I haven't worked with animation so this might not work but i would have a variable that would get set to 1 when the event collision happens, then change the while (1) to while (collision_var = 1). and when death_percentage = 100 change collision_var to 0. thats the only way i can think off, im sure there are better ways though.


Wait, there isn't a "Make My Game Now" button?