AI looks like they are sliding across the floor

Hi everyone,

I’m fairly new to UE and have spent two to three months trying to learn it.

I have a character model downloaded from Mixamo along with some of its walking animations for an AI enemy.

I’m currently stuck on a problem where my AI enemy movements look unnatural as they look like they are sliding across the floor as their walking animation plays.

At first I thought it was a Root Motion problem, so I checked the Enable Root Motion box, and on top of that, re-did the Maximo mesh such that it had a proper Root bone instead of having its Hip bone at the top of the hierarchy.

However, after doing all that, my character still looks like it’s sliding. I am new to in-engine animations, and would like to know how to make my AI enemies’ movements look natural (like their feet are actually planted on the ground as they move).

Side Question: How does the AI’s movement speed play into this? Does enabling root motion solve the animations for if it has, e.g. 600m/s vs 200m/s (animation will be slowed down and root motion data will be shortened?) ?

1 Like

Hey @r4kujin!

That’s usually a problem with animations not matching the movement. With the way your character shuffles, it may be best to stick with root motion animations only, especially since there is such a long drag after the foot is planted.

I hope the above points you in the direction you need!

Thank you for the reply!

However, I’m still not quite sure what to do, as the animations in the above video already has Root Motion applied (Enable Root Motion + Force Root Lock checked).

Could I possibly be doing Root Motion wrong? Maybe some conceptual error somewhere?

Here’s a more detailed breakdown of what I did:

Downloaded Maximo model + animations → added Root bone to the Maximo model in Blender → imported new model and animations into UE → checked the ‘Enable Root Motion’ + ‘Force Root Lock’ in all imported animation sequences → applied animations in blendspace and animBP of the model → assigned said animBP to my enemy AI BP with the new model as its mesh

Even after all this, my enemy AI still slide-walks as shown in the video. I also set it such that all tasks in my Behavior Tree will only set the enemy’s move speed to the same 100m/s to ensure that it’s a constant factor.

Hey @r4kujin,

So that could be a solution for your other movements (where your character moves both feet) however, the key issue is that your forward movement actually steps forward, stops, then steps again. The movement is not constant so constant speed will appear as sliding. Check out this non-Epic affiliated example of how to set up a custom AI movement system that implements Root Motion:

Let me know if this works for you!

Thanks so much for the two videos! I’ve taken a look at both of them and they seem to be implementing their own AI movement system. It looks promising, since what the person in the video was saying is that the animation will drive the actual physical movement of the mesh, which is what I’m looking for.

However, before I conclude this question, I would like to ask: how exactly does the system ‘drive’ the actual movement in his implementation? As far as I can tell with my limited knowledge, he is setting path points from a navigation node, and then using Get Unit Direction (Vector) to actually move the AI. How does this differ from the AIMoveTo node which makes it such that the animation drives the mesh instead of the animation just playing and needing to adjust to the mesh that is moving separately?

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.