ColliderOptions
physics/rigid-body.types.ts:75Describes one collider attached to a RigidBody: its shape plus the material and role knobs that govern how it responds to contact. A body can carry several, letting you build a compound silhouette from primitives.
Properties
density?: number Mass density, in mass units per pixel². A dynamic body's mass and inertia
are derived from its colliders' densities and areas. Defaults to Rapier's
1. Ignored for fixed bodies (infinite mass).
friction?: number Surface friction coefficient. 0 is frictionless; higher values resist
sliding contact. Defaults to Rapier's 0.5.
isSensor?: boolean When true, the collider detects overlaps and reports contacts but does
not push anything — a trigger volume. Defaults to false.
offset?: PointPrimitive Local-space offset of the shape from the host origin, in pixels. Defaults
to (0, 0). Use it to place a collider off-center or to assemble a
compound body from several offset primitives.
restitution?: number Bounciness, from 0 (no bounce, energy fully absorbed) to 1 (perfectly
elastic). Defaults to Rapier's 0.