Files
sporel-module-vagrant-skeleton/rigs/humanoid.rig.json
Axel Meyer 3f176f6105 fix(vagrant): remove head sprite_rot + invert signed-angle cross-sign
Two fixes from manual interactive verification after iteration-3:

1. Head 90° CCW off → removed sprite_rot=-90 from head bone. The
   v0.3.3 sprite_rot fix was based on misobservation: at that point
   the persistent-state-rate-limit bug was active and head was
   wiggling within ±10° of an arbitrary initial direction, perceived
   as 90° CW off. With v0.3.2+ persistent-state fix and v0.4.0 slerp,
   head rotates correctly when sprite-natural-face is -Y (matching
   body-sprite convention).

2. Legs walked in inverted sector → signed_angle_2d cross-component
   was using Y-up math convention but Sporel screen-coords are Y-down.
   With Y-down, what's CCW in math is CW visually. Flipping the cross
   sign aligns sector selection: body up + player walks right → CW
   visually → walk_right_lower (was wrongly returning walk_left).

Front/back leg-anchor issue (#3 from user report) deferred — likely an
optical-overlap artifact from rotated body sprite + world-frame leg
positions, will reassess after #1+#2 fixes are visually verified.
2026-05-18 21:38:43 +02:00

24 lines
2.3 KiB
JSON

{
"id": "humanoid",
"asset_pack": "player",
"bones": [
{ "id": "root", "parent": null, "rest": {"x": 0, "y": 0, "rot": 0}, "z_order": -1 },
{ "id": "lower_control", "parent": "root", "rest": {"x": 0, "y": 0, "rot": 0}, "virtual": true },
{ "id": "body", "parent": "root", "rest": {"x": 0, "y": 0, "rot": 0}, "z_order": 2, "texture": "body_001", "look_at": "soft", "look_at_slerp": 6 },
{ "id": "head", "parent": "body", "rest": {"x": 0, "y": -3, "rot": 0, "rot_min": -60, "rot_max": 60}, "z_order": 6, "texture": "head_001", "look_at": "aim" },
{ "id": "shoulders", "parent": "body", "rest": {"x": 0, "y": 0, "rot": 0}, "z_order": 5, "texture": "shoulder_001" },
{ "id": "upper_arm_l", "parent": "shoulders", "rest": {"x": -19, "y": -3, "rot": 0, "scl": [-1, 1]}, "z_order": 3, "texture": "upper_arm_001" },
{ "id": "upper_arm_r", "parent": "shoulders", "rest": {"x": 20, "y": -4, "rot": 0}, "z_order": 3, "texture": "upper_arm_001" },
{ "id": "lower_arm_l", "parent": "upper_arm_l", "rest": {"x": 14, "y": -18, "rot": 0}, "z_order": 2, "texture": "lower_arm_001" },
{ "id": "lower_arm_r", "parent": "upper_arm_r", "rest": {"x": 13, "y": -17, "rot": 0}, "z_order": 2, "texture": "lower_arm_001" },
{ "id": "leg_l", "parent": "lower_control", "rest": {"x": -9, "y": 1, "rot": 0, "scl": [-1, -1]}, "z_order": 1, "texture": "leg_001" },
{ "id": "leg_r", "parent": "lower_control", "rest": {"x": 9, "y": 1, "rot": 0, "scl": [ 1, -1]}, "z_order": 1, "texture": "leg_001" },
{ "id": "foot_l", "parent": "leg_l", "rest": {"x": 0, "y": 25, "rot": 0, "scl": [ 1, -1]}, "z_order": 0, "texture": "foot_001" },
{ "id": "foot_r", "parent": "leg_r", "rest": {"x": 0, "y": 26, "rot": 0, "scl": [ 1, -1]}, "z_order": 0, "texture": "foot_001" }
],
"tracks": [
{ "id": "lower", "bones": ["leg_l", "leg_r", "foot_l", "foot_r"] },
{ "id": "upper", "bones": ["body", "head", "shoulders", "upper_arm_l", "upper_arm_r", "lower_arm_l", "lower_arm_r"] }
]
}