OptionalcountLive contact points in the narrow phase after the last step (§84). Optional:
adapters that cannot walk manifolds omit this and SolverStatistics.contactCount
stays NaN.
Visits every live body in creation order (§33).
Visits every live collider in creation order (§33).
World transform of one body (§42 "physics" authority's read).
The members of
SolverBodyAccessthis module reads, declared locally because@fourjs/diagnosticscannot import@fourjs/physics(module header, plan §6h). Transcribed frompackages/physics/src/body-access.ts; an adapter satisfies it structurally, andTHandleis inferred from the caller because §37's handles are unforgeable brands.Everything
SolverBodyAccesspromises holds here unchanged: reads takeoutparameters and allocate nothing,forEachBodyandforEachCollidervisit in creation order (ascending monotonic id, §33), and a"2d"world reportsz = 0with rotation about +Z.Bodies and colliders take separate handle parameters because §37 gives them separate brands (
PhysicsBodyHandlevsPhysicsColliderHandle, which are mutually unassignable); collapsing them into one would make this interface unsatisfiable by a real adapter. Nothing here dereferences a collider handle — colliders are only counted — soTColliderHandleis inferred and otherwise ignored.