diag(phys): [bsp-test] probe + grounded apparatus test + handoff
Visual verification of Task 7 ship: doors block at dead-center (the small Cylinder catches) but the BSP slab doesn't catch off-center or inside-walking-out approaches. Probe-instrumented live capture proves multi-part registration is correct — every door spawns with shapes=cyl1+bsp1, and the BSP part is visited 135 times for a single door at player approaches as close as 0.42 m, with cacheHit=True. But zero [resolve-bldg] attributions for the BSP shape. Three artifacts added: 1. TransitionTypes.cs — new [bsp-test] probe in the BSP collision dispatch, fires BEFORE the cache lookup. Mirrors [cyl-test] on the Cylinder branch. Distinguishes "cache miss → silent skip" from "queried but no hit" (the latter doesn't show up in [resolve-bldg] which only fires on attributed hits). 2. DoorCollisionApparatusTests.cs — new grounded test (Apparatus_Grounded_50cmOffCenter_*) attempts to reproduce the production bug via a seeded PhysicsBody (Contact + OnWalkable + ContactPlane + WalkablePolygon). Currently doesn't reproduce because the apparatus's stub-terrain + synthetic-floor setup diverges from production's real Holtburg geometry. Captured as "documents-the-bug" — flip the assertion shape when the fix lands. 3. docs/research/2026-05-24-door-collision-task7-shipped-but-bug-remains.md — full session handoff. Identifies the remaining bug as a Path 5 (Contact branch + StepSphereUp) misbehavior at thin tall obstacles, not in the multi-part registration we just shipped. Leading hypothesis: DoStepUp's downward probe finds the same flat floor on the OTHER side of the door (Holtburg cottages have no Z change between exterior and interior floor), declares step-up success, BSP collision returns OK, sphere walks through. Recommended next move: relaunch with ACDREAM_DUMP_STEPUP=1 to verify the hypothesis. What this commit DOES NOT do: fix the remaining step-up bug. The A6.P4 multi-part registration foundation is correct and stays. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
parent
ca9341c2cb
commit
163a1f0d35
3 changed files with 360 additions and 0 deletions
|
|
@ -2254,6 +2254,21 @@ public sealed class Transition
|
|||
// ── BSP object: use the full 6-path retail dispatcher ────
|
||||
// ACE: PhysicsObj.FindObjCollisions → Setup.BSP.find_collisions
|
||||
var physics = engine.DataCache.GetGfxObj(obj.GfxObjId);
|
||||
|
||||
// A6.P4 door investigation (2026-05-24): log every BSP shadow
|
||||
// visit before the cache lookup so we distinguish "cache miss
|
||||
// → silently skipped" from "queried but no hit" (only the
|
||||
// latter shows up in [resolve-bldg], which fires only on
|
||||
// attributed hits). Mirrors [cyl-test] on the Cylinder branch.
|
||||
if (PhysicsDiagnostics.ProbeBuildingEnabled)
|
||||
{
|
||||
Vector3 dxy = obj.Position - sp.GlobalCurrCenter[0].Origin;
|
||||
float distXY = MathF.Sqrt(dxy.X * dxy.X + dxy.Y * dxy.Y);
|
||||
bool cacheHit = physics?.BSP?.Root is not null;
|
||||
Console.WriteLine(System.FormattableString.Invariant(
|
||||
$"[bsp-test] obj=0x{obj.EntityId:X8} gfx=0x{obj.GfxObjId:X8} state=0x{obj.State:X8} radius={obj.Radius:F3} pos=({obj.Position.X:F2},{obj.Position.Y:F2},{obj.Position.Z:F2}) distXY={distXY:F3} cacheHit={cacheHit}"));
|
||||
}
|
||||
|
||||
if (physics?.BSP?.Root is null) continue;
|
||||
|
||||
// Transform player spheres to object-local space.
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue