Animation not loop correctly

Godot Version

godot 4.5

Question

I tried to add a shooting animation, but when testing it, only the first frame loops.

if Input.is_action_pressed("shot"):
		animated_sprite.play("Shooting")
		shoot_sound.play()

Try using is_action_just_pressed also you can check that is the animation playing or not if you are making an auto gun:

!is_playing or something like that.

1 Like

Your action is being triggered indefinitely, so it keeps restarting on frame 1.

If Frozens method doesnt work, try using a variable as a quick countdown. That will act as a buffer in between instances; and allow your animation to play in full.

1 Like