summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRĂ©mi Verschelde <rverschelde@gmail.com>2019-09-30 11:03:29 +0200
committerGitHub <noreply@github.com>2019-09-30 11:03:29 +0200
commit680bcb1ef45c67da1b58ff3be84ca5e4fd1e40cf (patch)
treef6957a01dcb82a18301486bcb4869fa25b782ab9
parentcb984b3f5f352368956473910ad331d6070997f8 (diff)
parent168f6cd975278122e9b3d06c2942c83509fa785d (diff)
Merge pull request #32434 from willnationsdev/script-class-no-plugins
Fix plugin script classes defined even if inactive.
-rw-r--r--editor/editor_file_system.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/editor/editor_file_system.cpp b/editor/editor_file_system.cpp
index 3663bdee27..5ea7081667 100644
--- a/editor/editor_file_system.cpp
+++ b/editor/editor_file_system.cpp
@@ -1411,6 +1411,9 @@ String EditorFileSystem::_get_global_script_class(const String &p_type, const St
}
void EditorFileSystem::_scan_script_classes(EditorFileSystemDirectory *p_dir) {
+ if (p_dir->parent && p_dir->parent->name == "addons" && !EditorNode::get_singleton()->is_addon_plugin_enabled(p_dir->name)) {
+ return;
+ }
int filecount = p_dir->files.size();
const EditorFileSystemDirectory::FileInfo *const *files = p_dir->files.ptr();
for (int i = 0; i < filecount; i++) {