Fix ResourceLoader.has_cached() and ResourceLoader.get_cached_ref() not handling UIDs.
This commit is contained in:
parent
7b1ed520bd
commit
9014cdb596
3 changed files with 10 additions and 3 deletions
|
|
@ -113,12 +113,12 @@ PackedStringArray ResourceLoader::get_dependencies(const String &p_path) {
|
|||
}
|
||||
|
||||
bool ResourceLoader::has_cached(const String &p_path) {
|
||||
String local_path = ProjectSettings::get_singleton()->localize_path(p_path);
|
||||
String local_path = ::ResourceLoader::_validate_local_path(p_path);
|
||||
return ResourceCache::has(local_path);
|
||||
}
|
||||
|
||||
Ref<Resource> ResourceLoader::get_cached_ref(const String &p_path) {
|
||||
String local_path = ProjectSettings::get_singleton()->localize_path(p_path);
|
||||
String local_path = ::ResourceLoader::_validate_local_path(p_path);
|
||||
return ResourceCache::get_ref(local_path);
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue