Browse Source

Merge pull request #105797 from bruvzg/scroll_crash

Fix `AnimationNodeBlendTree` crash on `Open Editor` button press.
Thaddeus Crews 4 months ago
parent
commit
7c35e3999d
1 changed files with 5 additions and 0 deletions
  1. 5 0
      editor/plugins/animation_blend_tree_editor_plugin.cpp

+ 5 - 0
editor/plugins/animation_blend_tree_editor_plugin.cpp

@@ -1024,6 +1024,11 @@ void AnimationNodeBlendTreeEditor::_scroll_changed(const Vector2 &p_scroll) {
 	if (updating) {
 		return;
 	}
+
+	if (blend_tree.is_null()) {
+		return;
+	}
+
 	updating = true;
 	blend_tree->set_graph_offset(p_scroll / EDSCALE);
 	updating = false;