How do you work with root motion? (MoBu, UDK)

I’m struggling with animations requiring root motion.
At the moment I’m working on a “turn 90 degrees in place” kind of move: the
character tiptoes in one place as it turns to the left. I animated it using
MoBu’s character rig, which drives the skeleton which is used in UDK.

Since the root bone is not controlled by the char rig, it has no animation
whatsoever. The top most bone which has valid animation is the Hips.

I tried to copy the horizontal movement and rotation of the b_Hips bone to
the b_Root bone using a relation constraint. In MoBu the root follows the
hips on the ground, all cool. However after plotting I lose all animations of
both the b_Hips and b_Root. (I understand the hips part as it ends up not
rotating relative to its parent, the root bone.)

My next guess was to drive the b_Root by the HipsEffector’s transforms. In
UDK the char faces the wrong way, halfway through the anim it flips 180
degrees and the root doesn’t move at all.

If I manually rotate and keyframe the root bone then that motions gets
through.

Any suggestions?
Generally how do you deal with root motion?

Manually plotting only the b_Root bone fixes everything. Now I just need to fix
my exporter to do this automatically.

I don’t know that rig or UDK, but in Unity, what I’ve done is have an additional bone that tracks the hips’ offset from the root. It stays on the floor and can be used to sync the real root with the visual location of the character, and the character can be animated off origin without moving the root itself.

So put a bone in your rig that’s just called “motion” and have it skinned to no verts and be a child of Root. Then when you want to move the character off of the origin, move this to match the ground plane location of the hips.

In code you can use its offset from the real root to back-transform the hips and then move the root to its location.

Basically, without this bone, you cannot move your character off of the origin because it will never be able to find its way back reliably. Or rather, it will have to find its way back through explicit animation, and code won’t be able to do it.

Again, I don’t know how this relates to UDK. In Unity, you’d need to script code yourself to do this back-transforming. The assumption is that most of the time the game is controlling the character’s position, but you allow the anims to “nudge” the root through that bone.

Hmm interesting… As far as I can tell from the docs, Unreal is strict about
moving the root bone. A dedicated bone would be a cleaner solution tho,
especially when animating directly the skeleton and not a control rig above it.