diff options
Diffstat (limited to 'core/io/resource_loader.h')
-rw-r--r-- | core/io/resource_loader.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/core/io/resource_loader.h b/core/io/resource_loader.h index 11abb4dc18..c48f39b5cc 100644 --- a/core/io/resource_loader.h +++ b/core/io/resource_loader.h @@ -187,6 +187,7 @@ private: static thread_local int load_nesting; static thread_local WorkerThreadPool::TaskID caller_task_id; + static thread_local HashMap<int, HashMap<String, Ref<Resource>>> res_ref_overrides; // Outermost key is nesting level. static thread_local Vector<String> *load_paths_stack; // A pointer to avoid broken TLS implementations from double-running the destructor. static SafeBinaryMutex<BINARY_MUTEX_TAG> thread_load_mutex; static HashMap<String, ThreadLoadTask> thread_load_tasks; @@ -272,6 +273,9 @@ public: static void set_create_missing_resources_if_class_unavailable(bool p_enable); _FORCE_INLINE_ static bool is_creating_missing_resources_if_class_unavailable_enabled() { return create_missing_resources_if_class_unavailable; } + static Ref<Resource> ensure_resource_ref_override_for_outer_load(const String &p_path, const String &p_res_type); + static Ref<Resource> get_resource_ref_override(const String &p_path); + static bool is_cleaning_tasks(); static void initialize(); |