How to properly write player movement script with Root Motion movement?

Hi, this is my problem. I make a Visual Script for Player Movement, I followed this video tutorial.

But, when I use Human Model with Root Motion animation for movement, so I got terrible results, according to the instructions.

How would it be possible to correctly program the 3rd Person Player Movement script when the movement is via Root Motion animation?