Blend walking and running by speed so the feet do not slide or hop
Mixing a slow walk and a fast run for in-between speeds looks wrong when the two cycles have different lengths: the legs fall out of step and the character seems to skate. Here is the way to mix them so every foot lands together.
Why this works
Feet slide when the legs move at a different pace than the ground, and they hop when two walks are out of step. One shared position in the stride, used by both clips, keeps the feet in agreement, and the pace of the stride follows the speed on the ground.
When not to use it
Don't use it for movement that is not a repeating stride, such as a limp, a crawl, a dance or an animal that gallops in jumps. Their feet land in different patterns. Switch between separate clips there, with a short fade.
In the full entry
- What to build, step by step
- Starting values and the reason for each
- 4 common mistakes and the fix
- 39 lines of example code with 4 checks that pass
- How your AI shows you that it works
Say this to your AI
Use the Spielerando entry "Blend walking and running by speed so the feet do not slide or hop" (read_entry walk-run-blend-with-matching-footsteps) in my game. Build it step by step, and show me how you checked that it works.Or skip this and connect the MCP: your AI then finds all of this by itself.Connect the MCP