Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 1 addition & 4 deletions editor/settings/editor_autoload_settings.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -333,10 +333,7 @@ Node *EditorAutoloadSettings::_create_autoload(const String &p_path) {
Node *n = nullptr;
if (ResourceLoader::get_resource_type(p_path) == "PackedScene") {
// Cache the scene reference before loading it (for cyclic references)
Ref<PackedScene> scn;
scn.instantiate();
scn->set_path(ResourceUID::ensure_path(p_path));
scn->reload_from_file();
Ref<PackedScene> scn = ResourceLoader::load(p_path);
ERR_FAIL_COND_V_MSG(scn.is_null(), nullptr, vformat("Failed to create an autoload, can't load from UID or path: %s.", p_path));

if (scn.is_valid()) {
Expand Down