1
0
mirror of https://github.com/godotengine/godot.git synced 2025-11-21 14:57:09 +00:00

Misc script editor code cleanup

This commit is contained in:
kobewi
2024-07-07 00:14:39 +02:00
parent 019889d1da
commit 89432600ce
3 changed files with 3 additions and 18 deletions

View File

@@ -673,8 +673,8 @@ void RemoteDebugger::poll_events(bool p_is_idle) {
reload_all_scripts = false;
} else if (!script_paths_to_reload.is_empty()) {
Array scripts_to_reload;
for (int i = 0; i < script_paths_to_reload.size(); ++i) {
String path = script_paths_to_reload[i];
for (const Variant &v : script_paths_to_reload) {
const String &path = v;
Error err = OK;
Ref<Script> script = ResourceLoader::load(path, "", ResourceFormatLoader::CACHE_MODE_REUSE, &err);
ERR_CONTINUE_MSG(err != OK, vformat("Could not reload script '%s': %s", path, error_names[err]));