> For the complete documentation index, see [llms.txt](https://hiveminddocs.gitbook.io/hivemind/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://hiveminddocs.gitbook.io/hivemind/code-systems/ultimate-building-system-framework-ubs/proxy-behaviour/placement-conditions.md).

# Placement Conditions

With `Placement Conditions`, you can create any logic required to control where and how a buildable can be placed. For example, you might want to prevent a buildable from being placed if it overlaps with the environment. You can add and combine multiple placement conditions to customize the placement behavior for your buildables.

To create your own placement condition, subclass the `UBF_BuildableCondition` class and override the `CanPlace` function. This function returns a boolean: if `true`, the buildable can be placed; if `false`, it cannot be placed.

<figure><img src="/files/FS9HT6sgtvDV7iNCDgUK" alt=""><figcaption><p>Example of a Placement Condition</p></figcaption></figure>

## Functions

* `CanPlace()`:\
  Create your conditional logic here. Returns a boolean - true will pass the condition, false will fail it.<br>


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://hiveminddocs.gitbook.io/hivemind/code-systems/ultimate-building-system-framework-ubs/proxy-behaviour/placement-conditions.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
