Function setPhysicsBodyCollisionEventsEnabled
-
setPhysicsBodyCollisionEventsEnabled(
world: PhysicsWorld,
body: PhysicsBody,
enabled: boolean,
): voidParameters
- world: PhysicsWorld
The physics world owning the body.
- body: PhysicsBody
The body to toggle collision events on.
- enabled: boolean
trueto report STARTED/CONTINUED/FINISHED events,falseto silence the body.
Returns void
- world: PhysicsWorld
Enable or disable collision-event reporting for a single body by setting its Havok event mask.
Only bodies with events enabled contribute to the stream read by onPhysicsCollision; a collision is reported when at least one of the two touching bodies has events enabled.