Skip to content

Commit 38a6018

Browse files
committed
[修复]1. 修复map 协议报错导致的aot 裁剪报错
1 parent 5af2ead commit 38a6018

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

ProtoExport/ProtoBuffUnityHelper.cs

+2-2
Original file line numberDiff line numberDiff line change
@@ -79,8 +79,9 @@ public void Run(MessageInfoList messageInfoList, string outputPath, string names
7979
if (operationField.IsKv)
8080
{
8181
defaultValue = $" = new {operationField.Type}();";
82+
sb.AppendLine($"\t\t[ProtoMap(DisableMap = true)]");
8283
}
83-
sb.AppendLine($"\t\t[ProtoMap(DisableMap = true)]");
84+
8485
sb.AppendLine($"\t\tpublic {operationField.Type} {operationField.Name} {{ get; set; }}{defaultValue}");
8586
}
8687

@@ -100,7 +101,6 @@ public void Run(MessageInfoList messageInfoList, string outputPath, string names
100101

101102
public void Post(List<MessageInfoList> operationCodeInfo, string launcherOptionsOutputPath)
102103
{
103-
104104
}
105105
}
106106
}

0 commit comments

Comments
 (0)