PhysicsHandle
A world’s physics scene once it holds a body: the Rapier world and what the engine keeps beside it.
Properties
Section titled “Properties”| Property | Type | Description |
|---|---|---|
actors |
Map<Entity, PhysicsActor> |
A kinematic capsule per actor, made the first step it moves. |
bodies |
Map<Entity, RigidBody> |
A body per entity with a ColliderTrait, made the first step it is seen. |
brokenJoints |
Set<Entity> |
The joints that broke at the last step, whose entities the next step destroys. |
changedBodies |
Set<Entity> |
The entities whose CharacterCapsuleTrait or ColliderTrait changed since the bodies were last matched to them, each edited in place then. |
fallen |
Set<Entity> |
The dynamic bodies and living characters that fell below the scene’s killBelowHeight and emitted FellOutOfWorldEvent. A body or an NPC is destroyed at the next step unless it stands above it again, and a player’s character stays here until it stands above it or goes down. |
fixedChanges |
number |
Changes a walker’s sweep would meet, counted: one for each body built or dropped, each change of a body’s kind, shapes, places, scale, trigger flags, layers or ignore list, and each rebuild of a terrain or its hulls; a change of material, damping or mass counts none. A step’s sweep record holds the count it ran under, so a replay of the step tells the geometry changed. |
forcedBodies |
Set<Entity> |
The bodies a force or a torque was added to since the last step, whose forces the next step clears once it has applied them. |
joints |
Map<Entity, BuiltJoint> |
A Rapier joint per joint entity this world simulates, built the first step both its bodies stand built. |
kinematicPlacements |
number |
Kinematic bodies placed at once rather than moved by a physics step, counted: each teleport or moveAndSlide of one. A query through a step meets such a body where it now stands, so a cache of the scene’s answers reads this beside fixedChanges. |
navMesh |
NavMeshHandle | null |
The bake the actors’ polygons belong to, so a new bake is told from the old by reference. |
placedAlone |
Entity | null |
The one actor whose own bodies and colliders are all that was set in place, added or removed since then, or null: its own casts leave it out, so its next lone move needs no refresh. |
placedSinceStep |
boolean |
Whether a body was set in place, or a collider added or removed, since the Rapier world last stepped, where the sweeps’ queries do not see it yet. |
preparedPass |
number |
The step pass the movers last readied the scene for, so they ready it once a step. |
slidBodies |
Map<Entity, SlidStart | null> |
The kinematic bodies moveAndSlide placed since the last step, each with where it stood before its first move of the tick, which the step puts it back at and hands the solver its end as a target, so it pushes what it meets with the move’s velocity; null for one teleported this tick, which takes no target and pushes nothing. |
terrains |
Map<Entity, TerrainBody> |
A terrain body per ground entity, built the first step that finds the ground and rebuilt alone when its surface changes. |
unsubscribers |
() => void[] |
The koota subscriptions the handle made, dropped when it is freed. |
world |
World |
- |