Function setPhysicsShapeIsTrigger
-
Parameters
- world: PhysicsWorld
The physics world owning the shape.
- shape: PhysicsShape
The collision shape to flag.
- isTrigger: boolean
trueto make the shape a trigger volume,falsefor a solid shape.
Returns void
- world: PhysicsWorld
Flag a collision shape as a trigger volume (or clear the flag).
A trigger shape detects overlaps and reports PhysicsTriggerInfo events but does not produce a physical collision response — bodies pass through it. Attach the flagged shape to a body in the world, then listen with onPhysicsTrigger.