mirror of
https://github.com/godotengine/godot
synced 2024-11-02 09:38:07 +00:00
Merge pull request #72257 from KoBeWi/potential_fix_or_maybe_not_who_knows
Fix sub-resource IDs resetting when preloaded
This commit is contained in:
commit
07d46da485
1 changed files with 5 additions and 3 deletions
|
@ -601,9 +601,11 @@ Error ResourceLoaderText::load() {
|
|||
*progress = resource_current / float(resources_total);
|
||||
}
|
||||
|
||||
int_resources[id] = res; //always assign int resources
|
||||
if (do_assign && cache_mode != ResourceFormatLoader::CACHE_MODE_IGNORE) {
|
||||
res->set_path(path, cache_mode == ResourceFormatLoader::CACHE_MODE_REPLACE);
|
||||
int_resources[id] = res; // Always assign int resources.
|
||||
if (do_assign) {
|
||||
if (cache_mode != ResourceFormatLoader::CACHE_MODE_IGNORE) {
|
||||
res->set_path(path, cache_mode == ResourceFormatLoader::CACHE_MODE_REPLACE);
|
||||
}
|
||||
res->set_scene_unique_id(id);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue