From cd8beea3bf12bc3386ceac026dd76f36a7a5036c Mon Sep 17 00:00:00 2001 From: volzhs Date: Wed, 24 Aug 2016 02:19:48 +0900 Subject: [PATCH] Prevent to add node to selection when node is not inside tree (cherry picked from commit 4857eabddb3eda7fef9ee3740a0325265209c640) --- tools/editor/editor_data.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/editor/editor_data.cpp b/tools/editor/editor_data.cpp index 8d3fd6c9c2f..35ec1ebfcca 100644 --- a/tools/editor/editor_data.cpp +++ b/tools/editor/editor_data.cpp @@ -834,7 +834,7 @@ void EditorSelection::_node_removed(Node *p_node) { void EditorSelection::add_node(Node *p_node) { ERR_FAIL_NULL(p_node); - + ERR_FAIL_COND(!p_node->is_inside_tree()); if (selection.has(p_node)) return;