summaryrefslogtreecommitdiff
path: root/tools/editor
diff options
context:
space:
mode:
Diffstat (limited to 'tools/editor')
-rw-r--r--tools/editor/editor_data.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/tools/editor/editor_data.cpp b/tools/editor/editor_data.cpp
index 8d3fd6c9c2..35ec1ebfcc 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;