acdream/tools/cdb/cellar-corner-escape.cdb
Erik 5ad897b0a5 docs(p2): cellar corner-wedge pinned to step-up-onto-floor (retail cdb) + trace apparatus
Live retail cdb trace (tools/cdb/cellar-corner-escape.cdb) of the Holtburg
cottage cellar-top corner decodes the ground truth: retail escapes by
step_sphere_up->step_up (196x vs 38 near-misses), transitioning the contact
plane from the ramp (N.z=0.78) onto the flat cottage floor (N.z=1.0, 76
landings). acdream slides at the lip and never makes that ramp->floor
transition -> the intermittent cellar wedge.

So the remaining cellar bug is the #98-core step-up-onto-cottage-floor
(DoStepDown / step_sphere_down / find_walkable), which the shipped B1 (abbd761)
+ slide_sphere (0935a31) fixes got close to but didn't finish. Door still
blocks; generic step-up climbs; cellar went always-stuck -> works-mostly.

Next (handoff doc): instrument acdream's OWN corner path (does step_up fire at
the lip and fail to land on the cottage floor?) before porting the lip-climb --
no guessing (#98 saga rule).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-04 11:27:44 +02:00

51 lines
2.9 KiB
Text

$$
$$ Cellar-top corner-escape capture — 2026-06-04 (P2 cellar wedge)
$$
$$ Q: at the cellar-top corner, the acdream player (on the ramp, pushing +Y)
$$ wedges against a -Y wall (head-sphere near-miss -> slide, oscillates, no
$$ net +Y). Does RETAIL escape by STEPPING UP over the lip, or by SLIDING,
$$ and is the near-miss a HEAD (neg_step_up=0) or FOOT (neg_step_up=1) hit?
$$ That decides whether the fix is slide-convergence vs step-up-at-the-lip.
$$
$$ Unique (non-overloaded) symbols only -> robust counts + key args:
$$ BPA CTransition::step_up(this, Vector3* normal) step-up ATTEMPT
$$ BPB BSPTREE::step_sphere_up(this@ecx, CTransition*, V3*) step-up DISPATCH
$$ BPC SPHEREPATH::set_neg_poly_hit(this, int negStepUp, V3* n)
$$ negStepUp 0=head(slide) 1=foot(step-up); also logs n
$$ BPD COLLISIONINFO::set_contact_plane(this, Plane*, isWater)
$$ landing signal: N.z ~1 = cottage floor (escaped), ~0.7 = ramp
$$
$$ thiscall: ecx=this; args [esp+4],[esp+8],... CSphere center: x+0 y+4 z+8 r+0xc
$$ Plane (set_contact_plane arg): N.x+0 N.y+4 N.z+8 d+0xc
$$ Floats logged as 32-bit hex (dwo + %08X); decode with tools/cdb/decode_retail_hex.py
$$
$$ Threshold 30000 hits across A+B+C (auto-detach via qd). BPD unbounded.
$$ Walk up the cellar stairs into the corner and let it wedge once or twice;
$$ the wedge generates the hits, so 30K auto-detaches within an attempt or two.
.logopen C:\Users\erikn\source\repos\acdream\.claude\worktrees\thirsty-goldberg-51bb9b\cellar-corner-retail.log
.sympath C:\Users\erikn\source\repos\acdream\refs
.symopt+ 0x40
.reload /f acclient.exe
r $t0 = 0
r $t1 = 0
r $t2 = 0
r $t3 = 0
r $t4 = 0
$$ BPA: CTransition::step_up(this, Vector3* normal) — did retail try to step up the lip?
bp acclient!CTransition::step_up "r $t1=@$t1+1; r $t0=@$t0+1; .printf /D \"[BPA] step_up #%d nx_h=0x%08X ny_h=0x%08X nz_h=0x%08X\\n\", @$t1, dwo(poi(@esp+4)+0), dwo(poi(@esp+4)+4), dwo(poi(@esp+4)+8); .if (@$t0 >= 30000) { qd } .else { gc }"
$$ BPB: BSPTREE::step_sphere_up — step-up dispatch count.
bp acclient!BSPTREE::step_sphere_up "r $t2=@$t2+1; r $t0=@$t0+1; .printf /D \"[BPB] step_sphere_up #%d\\n\", @$t2; .if (@$t0 >= 30000) { qd } .else { gc }"
$$ BPC: SPHEREPATH::set_neg_poly_hit(this, int negStepUp, Vector3* n)
bp acclient!SPHEREPATH::set_neg_poly_hit "r $t3=@$t3+1; r $t0=@$t0+1; .printf /D \"[BPC] neg_poly_hit #%d negStepUp=%d nx_h=0x%08X ny_h=0x%08X nz_h=0x%08X\\n\", @$t3, dwo(@esp+4), dwo(poi(@esp+8)+0), dwo(poi(@esp+8)+4), dwo(poi(@esp+8)+8); .if (@$t0 >= 30000) { qd } .else { gc }"
$$ BPD: COLLISIONINFO::set_contact_plane(this, Plane*, isWater) — landing signal (unbounded).
bp acclient!COLLISIONINFO::set_contact_plane "r $t4=@$t4+1; .printf /D \"[BPD] contact_plane #%d Nz_h=0x%08X d_h=0x%08X\\n\", @$t4, dwo(poi(@esp+4)+8), dwo(poi(@esp+4)+0xc); gc"
.printf "cellar-corner-escape armed: A=step_up B=step_sphere_up C=neg_poly_hit D=contact_plane; 30K threshold\\n"
g