This code makes it so the bandit does an attack animation when you are within 100 pixels from it. The first time the attack animation occurs, it works, but the second time the attack animation occurs, the first frame is drawn out by 4-5 times its length. After the second time, the animations works as expected continuously.
Can anyone see anything I'm doing wrong here?
I have an event below that you cannot see that basically says if bandit is Attacking, Set Animation to "Attack". Below that I have On Animation "Attack" finished, Set Attacking to false and Chasing to true.
Any help would be greatly appreciated. Thanks!