Browse Source

Merge pull request #87711 from matthew1006/threaded-loading-progress-fix

Fix `ResourceLoader.load_threaded_get_status` returning `[0]` constantly in exported projects.
Rémi Verschelde 1 năm trước cách đây
mục cha
commit
3dfedd69ea
1 tập tin đã thay đổi với 2 bổ sung2 xóa
  1. 2 2
      core/io/resource_loader.cpp

+ 2 - 2
core/io/resource_loader.cpp

@@ -244,11 +244,11 @@ Ref<Resource> ResourceLoader::_load(const String &p_path, const String &p_origin
 		thread_load_mutex.lock();
 		HashMap<String, ThreadLoadTask>::Iterator E = thread_load_tasks.find(load_paths_stack->get(load_paths_stack->size() - 1));
 		if (E) {
-			E->value.sub_tasks.insert(p_path);
+			E->value.sub_tasks.insert(p_original_path);
 		}
 		thread_load_mutex.unlock();
 	}
-	load_paths_stack->push_back(p_path);
+	load_paths_stack->push_back(p_original_path);
 
 	// Try all loaders and pick the first match for the type hint
 	bool found = false;