summaryrefslogtreecommitdiffstats
path: root/modules/gdscript/gdscript.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'modules/gdscript/gdscript.cpp')
-rw-r--r--modules/gdscript/gdscript.cpp14
1 files changed, 5 insertions, 9 deletions
diff --git a/modules/gdscript/gdscript.cpp b/modules/gdscript/gdscript.cpp
index 88383554b6..de56dd5ece 100644
--- a/modules/gdscript/gdscript.cpp
+++ b/modules/gdscript/gdscript.cpp
@@ -49,11 +49,12 @@
#include "core/config/engine.h"
#include "core/config/project_settings.h"
#include "core/core_constants.h"
-#include "core/core_string_names.h"
#include "core/io/file_access.h"
#include "core/io/file_access_encrypted.h"
#include "core/os/os.h"
+#include "scene/scene_string_names.h"
+
#ifdef TOOLS_ENABLED
#include "editor/editor_paths.h"
#endif
@@ -1995,7 +1996,7 @@ void GDScriptInstance::_call_implicit_ready_recursively(GDScript *p_script) {
Variant GDScriptInstance::callp(const StringName &p_method, const Variant **p_args, int p_argcount, Callable::CallError &r_error) {
GDScript *sptr = script.ptr();
- if (unlikely(p_method == SNAME("_ready"))) {
+ if (unlikely(p_method == SceneStringName(_ready))) {
// Call implicit ready first, including for the super classes recursively.
_call_implicit_ready_recursively(sptr);
}
@@ -2919,7 +2920,7 @@ String ResourceFormatLoaderGDScript::get_resource_type(const String &p_path) con
return "";
}
-void ResourceFormatLoaderGDScript::get_dependencies(const String &p_path, List<String> *r_dependencies, bool p_add_types) {
+void ResourceFormatLoaderGDScript::get_dependencies(const String &p_path, List<String> *p_dependencies, bool p_add_types) {
Ref<FileAccess> file = FileAccess::open(p_path, FileAccess::READ);
ERR_FAIL_COND_MSG(file.is_null(), "Cannot open file '" + p_path + "'.");
@@ -2933,13 +2934,8 @@ void ResourceFormatLoaderGDScript::get_dependencies(const String &p_path, List<S
return;
}
- GDScriptAnalyzer analyzer(&parser);
- if (OK != analyzer.analyze()) {
- return;
- }
-
for (const String &E : parser.get_dependencies()) {
- r_dependencies->push_back(E);
+ p_dependencies->push_back(E);
}
}