Feet won't stay planted with humanoid rig (video included)

Hi guys, I’m trying to wrap my head around humanoid rigs and retargetting animation. I’ve been able to figure out (more or less) how retargetting works and exported model and animations seperately using maya LT’s game exporter.

My problem occurs in unity, where it seems to use the hips as the root of the character instead of at the feet. You can see the video here: https://drive.google.com/open?id=0B12Fjjh-p8DPVktoaXdBZzNlZEE Ignore the bad animation, it was just for testing purposes. The important part is that the character should be moving down, and not moving his legs up.

I’m assuming that there is something I’m missing either in the rig, or in the import/export settings in the respective software. I did try to change the various bake into pose-settings for the animation, but has little to no effect.

Any insight into this would be super helpful. Lastly, here’s an image of the rig setup (at least the most important parts of it).

Check what root node you have selected in Unity, should be a root node the hips are parented to, and also make sure you have IK turned on, on the animation.
In the future if showing a hierarchy - the animation controls clutter the understanding of the bone structure. Best to just show the bone hierarchy.
Which raises a good question - what are you including in the export, the entire rig within Unity? It should only consist of the bones and mesh instead of all the controls, bindings, off sets, and constraints. Unity only needs/cares about the bones and skin.

2 Likes

Absolutly right, if you import all those bones, unity need to compute each frame the global/local position of all those extra bone that are useless in unity, so you’re lossing alot of cpu cycle for something that you don’t use.

Better to cleanup you’re rig before using it.

Thank you guys for some quick answers! I’ve been working on cleaning up my rig and I’ll update you on how that works out once I’m done with it. Just for testing purposes, I figured I’d try Maya’s Quick Rig setup. Through that I also discovered that my mesh was way too small, so there might be issues related to that as well. When retargeting the animations from the rig over to the character, it is still somewhat unprecise. The feet are not staying still as they do in Maya (See video), and I’d appreciate if someone would enlighten me to what I’m doing wrong. This time I made sure to only include what I needed.

I’m not actually going to use the quick rig for the project since it doesn’t have a reverse foot roll and some other things, but it’s not unlikely I’ll see this problem with my custom rig as well. Appreciate the help!

There is a button to turn on IK somewhere. I think it’s in the inspector when the animation is selected, but I don’t have Unity in front of me right now, might be somewhere else, or with the character selected.

Sorry I can’t be more precise, I don’t have this issue with humanoid rigged characters.

The only IK that I could turn on/off that I could find was the one in the image, but it doesn’t seem to change anything.

apologies for the double post, I did find another place to turn on IK in the animator, but it didn’t do anything either.

Having said that - right now we’ve been using a locator from Maya and at one point a group as the root of the character. Since the HumanIK also seems to only use a locator for its rig’s root, I thought it could work, but it did not. The feet simply will not stay planted. The locator doesn’t do anything besides being at the top level of the hierarchy, so I’m thinking I need to do something about it, but I’m not certain what exactly. Here’s a better overview of the joint structure:

I cant be specific because Im a Max artist, however it sounds like you are trying to use some ‘fancy’ dedicated content creation tools/features that are not supported in Unity or any other game engines.
Suggestion; Make a simple leg rig with a simple IK handle at the ankle. If you feel sparky you can create a 3 point reverse foot setup, which is basically 3 overlapping IK chains that articulate exactly like a leg and foot does. But ONLY create it with bones and IK goals/chains.
Animate the squatting animation .
Skin a simple cylinder leg/foot to the rig and export as usual, fbx.
Import into Unity, the simple animation should work as expected if the root is set to the top most hierarchical bone.

The only tool we’ve been trying out is the quick rig which works with Unity right out of the box, however, it’s missing some important components so we’re not going to use it. As far as the foot goes, it is set up with 3 IKs as you mention, nothing more than that. So the problem still remains - the feet are still being lifted from the ground instead of the hip moving down.

When checking the hierarchy of the two. I noticed that the quick rig (which works) has this set-up:

Rig

  • Hips

  • Spine

  • LeftUpLeg

  • RightUpLeg
    …and so forth

While mine is:

Rig

  • Root

  • Hips

  • LeftUpLeg

  • RightUpLeg
    …and so forth

I tried to simply move the hips out of the root group, however it didn’t seem to have any effect. I’ll update once I make any further progress. One interesting thing to note is that the Animator.Root T.y (which is the humanoid set up name for the hips y translation as far as I can gather) has opposite curves from the Quick Rig and our own custom rig. We checked the orientation of the axis within maya and they are also the same.

It seems we were able to find a solution to the problem. After selecting all the joints, we baked the animation into them. I was able to create a simple rig in Blender that also worked where I didn’t have to bake the animation in any way, so I’m guessing this is a Maya-specific issue? If anyone knows more about this I’d love to know. Also considering that the maya quick rig works without baking, I’m curious as to why that is.

The bake animation can be found under: animation > key > bake animation

1 Like

Hey Helge - glad you found a solution. I think the baking is needed because the animation keys are on the rig components rather than directly on the bones themselves, in Maya. Like I said - not sure because I’m a Max artist, but I like to help when I can especially when we are discussing ‘like’ content, like animations.

1 Like

Hi @Helgemonster !!
Could you explain how you got from the first state (hips not moving and feet floaiting) to the second state (hips going down even though feets shakes) I can’t solve this problem for myself.

I also have my hips going down through the ground, in addition of not moving in translation(rotation seem to work)
It’s pretty annoying since I am already using the bake and exporting the bones only.

Thanks !!

Hi i have a similar problem. Feet seams to be floating and wont stay still (it’s not very obvious but I don’t like it). I am a Max user and I made my rig with CAT.

Any ideas?

4238998--377260--GIF.gif

4238998--377263--GIF2.gif

This has been an issue for such a long time - I would love to see a consistent reason as to why it happens.

1 Like

Could be animation compression (such as keyframe reduction) in the animation import settings.Unity - Manual: Animation tab

1 Like

You have to be kidding me. lol.

THIS. In the context of using CAT in 3dsmax. Turning off compression fixed it for me.

I have the same problem, tried to bake the animation, delete all extra bones, turn off compression and play with every single option in the inspector but none of that worked. Its like the humanoid thinks the hips bone is the root so the IKs are broken. What can I do?