Talos docs

rigidbody

Since 0.6
Plain text

Use it in a scene entity's components list as { "type": "rigidbody", … }. The contract writes the fields flat and refuses unknown keys.

Fields

FieldTypeRequiredDefaultAllowed valuesDescription
kindBodyKindyesstatic, dynamic, kinematic
massnumberno
frictionnumberno
restitutionnumberno
ccdbooleannoContinuous collision detection for this body, overriding the scene's physics quality. true makes it a bullet: whenever it moves fast it is swept against every other body, moving ones included, so a thrown ball or a projectile cannot pass through a thin wall or a crate between two ticks. Two bullets are not swept against each other. false keeps it out of the quality's per-body CCD (fast bodies are still swept against static colliders unless the quality's ccd is off). Absent follows meta.physics (medium: on for bodies moving fast enough to tunnel). Only dynamic bodies use it.
lockAxesLockAxesnoWorld axes this body may not move along or turn about, e.g. { "rotation": ["x", "z"] } for a crate that only turns about Y. Combines with planar. Only dynamic bodies use it.
planarbooleannofalsetrue keeps the body in the XY plane at the Z it spawned at: translation locked on Z and rotation locked about X and Y, so it only slides in X and Y and spins about Z (2D physics on the 3D solver). Adds to lockAxes. Default false. Only dynamic bodies use it.

Rules that can refuse it

Example

From the contract's tested fixture fixtures/contract/full20/scene.json#wall-north.

{
  "type": "rigidbody",
  "kind": "static"
}