How do I make my character walk backwards?

Hello community,

I’ve been searching on the web for a while, even going through forums to see if I can find the answer to my question, but I’ve had no such luck. So Basically this is my problem:

I’m making a 2.5D fighting game using my own assets and I have it so that the camera works perfectly the way I want it, my jump works and my characters flip depending on which side they are. But when I walk backwards away from the opponent character it still only plays the forward walk animation. I even have a blend with the backwards walk playing at a negative value. The thing is, the Velocity vector is always positive no matter what direction I’m moving in. I was wondering if it’s possible to get the Velocity depending on the Pawns direction so that moving backwards would give it a negative value and if so, how to do it. I started by using the 2D Platformer template if that helps you understand my situation.

I thank anyone for the help in advance.

YES!! Thatnk you Sir. You have no idea how happy you just made me. It works perfectly.

you can try a dot product between the forward vector and the velocity vector (normalised can be better to analyse)
and >0 means forward and <0 means backward (if i’m right)

1 Like

Perfect solution, thanks a lot!