0 votes

Hi geniuses on this section, this is very weird, I have a animationplayer which has a node lined 2d, I want it to decrease in length while the time is running, when button paused, it should pause the animation, when button resumed, it should go on by the position before pause.

There are actually two problems,
1. the animationplayer doesnt stop, I tried stop(true) and (false) and none works,
2. the resume doesn not work, I tried using code 1 when paused and code 2 when resumed.

code 1

PausePosition = $AnimationPlayer.get_current_animation_position()

code 2

$AnimationPlayer.seek(PausePosition, true)

Any help is appreciated!

in Engine by (35 points)

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.