MCPcopy Create free account
hub / github.com/GDRETools/gdsdecomp / get_cached_script_class

Method get_cached_script_class

utility/gdre_settings.cpp:1209–1224  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1207}
1208
1209StringName GDRESettings::get_cached_script_class(const String &p_path) {
1210 if (!is_pack_loaded() || p_path.is_empty()) {
1211 return "";
1212 }
1213 String path = p_path;
1214 if (!script_cache.has(path)) {
1215 path = get_mapped_path(p_path);
1216 }
1217 if (script_cache.has(path)) {
1218 auto &dict = script_cache.get(path);
1219 if (dict.has("class")) {
1220 return dict["class"];
1221 }
1222 }
1223 return "";
1224}
1225
1226StringName GDRESettings::get_cached_script_base(const String &p_path) {
1227 if (!is_pack_loaded() || p_path.is_empty()) {

Callers 2

get_global_nameMethod · 0.80

Calls 1

getMethod · 0.45

Tested by

no test coverage detected