Skip to content

Commit

Permalink
Fix AnimationTree(AnimationNodeStateMachine) error reported in the ed…
Browse files Browse the repository at this point in the history
…itor
  • Loading branch information
magian1127 committed Jul 17, 2023
1 parent cb7730c commit 3c01a43
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions editor/plugins/animation_tree_editor_plugin.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -241,12 +241,12 @@ bool AnimationTreeEditor::can_edit(const Ref<AnimationNode> &p_node) const {
}

Vector<String> AnimationTreeEditor::get_animation_list() {
if (!singleton->is_visible()) {
AnimationTree *tree = singleton->tree;
if (!tree) {
return Vector<String>();
}

AnimationTree *tree = singleton->tree;
if (!tree || !tree->has_node(tree->get_animation_player())) {
if (!singleton->is_visible() || !tree->has_node(tree->get_animation_player())) {
return Vector<String>();
}

Expand Down

0 comments on commit 3c01a43

Please sign in to comment.