summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLuiz <luizcarlos1405@gmail.com>2019-02-14 15:32:29 -0300
committerLuiz <luizcarlos1405@gmail.com>2019-02-14 15:32:29 -0300
commit5ec4f14a245b66b3e268f3c6cbb68a85336c7ca6 (patch)
treec57a6d57dd3f701d18ec949fe9d3dc474b851bf3
parent89eb79aef1aac645358664a8245afe35b30da130 (diff)
Fix AnimationPlayer bug where it wouldn't reset its position when finished
-rw-r--r--scene/animation/animation_player.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/scene/animation/animation_player.cpp b/scene/animation/animation_player.cpp
index 86fd1ef14c..992eb365ed 100644
--- a/scene/animation/animation_player.cpp
+++ b/scene/animation/animation_player.cpp
@@ -938,6 +938,7 @@ void AnimationPlayer::_animation_process(float p_delta) {
} else {
//stop();
playing = false;
+ playback.current.pos = 0;
_set_process(false);
if (end_notify)
emit_signal(SceneStringNames::get_singleton()->animation_finished, playback.assigned);