Advanced Guides
Dive deeper into complex features and techniques with our advanced guides.
Last updated
Was this helpful?
Dive deeper into complex features and techniques with our advanced guides.
Last updated
Was this helpful?
This condition prevents placing a if there's a collision with any of the different objects.
You can enable this condition in the "Conditions Settings" section of your :
In the Building Collision Condition, remember to tick the "Show Gizmos" option. This lets you visualize collisions as they happen in your scene. You can then move your objects around and see how they interact with other objects by trying to make them collide.
It is important that the layer you have defined in your Building Collision Condition matches the one on which you intend to detect the collision.
Now that the detection is active, you can choose whether you want collisions to occur. By default, collisions with other objects are disabled.
Here are some additional explanations for each field that you will find in this condition :
In coming...
In coming...
Here is an example of what it can look like during runtime:
The condition is determined by the "Bounds" model of your , located in the 'Model Settings' section. Ensure they are set up correctly. These are generated automatically when you add a new , but you can later adjust their size and position to precisely fit your requirements.
When you turn on the condition and your is in the Unity Editor scene, you can use the Gizmos button at the top-right of the editor window. This shows you where collisions are happening in real-time, giving you instant updates on what's going on with your object.
If you want the colliding a specific surface to be placed, you'll need to check the "Require Building Surfaces" field. Make sure the "Bounds" hit the desired surface during the preview mode, and define your surfaces. You'll find instructions on how to define one further down the page.
If you want placement to occur only upon contact with another , you need to check "Require Building Part" and, as mentioned before, ensure that it collides with another .
For now, it's not possible to choose a specific type of to allow placement only on it, but this feature will be available in a future update.
Allows you to define the layers with which your will check for collisions.
This allows the placement of the only when entering into collision with other in your scene.
This allows the placement of the only on one of the surfaces you have predefined here. If none of these surfaces are found, placement will be refused.
The component allows you to attach your buildings to a predefined surface in your scene. This means the placed building will be linked to the transform and will move accordingly.
You can add the component to the object you want to attach your to during runtime. Here's an example below. You need to define a detection bounds, which will detect the placed within it and then link them to the transform.