A kinematic capsule character. Set velocity (x/z) from a script or circuit each frame; gravity drives y. Calls move-and-slide and writes the resolved position back onto the GameObject.
A box sensor volume: fires onEnter/onExit as bodies overlap it and tracks how many currently do (isOccupied). Assign the callbacks from a script/circuit. Static (stays at its authored transform).
A single collision shape — Godot's CollisionShape3D. Pure geometry placed by
its GameObject's transform; it owns no physics body. The nearest ancestor
StaticBody gathers every descendant Collider into one compound body,
so each shape is a selectable/editable object yet costs no extra body. Inert
on its own (like a CollisionShape3D with no parent body).
A static physics body — Godot's StaticBody3D. Builds ONE compound collider
from every descendant Collider (stopping at nested bodies), so a whole
authored collision group is one broadphase entry while every shape stays an
editable GameObject. Always static; the compound is built once the physics
world is ready, reading each collider's live world transform at that moment.
Floats the sibling RigidBody on a water surface. Add it to a
GameObject that also has a dynamic RigidBody; set waterHeightAt
to the ocean surface query.
Options for locating the Jolt .wasm when initializing physics. Omit entirely
when building with Vite — the default path uses Vite's ?url asset handling
to emit, hash, and fetch the .wasm automatically. Supply one of these only for
non-Vite bundlers (webpack/rollup/esbuild/…) or to self-host the file (CDN,
custom public path), since the ?url import is a Vite-ism other bundlers don't
understand.
Growable line-list vertex buffer ([x,y,z, r,g,b] per vertex, world space).
Options accepted by the spawn helpers: physics tuning + visual styling.
A tracked body plus the local-space description of its collision shape(s), so
a debug renderer can draw exact collision wireframes at the body's live world
transform. Populated by the add* factories; dropped on removeBody/clear.
Callbacks for a sensor (trigger) body's overlap events.
Per-body tuning shared by every shape factory.
Coarse ground classification, mirroring Jolt's EGroundState.
Shape of a RigidBody.
Shape of a Collider.
One primitive sub-shape of a body's collision, described in BODY-LOCAL space, for debug visualization. A simple (non-compound) body has a single part at the local origin; a compound collider records one part per sub-shape. Triangle meshes / height-fields / convex hulls are not described here (too detailed to wireframe cheaply) — they simply produce no debug part.
One primitive sub-shape of a PhysicsWorld.addCompoundCollider body, in the compound's local space. Box half-extents are per-axis; cylinder / capsule axis is local Y.
How a body participates in the simulation.
Floats per vertex in the debug line buffer: position (3) + color (3).
Named collision layers as bit flags (Godot-style). A body's layer says which
layer(s) it belongs to; its mask says which layers it collides with. Two
bodies interact only when each one's layer appears in the other's mask (an
AND of both directions, matching Jolt's ObjectLayerPairFilterMask). Give
"passively collidable" bodies (static world, the player capsule) mask: All
and put the selective filtering on the active body (e.g. a bullet that should
hit only World | Enemy).
Back-compat alias for the static-geometry layer (was object layer 0).
Back-compat alias for the default dynamic layer (was object layer 1).
Loads the Jolt physics backend (the WASM module) on demand. Call once before
using physics, or simply await PhysicsWorld.create() which loads it for you.
Idempotent — safe to call repeatedly / concurrently.
True once the physics backend has finished loading.
Every Collider under root that belongs to the body at root — i.e.
the whole subtree, but NOT colliders inside a nested StaticBody (which
owns its own subtree). Mirrors Godot's "a CollisionShape3D belongs to its
nearest ancestor physics body". Exported for testability.
Register the physics component factories (idempotent; called on module import).
Creates an empty buffer with room for capacityVerts vertices.
Appends the wireframe of one collision sub-shape to buf. world is the
column-major model matrix placing the shape's LOCAL space into world space
(body world transform composed with the sub-shape's local offset). color
is the line RGB.
Rebuilds buf with wireframes for every collision shape currently in the
world, placed at each body's LIVE transform. Reads
PhysicsWorld.debugShapes; bodies with no debug description (mesh /
hull) contribute nothing. color is the line RGB (default a bright green,
Godot-style).
The physics system for an engine, created (and Jolt init kicked off) on first use.
The physics system for an engine if one exists, without creating it (no Jolt spin-up).
Set the pause state for an engine's physics. Records the desired state even before the system exists (so a later-attached body starts correctly gated) and applies it to a live system. Used by the editor to freeze the sim in edit mode.
The Jolt WASM rigid-body backend: PhysicsWorld body factories (box/sphere/mesh/heightfield/convex-hull), constraints, raycasts, the
PhysicsSceneGameObject coupling layer, and the per-frame step/sync loop.All physics goes through this module — never
jolt-physicsdirectly. The Jolt WASM backend is loaded lazily on first use (see initializePhysics /PhysicsWorld.create), in its own chunk, so apps that don't import this module ship none of it. It is intentionally NOT re-exported from the engine's top-level barrel; consumers opt in via thetaos/physicssubpath, which keeps Jolt out of every physics-free bundle.