From 038505ea3e0ac9938822be392265f71ce8240d98 Mon Sep 17 00:00:00 2001 From: VinPropane Date: Sun, 12 Apr 2026 19:03:50 -0400 Subject: [PATCH] NEON-29: Gate descend lip snap on debounced ledge peel. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit DESCEND_LIP_SNAP_CAP (0.1) ran whenever goal was below feet by geometry, independent of probe debounce. Feet_y noise on treads toggled 0.32 vs 0.1 snap and caused ~2–3 cm Y jitter. Apply lip cap only when debounced peel is armed and not in peel suspend; otherwise keep FLOOR_SNAP_MOVING. --- client/scripts/player.gd | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/client/scripts/player.gd b/client/scripts/player.gd index eb1be30..057f2ad 100644 --- a/client/scripts/player.gd +++ b/client/scripts/player.gd @@ -567,9 +567,17 @@ func _walk_floor_snap_length( # fight the approach stairs with snap ↔ assist oscillation. if _auth_walk_goal.y > feet_y + 0.12 and _step_assist_wallish_blocks(want): return WALK_STEP_ASSIST_SNAP - if ( + # Lip cap only while debounced peel is armed. Otherwise [code]feet_y[/code] wobble on treads + # crosses [code]feet_y > goal + 0.08[/code] / margins → 0.32 m vs 0.1 m snap flips each tick + # (~2–3 cm body Y jitter on green stairs, x≈19). + var descend_lip_geom: bool = ( _auth_walk_goal.y < feet_y - DESCEND_GOAL_Y_MARGIN and feet_y > _auth_walk_goal.y + 0.08 + ) + if ( + descend_lip_geom + and _walk_debounced_wants_ledge_peel + and not _walk_peel_suspend_near_goal(feet_y, horiz_dist) ): return minf(FLOOR_SNAP_MOVING, DESCEND_LIP_SNAP_CAP) return FLOOR_SNAP_MOVING