Преглед на файлове

Merge pull request #51890 from fabriceci/crash-animation-blend-tree

Fix 51889 that cause a crash when you click on an AnimationTree that contains an invalid node
Rémi Verschelde преди 4 години
родител
ревизия
fb8487e011
променени са 1 файла, в които са добавени 1 реда и са изтрити 0 реда
  1. 1 0
      editor/plugins/animation_blend_tree_editor_plugin.cpp

+ 1 - 0
editor/plugins/animation_blend_tree_editor_plugin.cpp

@@ -126,6 +126,7 @@ void AnimationNodeBlendTreeEditor::_update_graph() {
 		graph->add_child(node);
 
 		Ref<AnimationNode> agnode = blend_tree->get_node(E);
+		ERR_CONTINUE(!agnode.is_valid());
 
 		node->set_position_offset(blend_tree->get_node_position(E) * EDSCALE);