Animation doesn't play fully

Godot Version

I forgort but its probably 4

Question

Just a small issue with a 2D platformer but with my falling animation it freezes on the first frame and never actually plays. The code looks like this:
if not is_on_floor():
if velocity.y > 0:
animated_sprite_2d.play(“fall”)
else:
animated_sprite_2d.play(‘jump’)

Any idea for how to fix it?

I was able to fix it myself. For anyone who has the same problem, I figured out that animations don’t play fully if there’s another animation that’s playing over it. Like two of them being played at the same time.

I fixed it by adding to my other anim code: “if not abs(velocity.y) > 0:” and it worked.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.