Moving character's root part in an animation via scripts

Before moving forward with my animations I am trying to figure out how to approach moving the humanoid root part through scripts. In some animations, the character’s torso rotates and changes position radically which when played only moves the character but not the camera/POV. I need the humanoid root part to keep up with the animation so that the camera and final player position/rotation changes as the animation plays through.

To do this, I’m looking through two different approaches. I can either redo all my animations so that the torso stays at the origin and instead use a script to animate the player’s position/rotation. It’s either this, or I can keep the animations as is (ie. torso position is varied through the animation) and extract the torso’s transforms from them. I can then use these transforms to animate the humanoid root part in a script. Does anyone have a recommendation on which approach I should use? This is for a combat game if that matters.

1 Like