@icqqq said:
I am new to the concept of root motion.
All I know is with root motion, my character will move in godot as in the animation designed in blender.
So my concern is, without root motion, I can move my character in godot by my speed variable, which I can tune in godot editior.
While with root motion, the speed of character depends on the animation edited in blender, which I think I cannot tune in godot editor.
As far as I know, this is correct. Godot will move the character according to the movement of the root bone in a animation.
So my question is, what is the advantage and disadvantage to use root motion in character controller?
I think the biggest advantage to using root motion is that it makes your player's movements feel more lifelike, as the player moves along with the animations, putting the two in sync. It also makes more complicated motions, like slides and jumps, feel a little more grounded as the physics sync up with the visuals in a way that is much harder to do without using root motion.
However, as you mentioned, a huge downside to using root motion is to change the speed of each animation, you have to change the animation in something like Blender. This makes using root motion animations fairly time consuming depending on how complex your animations needs are for your game.
or should I use root motion for some specific animations, while for other animations, like run cycle or walk cycle, I don't need to use root motion?
As far as I know, you can mix and match root motion animations with normal animations (animations with no root motion).
So if you want, you can add root motion to animations that need it, and not for animations that do not need root motion.
Then in Godot you can control the movement through a script for the animations that do not have root motion. The hard part will be not applying any motion when a animation with root motion is playing, and then resuming motion when a animation without root motion is playing. I imagine it is doable though!
I should mention that I have very little working experience with root motion. I have read up on how it works, and even seen some cool examples, but I have never really had the opportunity to use/create root motion animations myself.
The best way to know for sure would be to test and see what works best for your project(s).
I would suggest making a simple root motion animation and see what you think. From what I remember, the hardest part with making root motion animations is keeping the relative speeds of each animation somewhat consistent (you do not want your walking animation to travel farther than your running animation)
I would offer a more concrete answer, but honestly I have little experience using root motion animations. Once Godot 3.1 comes out, I plan on giving it a try, but until then I can only speculate based on experience working with other game engines.