Physics
The Rapier world and helpers: game.get(Physics) after adding the rapier() plugin.
rapier, world and body are Rapier’s own API, so they change with Rapier’s versions.
Properties
Section titled “Properties”rapier
Section titled “rapier”rapier:
any
The Rapier module (Ray, ColliderDesc, …), so games don’t import their own copy.
scale:
number
Pixels per meter.
world:
World
The Rapier world, for raycasts, joints and anything the components don’t cover.
Methods
Section titled “Methods”body()
Section titled “body()”body(
e):any
Rapier body of an entity, to apply impulses or read velocities.
Parameters
Section titled “Parameters”number
Returns
Section titled “Returns”any
