πΆAdd object placement bounds
Quick guide to set up your game objects with bounds for placement.
Last updated
Quick guide to set up your game objects with bounds for placement.
Last updated
Each game object that will be used for placing should have something to define it's placement bounds.
This will be done internally by placement system if no component for this is present; provided one of these components is attached to the placing game object (root transform of the object/prefab):
BoxCollider: bounds are calculated from the collider
Renderer: bounds are retrieved from rendering bounds
For manual configuration of placement bounds for each game objects, you should use one of these provided components:
CustomPlacementBounds: bounds are defined by center
& size
properties
RendererPlacementBounds: supports referencing a specific renderer from which bounds are retrieved
ColliderPlacementBounds: supports referencing a specific collider from which bounds are calculated
IPlacementBounds or APlacementBounds can be used to implement your own behaviour for placement bounds
That is it! Each game object can use its own placement bounds, you are not bound to a type once selected.