A big sphere with 60 small ones converging has more contacts than graph colours, so Box3D's
scalar overflow path runs: the big lane equals the sum of the small lanes, each its own
momentum change, at restitution 0 and 0.5. A swung arm (ApplyImpulse launches) into a
frictionless slab is exact. The docs say the lane sums magnitudes and is the weight at
rest only on average.
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
contact_impulse (N s) replaces last_substep_force in the same lane slot: the sum of
Box3D's stepNormalImpulse over the body's touching manifold points, the normal impulse
contacts delivered over the whole step. The hit fact's impulse replaces impulse_estimate in
the same slot: the same sum over the manifold of the hit's shape pair. The approach-speed
formula (ymir_soa_hit_impulse) and the last-sub-step scaling are gone, with the tests that
pinned their estimates; the new tests check the lane and the hit against momentum change
per step on a jointed forearm (5 kg ball, 0.3 g BB, arm onto a slab), drops, rest and two
free bodies. Build id names the fork commit.
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
extern/box3d now points at https://eureka.gamecult.org/forge/GameCult/box3d, branch
gamecult/step-normal-impulse (upstream 8441b4a plus the step-impulse field and a static
assert that RELAX_ITERATIONS is 1). Nothing reads the new field yet.
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
DestroyJoint takes (lane, generation) and refuses a stale handle, so a repeated
release cannot destroy a later grab in a reused slot. The ABI number moves to 6
so an old and a new native/managed pair fail closed at construction. Fixes Soul
s2 findings.
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
destroy_joint releases a motor joint only; its lane reads Removed and is reused
after a step has passed. free_joint_slots lets a caller check before adding an
anchor. After every step anchor velocity is zeroed so a skipped frame flings
nothing. Fixes Soul s1 findings (no release, anchor keeps moving).
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Anchor body kind (kinematic, no shape) with set_anchor_target; Motor joint kind
with position springs bounded by max force and torque, taking the slot of the
joint desc's reserved float; apply_impulse at a world point; cast_ray_closest.
Ymir executes the commands and decides nothing about grabbing.
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
ImpulseEstimate is documented as exact for a centre-to-centre hit between
free bodies, over-counting when one collision yields several hit facts and
undercounting for jointed bodies; never a bound. Tests: two free spheres at
mass ratios 1:1, 1:10, 10:1 with restitution 0 and 0.5, and a hit below the
restitution threshold that must not bounce. The ABI handshake now checks the
touch and hit fact element sizes.
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Box3D exposes no whole-step normal impulse: normalImpulse is the last
sub-step and totalNormalImpulse is a solve plus relax mixture, so no lane
built from them is true on an impact step. The per-body lane is renamed
LastSubstepForce and documented as a resting load only. Impact severity is
the hit fact's ImpulseEstimate, v (1 + e) / (1/mA + 1/mB), checked against
the ball's momentum change at 60 and 240 Hz, 1 and 4 sub-steps, restitution
0 and 0.5. Also pins that dropped counters reset each step.
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
totalNormalImpulse accumulates the accumulated impulse once per solve and
once per relax pass, so a resting body read twice its weight. ContactForce
is now normalImpulse * sub_steps / dt, which reads the weight at rest.
Tests cover drop begin/hit, lift end, resting force, materials, one-step
lifetime, overflow counting, per-step determinism and zero allocation.
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Every shape is created with contact and hit events on; the body's user data
is lane + 1. After each step the world rewrites begin, end and hit fact
buffers (lanes and stable ids resolved, fixed capacity, per-kind dropped
counters) and the ContactForce (totalNormalImpulse / dt), ContactCount and
MaterialId lanes. Body desc gains material_id; create takes fact_capacity
and hit_threshold. No allocation inside the step.
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Soul low finding on cut-ymir-shape-lanes.s1: a direct native caller could
publish nonzero unused components, contradicting the docs.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Size0/1/2 sit beside Kind, written once in add_body, never touched by step,
so a renderer draws every body from one source.
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
b3CreateWorld/b3DestroyWorld scan and rewrite Box3D's global world pool with
no synchronization; concurrent creation crashed the host (0xC000001D). All
five call sites (SoA world, retained session, pair step, torque lifetime) now
go through one lock owned by ymir_box3d.c (SRWLOCK on Windows, pthread mutex
elsewhere). Adds a multi-thread create/step/dispose test, which aborts the
test host without the lock; drops the serial-test assembly attribute.
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
ABI 2. One body descriptor replaces add_sphere/add_static_box (kinds: sphere, capsule, box, static box).
Revolute, spherical and weld joints created from a world anchor and axis, with joint state lanes (angle,
frame A orientation, relative rotation, relative angular velocity). Per-body force and torque write lanes,
applied before the step then cleared; non-finite values refuse the step. Parent and limb index lanes.
Tests run serially: concurrent b3CreateWorld aborts the host.
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
New native object ymir_box3d_soa (ABI 1): gravity, free rotation, spheres and static boxes,
one worker, state copied once per step into contiguous lanes that a caller reads in place.
Managed Box3DSoaWorld/Box3DSoaView expose the lanes as spans. The planar retained session is
unchanged. Tests: fall and rest, in-place reads, bit-for-bit repeat runs.
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Eve is deprecated; per thing2:ruling:eve-dashboards-quarantined the surface builders, EveSurfaceDocument publication, GameCult.Eve.Surface reference and EveRoot are gone. YmirOperatorStateDocument and its publication stay.
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Directory.Build.props names CultLibRoot (CULTLIB_ROOT, else the sibling checkout) and pins CultLibRevision to cultlib-unity-v2.0.0 (42dce361). Directory.Build.targets fails the build unless that checkout is at the pin and clean, as Aetheria's guard does. Project references use CultLibRoot.
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Claude Code reads CLAUDE.md, not AGENTS.md, so this repo's doctrine was
invisible to it. This one-line import makes the existing AGENTS.md load
without duplicating or renaming it. Codex is unaffected.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>