Creates a new PhysicsSystem.
The event bus to dispatch collision events.
Continuous Collision Detection (CCD) threshold, as a multiple of a sphere body's own radius.
If a sphere-shaped body moves farther than radius * ccdMotionThreshold in a single
substep, it's swept against nearby geometry instead of only being checked for overlap at its
new position -- this catches fast/small bodies that would otherwise tunnel straight through
thin walls or other small colliders. Sphere bodies only, see
docs/adr/0005-ccd-sphere-only-scope.md. Set to Infinity to disable CCD entirely.
The fixed time step for physics calculations (e.g. 1/60).
Global gravity vector (default: -9.81 on Y)
Maximum delta time allowed per frame.
Maximum number of sub-steps per frame to prevent spiral of death.
How far the accumulator has progressed into the next, not-yet-simulated fixed timestep, as
a fraction in [0, 1). Used by applyRenderInterpolation to blend each body's rendered
transform between its previous and current physics state.
Renders every tracked rigid body's transform interpolated between its previous and current
fixed-timestep physics state, instead of snapping to the latest completed substep -- this is
what actually eliminates visual stutter when the render framerate doesn't line up evenly
with fixedTimeStep (see "Fix Your Timestep!" in REFERENCES.md).
Must be called once per frame, after anything that depends on the true physics transform (collision bounds, frustum culling, gameplay logic) and immediately before rendering: each object's true position/rotation is restored right after its interpolated world matrix is computed, so nothing else ever observes the interpolated (render-only) state.
Steps the physics simulation forward.
The scene containing objects with RigidBodies.
Delta time in seconds.
A lightweight physics solver using Semi-Implicit Euler integration.