Creating Locomotion Animation Cycles (Walk, Run, Jump) for Games
We develop locomotion animation networks—from simple idle/run sets to complex setups with blend trees, foot IK, and root motion. With over 10 years in gamedev and dozens of projects for Unity and Unreal Engine, we know that a poorly made locomotion set makes the character slide, float, or jerk at transitions—visible from the first second of gameplay. We guarantee your animations will perform flawlessly.
Why Blend Tree Outperforms State Machine for Locomotion
A common mistake is building locomotion through separate animation states in a State Machine with cross transitions. It looks fine in the Animator window, but in practice, transitioning idle → walk → run requires managing three transition thresholds and crossfade times, and any change in speed parameter creates noticeable blending artifacts.
A 1D Blend Tree by Speed parameter elegantly solves this: Unity interpolates between idle, walk, run, and sprint along a single axis, automatically normalizing weights. Thresholds: 0 — idle, 0.5 — walk, 1.0 — run, 2.0 — sprint. Set thresholds via Compute Thresholds → Velocity Z, which auto-calculates values based on root motion velocity in each clip.
A 2D Blend Tree (Simple Directional or Freeform Directional) adds a second axis—Strafe. Needed for shooters and action games where the character moves in 8 directions. It's critical to set the center point (0, 0) correctly—it should reference an idle clip with zero movement; otherwise, diagonal movement blending yields incorrect weights.
Root motion is a separate concern. If animations are made with root motion (character movement encoded in root bone motion), ensure: identical cycle step between walk and run (otherwise foot sliding during blend), and correct bake axes in Unity (Apply Root Motion → Bake Into Pose for vertical and horizontal axes depending on the project). For a walk cycle, the loop length in Unity is set via Loop Pose + Cycle Offset—if the clip isn't perfectly looped, a visible "bounce" occurs at the end of the cycle.
Setting Up Foot IK for Perfect Surface Contact
Without Foot IK, the character's feet will sink into uneven terrain or hover above it. The Unity Animation Rigging package provides the Two Bone IK Constraint for legs—this is the preferred approach in Unity 2022+. The older approach using OnAnimatorIK + animator.SetIKPosition still works but is less flexible when switching between multiple rigs.
Correct Two Bone IK setup: Effector target is a transform that raycasts to the terrain surface. Hint target is the knee position. Weight is controlled by a curve based on the foot's phase in the step cycle (when lifting off, weight → 0; when contacting, weight → 1). Without this curve, the IK will snap the leg during lift-off.
The foot contact frame in a walk cycle is crucial: exactly at the frame when the foot should touch the ground, it must have zero vertical velocity. This is called the foot plant frame and must be set via Loop Pose curves or manually in the animation editor.
What's Included in a Typical Game Locomotion Set
Minimal set for a third-person action character:
- Idle (2–3 variants with additive breathing layer)
- Walk forward / backward
- Run forward
- Sprint
- Strafe left / right (walk and run)
- Jump start / in-air / land (heavy and light landing)
- Turn in place (45°, 90°, 180°—needed for correct Foot IK)
For mobile projects, the set is often reduced to 6–8 clips with aggressive blending. For AAA projects, we add: crouch locomotion, prone, climb transitions, root motion for turns.
Jump is especially complex—it's not one clip but three or five states: anticipation → take-off → peak → descent → land (+ heavy land at high speed). Transitions between them are controlled by parameters IsGrounded and VerticalVelocity, computed by CharacterController or Rigidbody. If the transition from in-air to land uses a fixed duration instead of Exit Time = 0 with a conditional trigger, the landing will lag or be interrupted.
How to Reduce Animation Debugging Time
Some issues are typical and avoidable. Here is a checklist from our engineers:
- Verify all clips are looped (Loop Pose) with zero offset.
- Ensure root motion is consistently oriented along the Z axis for all clips.
- Set Blend Tree thresholds based on actual velocity, not manual values.
- Use weight curves for Foot IK, not constant values.
Common Locomotion Development Mistakes
- Transitions with fixed duration instead of Exit Time with conditions.
- Missing foot plant frame—foot "floats" at the moment of contact.
- Different tempo (BPM) between walk and run—causes step desynchronization.
- Ignoring IK on uneven terrain—character appears detached from ground.
Our Work Process
First, we analyze references and agree on key parameters: walk/run speed (units per second), jump height, movement style (heavy soldier vs. light ninja). Then we block key poses in Maya or Blender and export test FBX for mapping verification in Unity.
After approving the blocking, we perform spline interpolation and fine-tune secondary motions: arm swing, head bob, torso rotation. The final stage is integration into Animator Controller, setting Blend Tree parameters, testing foot IK, verifying loop points and transition timing.
| Scale | Timeframe |
|---|---|
| Minimal locomotion set (6–8 clips) | 3–7 days |
| Full set for action game (15–20 clips) | 2–4 weeks |
| With Animator integration + IK setup | +3–5 days |
| Locomotion for non-humanoid character | from 3 weeks |
Contact us to assess your project. We'll select the optimal animation set for your budget and timeline. Get a consultation—our engineers are ready to answer questions and propose a turnkey solution.
For more on Blend Trees, see the official Unity documentation.





