aboutsummaryrefslogtreecommitdiff
path: root/tools/editor/editor_node.cpp
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--tools/editor/editor_node.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/tools/editor/editor_node.cpp b/tools/editor/editor_node.cpp
index 9f3c57b0d..7b44f2cad 100644
--- a/tools/editor/editor_node.cpp
+++ b/tools/editor/editor_node.cpp
@@ -3047,7 +3047,7 @@ Error EditorNode::load_scene(const String& p_scene) {
//_cleanup_scene(); // i'm sorry but this MUST happen to avoid modified resources to not be reloaded.
- Ref<PackedScene> sdata = ResourceLoader::load(lpath);
+ Ref<PackedScene> sdata = ResourceLoader::load(lpath,"",true);
if (!sdata.is_valid()) {
current_option=-1;
@@ -3064,6 +3064,8 @@ Error EditorNode::load_scene(const String& p_scene) {
return ERR_FILE_NOT_FOUND;
}
+ sdata->set_path(lpath,true); //take over path
+
Node*new_scene=sdata->instance(true);
if (!new_scene) {