Sticking To Your Roots


The Problem: Where's the Root?!?

So this week we decided that we needed to swap player avatars. The model we were using came with a weapon as part of the mesh, and that was a problem because we were unable to remove it from the mesh to replace it with a new weapon that the player might pick up when playing, like a different sword or a bow. So we needed to find a new model as well as animations to use. It did not take long to find a new model and animations to use, thankfully.

However, making such a big change came with its own problems, of course. Both the model and animation did not have a proper root joint in their skeletons. This meant that having proper root motion animations would be difficult and caused some animations to look off or just plain bad. The animations would cause the mesh to move from the initial position and when it ended it would slingshot back to that position.

The Solution: The Hip bone's connected to the... Root bone

My initial solution was to check off the Force Root lock flag on the animation which prevented the mesh from moving away but that caused the animation to look incorrect. To fix this I had to learn how to add new joints to skeletons and animations in Maya. So, I created a new root node for the skeletal mesh and every animation I needed for the player. For this node, I removed the x and z translation of the previous "root" node and applied it to the new root node so, for example, when the run animation played, the colliders and everything else would move along with it.

Get Lucifer's Hordes

Leave a comment

Log in with itch.io to leave a comment.