+1 vote

I have a roll animation that I want to be played in reverse when moving backwards.
I tried to use play_backwards instead of play however the animation doesn't show up all.

I have also tried play("animation", -1, -1, true) to the same result. What could be causing this? Im using a state machine. Perhaps something in the transition state code.

Godot version 3
in Engine by (46 points)

Try it while moving forward.
Check if it is working

yeah i tried, not sure what the problem is, ive never been able to get play backwards to work since i started. Maybe my animationplayer is bugged.

Can you add part of the script?

func heavyattack():
attack
timer.stop()
attacktimer.start()
attack
finished = false
backswingfinished = false
if is
onfloor():
if Input.is
actionpressed("heavyattack"):
animplayer.playbackwards("Attack3")
if moveinputspeed == 0:
velocity.x = velocity.x + 140 * facing

in the state machine pressing heavy attack switches state(with delta) to in enter_state
heavyattack() is called. When idling and pressing heavy attack the animation doesnt play, and flickers some anim. But when Im running and press heavy attack, weirdly the run animation plays backwards, and then the heavy attack anim plays backwards.

Please log in or register to answer this question.

Welcome to Godot Engine Q&A, where you can ask questions and receive answers from other members of the community.

Please make sure to read How to use this Q&A? before posting your first questions.
Social login is currently unavailable. If you've previously logged in with a Facebook or GitHub account, use the I forgot my password link in the login box to set a password for your account. If you still can't access your account, send an email to webmaster@godotengine.org with your username.