SoiWatch

interface SoiWatch

What a frame's sphere-of-influence tests already know, so most ticks can skip them.

For each child of the frame, and for the frame's own boundary in the last slot, the gap between the entity and the sphere as of at, measured from origin. A gap is consumed by how far the entity has since moved from the origin plus how far the child could have moved toward it — its periapsis speed times the elapsed time — and while what is left is positive the triangle inequality says the entity cannot be inside. That is a subtraction and a multiply per child in place of a Kepler solve and a pose composition, and it is what makes sixty-six children cost nothing on a tick that is not near any of them.

Derived, never saved: a world that has none makes every test on its first tick and gets the answers the bounds were standing in for.

simulation/src/flight.ts:132

Members

at

at: number

framereadonly

frame: FrameId

gapsreadonly

gaps: Float64Array

One per child, then the parent boundary. Mutated in place.

origin

origin: Vec3