summaryrefslogtreecommitdiff
path: root/modules
diff options
context:
space:
mode:
authorIgnacio Etcheverry <ignalfonsore@gmail.com>2019-11-29 01:35:46 +0100
committerIgnacio Etcheverry <ignalfonsore@gmail.com>2019-11-29 01:35:46 +0100
commit85d8c427639554e67597daca577aa0509097263e (patch)
tree7147b4dc296701c743c1e026bbab547b2abf2595 /modules
parent7735af7e768e16efb4b3b6de1c72c3dfb50c9412 (diff)
Mono/C#: Fix crash on exported games that don't use C#
Diffstat (limited to 'modules')
-rw-r--r--modules/mono/csharp_script.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/modules/mono/csharp_script.cpp b/modules/mono/csharp_script.cpp
index 34dcde40f4..4536614379 100644
--- a/modules/mono/csharp_script.cpp
+++ b/modules/mono/csharp_script.cpp
@@ -128,7 +128,8 @@ void CSharpLanguage::init() {
print_line("Run this binary with '--generate-mono-glue path/to/modules/mono/glue'");
#endif
- gdmono->initialize_load_assemblies();
+ if (gdmono->is_runtime_initialized())
+ gdmono->initialize_load_assemblies();
#ifdef TOOLS_ENABLED
EditorNode::add_init_callback(&_editor_init_callback);