Component:BoxCollider: Difference between revisions

From Resonite Wiki
Automated: update Fields
add info
Line 2: Line 2:
<translate>
<translate>
<!--T:1-->
<!--T:1-->
{{stub}}
{{Infobox Component
{{Infobox Component
|Image=BoxColliderComponent.png
|Image=BoxColliderComponent.png
|Name=Box Collider
|Name=Box Collider
}}
}}
Representing a simple box, this collider is the second most performant collider in the game, beaten by [[Component:SphereCollider|Sphere Colliders]]


<!--T:2-->
<!--T:2-->
== Fields ==
== Fields ==
{{Table ComponentFields
{{Table ComponentFields
|Offset|Float3|
|Offset|Float3| How much to offset the center of this collider relative to the slot it is on
|Type|ColliderType|
|Type|ColliderType| The type of this collider. See the enum page for details.
|Mass|Float|
|Mass|Float| How heavy this collider is in total.
|CharacterCollider|Bool|
|CharacterCollider|Bool| Whether this should physically stop character controllers like players.
|IgnoreRaycasts|Bool|
|IgnoreRaycasts|Bool| Whether raycast operations like guns should hit this collider.
|Size|Float3|
|Size|Float3| How big locally this collider is in the x, y, and z directions.
}}
}}


Line 24: Line 24:
<!--T:4-->
<!--T:4-->
== Examples ==
== Examples ==
This is useful for floors and walls, and can also be set to NoCollide and used as a way to mark an area for a custom culling system.


<!--T:5-->
<!--T:5-->
== Related Components ==
== Related Components ==
</translate>
</translate>
[[Category:ComponentStubs]]
[[Category:Components{{#translation:}}|Box Collider]]
[[Category:Components{{#translation:}}|Box Collider]]
[[Category:Components:Physics:Colliders{{#translation:}}|Box Collider]]
[[Category:Components:Physics:Colliders{{#translation:}}|Box Collider]]

Revision as of 20:22, 14 October 2024

Component image 
Box Collider component as seen in the Scene Inspector

Representing a simple box, this collider is the second most performant collider in the game, beaten by Sphere Colliders

Fields

Fields
Name Type Description
persistent Bool Determines whether or not this item will be saved to the server.
UpdateOrder Int Controls the order in which this component is updated.
Enabled Bool Controls whether or not this component is enabled.
Offset Float3 How much to offset the center of this collider relative to the slot it is on
Type ColliderType The type of this collider. See the enum page for details.
Mass Float How heavy this collider is in total.
CharacterCollider Bool Whether this should physically stop character controllers like players.
IgnoreRaycasts Bool Whether raycast operations like guns should hit this collider.
Size Float3 How big locally this collider is in the x, y, and z directions.

Usage

Examples

This is useful for floors and walls, and can also be set to NoCollide and used as a way to mark an area for a custom culling system.

Related Components