| name | dodge |
| description | Dodges quickly to one side with a fast sequence that shifts root sideways and leans the torso, keeping the facing. Use when a command mentions dodge, dodge sideways, sidestep quickly, juke, evade, jump out of the way, or quick lateral dodge. |
| category | locomotion |
| disable-model-invocation | true |
| subskills | ["shift-weight","move-leg","move-torso"] |
dodge
A fast evasive shift to one side, body leaning into it, still facing forward. A quick two-frame sequence that nudges root sideways (OMIT faceDeg so the heading holds).
How
- The side direction is
faceDeg+90 (right) or faceDeg-90 (left): dx=sin, dz=cos of that heading. At face 0, RIGHT is +X (root.x increases), LEFT is -X.
- Use
loop:false, two frames: neutral, then shifted ~0.6–0.8 m to the side with a torso lean that way (Spine/Chest Z) and a small knee bend. Keep it FAST: durationMs ~350–550. Do NOT set faceDeg.
Example
- "dodge to the right" (at x:0,z:0,faceDeg:0) ->
{"durationMs":450,"say":"Whoa!","sequence":{"loop":false,"frames":[{"t":0,"pose":{"Spine":[0,0,0]},"root":{"x":0}},{"t":1,"pose":{"Spine":[0,0,-18],"Chest":[0,0,-12],"RightUpLeg":[20,0,0]},"root":{"x":0.7}}]}}
- "dodge left" (at x:0,z:0,faceDeg:0) ->
{"durationMs":450,"say":"Nope!","sequence":{"loop":false,"frames":[{"t":0,"pose":{"Spine":[0,0,0]},"root":{"x":0}},{"t":1,"pose":{"Spine":[0,0,18],"Chest":[0,0,12],"LeftUpLeg":[20,0,0]},"root":{"x":-0.7}}]}}