Foot locking (aka toe pinning) is a technique used to reduce foot sliding in character locomotion. Foot sliding causes characters to appear as they are floating or skating across the surface making the motion look un-realistic and impeding immersion. By locking the foot when it is intended to be grounded, some amount of foot sliding can be mitigated. This technique is very powerful when coupled with motion matching as it eliminates the foot sliding caused by blending so many animations in sequence.
How It Works
Foot locking uses IK to lock the toe of the foot in world space whenever the foot is intended to be grounded. When the foot touches the ground, its world position is saved and every subsequent frame it is moved back to that position (via IK) until the foot is released. As the foot can change profile while it is grounded, i.e. the heel raising and lowering, it is actually the toe position that is locked in world space. In order to achieve this the offset from the ankle to the toe is measured and applied to the world position before locking the ankle in place. This allows the foot to still rotate around the ball while grounded.
The foot locking node takes two boolean inputs which specify if the left and/or right foot are either locked or not. When locked the locking will occur immediately at the current position of the toe. When un-locked the foot will release gradually over time so that it does not snap and appear jittery. Essentially the foot position will be interpolated between the lock position and the actual position of the foot in order to provide smoothing, the rate of which can be adjusted in the node settings.
How the two boolean inputs are determined is arbitrary and can be decided by the user. However, The foot locker comes with utility AnimNotifies and an actor component which can assist with tracking foot locking. More details on the component and AnimNotifies can be found in subsequent sections of the documentation.
Limitations
Foot locking is not without its limitations. Sometimes the disparity between animation and movement is so great that locking the foot in world space will degrade the overall animation to an unacceptable level resulting in awkward poses or hyper-extension of the legs. The foot locker node includes options to limit the foot locking and allow the foot to slide where necessary. At some point it is better to let the foot slide then to degrade the overall pose of the character. More details on how to configure this can be found in the Foot Locking Node section of this documentation.