Dodge, random chance

Hello everyone I want to make it so that when a character is attacked, he has a chance to dodge, use animation and move away from the player. But, he moves only one pixel. If you remove “trigger once”, the number will be generated many times. Please help, friends

You are applying an instant force when you move the thug object. The conditions only allow for this event to get actioned once because of the the Dodge variable on Thug.

You may need to add a second boolean object variable to indicate the Thug is dodging, and apply the force while that’s true.

1 Like

Thank you!

1 Like