From e3f5af530b21513591f686ee959cecd5de2cf9ee Mon Sep 17 00:00:00 2001 From: Ari Vuollet Date: Fri, 19 Dec 2025 23:57:31 +0200 Subject: [PATCH] Fix incorrect class namespace in bindings class name lookups --- .../Flax.Build/Bindings/BindingsGenerator.Cpp.cs | 12 +----------- 1 file changed, 1 insertion(+), 11 deletions(-) diff --git a/Source/Tools/Flax.Build/Bindings/BindingsGenerator.Cpp.cs b/Source/Tools/Flax.Build/Bindings/BindingsGenerator.Cpp.cs index 190036af4..89e5dcd10 100644 --- a/Source/Tools/Flax.Build/Bindings/BindingsGenerator.Cpp.cs +++ b/Source/Tools/Flax.Build/Bindings/BindingsGenerator.Cpp.cs @@ -387,17 +387,7 @@ namespace Flax.Build.Bindings // Find namespace for this type to build a fullname if (apiType != null) - { - var e = apiType.Parent; - while (!(e is FileInfo)) - { - e = e.Parent; - } - if (e is FileInfo fileInfo && !managedType.StartsWith(fileInfo.Namespace)) - { - managedType = fileInfo.Namespace + '.' + managedType.Replace(".", "+"); - } - } + managedType = apiType.Namespace + '.' + managedType.Replace(".", "+"); // Use runtime lookup from fullname of the C# class return "Scripting::FindClass(\"" + managedType + "\")";