Enable to visualize raycasts in the scene with gizmos
Get access to the rapier world
The joint prevents any relative movement between two rigid-bodies, except for relative rotations along one axis. This is typically used to simulate wheels, fans, etc. They are characterized by one local anchor as well as one local axis on each rigid-body.
clear all possibly cached data (e.g. mesh data when creating scaled mesh colliders)
Get the Needle Engine component for a rapier object
Returns the linear velocity of a rigidbody or the rigidbody of a collider
Fast raycast against physics colliders
Optionalorigin: Vec3 | Vec2ray origin in screen or worldspace
Optionaldirection: Vec3ray direction in worldspace
Optionaloptions: {additional options
OptionalfilterGroups?: numberOptionalfilterPredicate?: (c: ICollider) => booleanReturn false to ignore this collider
OptionalmaxDistance?: numberOptionalqueryFilterFlags?: QueryFilterFlagsOptionalsolid?: booleanTrue if you want to also hit objects when the raycast starts from inside a collider
OptionaluseIgnoreRaycastLayer?: booleanWhen enabled the hit object's layer will be tested. If layer 2 is enabled the object will be ignored (Layer 2 == IgnoreRaycast) If not set the raycast will ignore objects in the IgnoreRaycast layer (default: true)
raycast that also gets the normal vector. If you don't need it use raycast()
Optionalorigin: Vec3 | Vec2Optionaldirection: Vec3Optionaloptions: {OptionalfilterGroups?: numberOptionalfilterPredicate?: (c: ICollider) => booleanReturn false to ignore this collider
OptionalmaxDistance?: numberOptionalqueryFilterFlags?: QueryFilterFlagsOptionalsolid?: booleanTrue if you want to also hit objects when the raycast starts from inside a collider
OptionaluseIgnoreRaycastLayer?: booleanWhen enabled the hit object's layer will be tested. If layer 2 is enabled the object will be ignored (Layer 2 == IgnoreRaycast) If not set the raycast will ignore objects in the IgnoreRaycast layer (default: true)
Precice sphere overlap detection using rapier against colliders
center of the sphere in worldspace
radius of the sphere
array of colliders that overlap with the sphere. Note: they currently only contain the collider and the gameobject
Optionaldt: number
Enable to render collider shapes