Add unique identifier for test_phase3c_walk_recovery.gd

This commit is contained in:
2026-09-06 13:09:37 -04:00
parent 1f91f3d2e5
commit 80595a0273
53 changed files with 6806 additions and 471 deletions
+31
View File
@@ -419,6 +419,37 @@ variant not referenced by the factory. The new `StickmanRig` script targets `mas
| D8 | Rig enables its own mod stack in `_ready()` | Facing/bend are meaningless until the stack is live; the rig should self-enable at runtime (single consumer today always enables it). |
| D9 | Rig exposes `get_bend_joint_global_position()` | Lets the harness drop `BEND_JOINT_BONE_PATHS`/`_bend_joint_bones` entirely; the rig owns the whole bend domain. |
## 9a. Round N — whole-rig Y-axis mirror (2026-09-05 design change)
**Decision (user-approved):** facing LEFT is now rendered as a **whole-rig Y-axis mirror** —
`Master.scale.x = -1` (RIGHT/FORWARD → `(1,1)`) — replacing the per-part/head mirroring. This flips
the head **and** body together so the figure faces the correct direction.
- `_apply_head_flip()` and the `Body/Head.scale.x` mirror are **removed** (the Head Pivot node's
driver transform is untouched).
- `PROFILE_FLAGS` (per-joint `flip_bend_direction`) and `Z_ORDER_BY_PROFILE` are **kept
provisionally** (unchanged). The mirror reflects the whole skeleton + `IK_Targets` + mounted
`Body/*` geometry, but does **not** affect depth (draw order); whether the bend flags can be
collapsed to a single canonical set must still be verified empirically (a root mirror is not
provably reflection-invariant for TwoBoneIK's `flip_bend_direction` sign).
- **Walk-clip mapping — Option A (single canonical clip):** `walk_right` is the canonical walk.
For `FacingProfile.LEFT` the rig root is X-mirrored and the **same `walk_right`** clip plays
mirrored; `walk_left` is no longer used at runtime. The animation `.:facing_profile` tracks are
neutralized/removed — facing is set explicitly by `set_facing_profile()` / `walk_to()`.
**Follow-up (implemented, tested):** two head-related fixes were required to make the LEFT root
mirror render the head correctly. (1) The head `RemoteTransform2D` (`Skeleton2D/Torso/Head/Pivot`)
no longer sets `update_scale = false` — it pushes the **full transform** like every other `Body`
driver, so `Body/Head.scale` stays identity under the mirrored root (the old partial-channel push
re-canonicalized the scale and caused per-frame Y-flips/wrap-jumps). (2) The `SkeletonModification2DLookAt`
that aims the Head bone is **not mirror-invariant**: under the LEFT root mirror it writes a bone
rotation 180° off the FORWARD aim, flipping the head to hang below the neck. New
`_apply_head_lookat_mirror_mode()` (called from `_apply_profile()`) disables the LookAt and pins the
head bone to the FORWARD canonical aim (π) when facing LEFT; `_pin_mirrored_head_rotation()`
re-asserts the pin each `_physics_process` frame while ANIMATED/RECOVERING so recovery's stack
re-arm can't let LookAt flip the bone. RIGHT/FORWARD re-enable the LookAt. Consequence: interactive
head-aiming while facing LEFT is intentionally static.
## 10. Test plan
1. **Parse check** (same as prior tasks):