Ok so heres my problem ive been acurring in ANIMATION thing

:information_source: Attention Topic was automatically imported from the old Question2Answer platform.
:bust_in_silhouette: Asked By Dandevuni

When i add anumation in my input.is_action_pressed(“forward”) amd then i do animationplayer.play(“the animation”) and then i wana make like a sprint input,input.is_action_pressed(" SPRINT ") and the animation of sprint but the animation of the sprint just dont play,itnjust stuck and its still moving,if you dont understand,ask me mirr

:bust_in_silhouette: Reply From: Inces

Your desciption is barely understandable, but I think I get it. You check input continously, so as long as You press SPRINT your animation tries to play starting from frame 0. You need to add some boolean condition for sprinting, so it starts ONCE when You press sprint and ends when You release it.

Could you show an example because im still a bigginer huhu

Dandevuni | 2021-03-20 02:06

:bust_in_silhouette: Reply From: Mrpaolosarino
if Input.is_action_pressed("Sprint"):
      if $Animationplayer.play("the_animation") == false:
            $Animationplayer.play()

this will constantly loop the animation if you are sprinting and if it stop then it will play again