summaryrefslogtreecommitdiff
path: root/editor
diff options
context:
space:
mode:
Diffstat (limited to 'editor')
-rw-r--r--editor/plugins/animation_player_editor_plugin.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/editor/plugins/animation_player_editor_plugin.cpp b/editor/plugins/animation_player_editor_plugin.cpp
index 60ef88d2e3..75a7099ec4 100644
--- a/editor/plugins/animation_player_editor_plugin.cpp
+++ b/editor/plugins/animation_player_editor_plugin.cpp
@@ -1077,12 +1077,16 @@ void AnimationPlayerEditor::_animation_key_editor_seek(float p_pos, bool p_drag)
if (!is_visible_in_tree())
return;
+
if (!player)
return;
if (player->is_playing())
return;
+ if (!player->has_animation(player->get_assigned_animation()))
+ return;
+
Ref<Animation> anim = player->get_animation(player->get_assigned_animation());
updating = true;