Various fixes for scripting bindings codegen
This commit is contained in:
@@ -375,6 +375,13 @@ namespace Flax.Build.Bindings
|
||||
// Find API type info
|
||||
var apiType = FindApiTypeInfo(buildData, typeInfo, caller);
|
||||
var typeName = typeInfo.Type.Replace("::", ".");
|
||||
if (typeInfo.GenericArgs != null)
|
||||
{
|
||||
typeName += '<';
|
||||
foreach (var arg in typeInfo.GenericArgs)
|
||||
typeName += arg.Type.Replace("::", ".");
|
||||
typeName += '>';
|
||||
}
|
||||
if (apiType != null)
|
||||
{
|
||||
// Add reference to the namespace
|
||||
@@ -1320,7 +1327,7 @@ namespace Flax.Build.Bindings
|
||||
contents.AppendLine(string.Join("\n" + indent, (indent + $$"""
|
||||
/// <summary>
|
||||
/// Marshaller for type <see cref="{{classInfo.Name}}"/>.
|
||||
/// </summary>");
|
||||
/// </summary>
|
||||
#if FLAX_EDITOR
|
||||
[HideInEditor]
|
||||
#endif
|
||||
|
||||
@@ -849,14 +849,12 @@ namespace Flax.Build.Bindings
|
||||
if (typeInfo.GenericArgs != null)
|
||||
{
|
||||
type += '<';
|
||||
|
||||
for (var i = 0; i < typeInfo.GenericArgs.Count; i++)
|
||||
{
|
||||
if (i != 0)
|
||||
type += ", ";
|
||||
type += typeInfo.GenericArgs[i];
|
||||
}
|
||||
|
||||
type += '>';
|
||||
}
|
||||
return string.Empty;
|
||||
@@ -1074,6 +1072,10 @@ namespace Flax.Build.Bindings
|
||||
{
|
||||
convertOutputParameter = true;
|
||||
}
|
||||
else if (apiType.Name == "Variant")
|
||||
{
|
||||
convertOutputParameter = true;
|
||||
}
|
||||
}
|
||||
// BytesContainer
|
||||
else if (parameterInfo.Type.Type == "BytesContainer" && parameterInfo.Type.GenericArgs == null)
|
||||
|
||||
Reference in New Issue
Block a user