Stopping player to change direction when one animation is playing?

The problem i am facing is whenever any animation of player is getting played (EX:: Hitting) and i press any of the movement controls it changes it direction to the assigned key direction. How can i stop this?

IF you have condition

D key is pressed
Change direction to right
Then add to it condition
Animation is not equal to Hitting

It is working but there is one problem first when i try to put if One of these condition are true then it doesn’t work
and second player can still move but without changing direction

Because you would need to move simulate action to sub event
Right now its not checking if state is NOT TreeHit to allow simulate pressing right
It only checks if its NOT TreeHit to change Direction variable to right

if it is like this it is working but if it is like the one below it’s not working

In 2nd screenshot you are checking if ONE OF THESE conditions is true
SO it does not care for all of them if at least 1 is returning true

SO you need to remove if one of these conditions is true
And simply leave all that conditions there

Yes finally it is working. Thank you!!

1 Like