Post

CollisionSensor

CollisionSensor

Overview

CollisionSensor generates collision-detection events.

The CollisionSensor node belongs to the RigidBodyPhysics component and requires at least level 1, its default container field is children. It is available from X3D version 3.2 or higher.

Hierarchy

1
2
3
4
+ X3DNode
  + X3DChildNode
    + X3DSensorNode
      + CollisionSensor

Fields

SFNode [in, out] metadata NULL [X3DMetadataObject]

Information about this node can be contained in a MetadataBoolean, MetadataDouble, MetadataFloat, MetadataInteger, MetadataString or MetadataSet node.

Hint

SFString [in, out] description “”

Author-provided prose that describes intended purpose of the node.

Hint

  • Many XML tools substitute XML character references for special characters automatically if needed within an attribute value (such as & for & ampersand character, or " for “ quotation-mark character).

SFBool [in, out] enabled TRUE

Enables/disables node operation.

SFBool [out] isActive

isActive true/false events are sent when sensing starts/stops.

Warning

  • It is an error to define this transient outputOnly field in an X3D file, instead only use it a source for ROUTE events.

MFNode [out] intersections [X3DNBodyCollidableNode]

Output field intersections.

MFNode [out] contacts [Contact]

Output field contacts.

SFNode [in, out] collider NULL [CollisionCollection]

The collider field specifies a CollisionCollection node that holds a collidables field of nodes and spaces that are to be included in collision-detection computations.

Advice

Hints

See Also

This post is licensed under CC BY 4.0 by the author.