summaryrefslogtreecommitdiffstats
path: root/modules/mono/csharp_script.cpp
diff options
context:
space:
mode:
authorDanil Alexeev <danil@alexeev.xyz>2023-08-18 07:35:58 +0300
committerDanil Alexeev <danil@alexeev.xyz>2023-09-11 18:45:39 +0300
commit4b5daf06efa1329d60be15f635dd49a7d2b2f056 (patch)
tree2de6ce70ddc3d25b80063f1700e12009677e2357 /modules/mono/csharp_script.cpp
parent221884e6bc260c38f16422081b7d4efd49a71375 (diff)
downloadredot-engine-4b5daf06efa1329d60be15f635dd49a7d2b2f056.tar.gz
Editor: Improve signal callback generation
Diffstat (limited to 'modules/mono/csharp_script.cpp')
-rw-r--r--modules/mono/csharp_script.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/modules/mono/csharp_script.cpp b/modules/mono/csharp_script.cpp
index 9e23a27093..b41f2155f8 100644
--- a/modules/mono/csharp_script.cpp
+++ b/modules/mono/csharp_script.cpp
@@ -435,6 +435,11 @@ static String variant_type_to_managed_name(const String &p_var_type_name) {
return "Collections.Dictionary";
}
+ if (p_var_type_name.begins_with(Variant::get_type_name(Variant::ARRAY) + "[")) {
+ String element_type = p_var_type_name.trim_prefix(Variant::get_type_name(Variant::ARRAY) + "[").trim_suffix("]");
+ return "Collections.Array<" + variant_type_to_managed_name(element_type) + ">";
+ }
+
if (p_var_type_name == Variant::get_type_name(Variant::ARRAY)) {
return "Collections.Array";
}