diff --git a/editor/editor_node.cpp b/editor/editor_node.cpp index 4e3b3fcc904..3c1b1fd1d0b 100644 --- a/editor/editor_node.cpp +++ b/editor/editor_node.cpp @@ -3577,7 +3577,9 @@ void EditorNode::set_current_scene(int p_idx) { _update_title(); _update_scene_tabs(); - call_deferred(SNAME("_set_main_scene_state"), state, get_edited_scene()); // Do after everything else is done setting up. + if (tabs_to_close.is_empty()) { + call_deferred(SNAME("_set_main_scene_state"), state, get_edited_scene()); // Do after everything else is done setting up. + } } void EditorNode::setup_color_picker(ColorPicker *p_picker) {