同一字段名在该类或其父类中被多次序列化。

时间:2018-12-27 12:25:03

标签: c# unity3d

每当我尝试为Windows构建时,都会收到此错误。

The same field name is serialized multiple times in the class or its parent class. This is not supported: Base(MonoBehaviour) speed
UnityEditor.HostView:OnGUI()

问题是它没有显示哪个脚本有问题?该错误未在编辑器中显示,但在我尝试构建时显示,但构建失败。

2 个答案:

答案 0 :(得分:0)

正如我所说的,每当我尝试为Windows平台构建时都会发生此错误

The same field name is serialized multiple times in the class or its parent class. This is not supported: Base(MonoBehaviour) speed
UnityEditor.HostView:OnGUI()

我发现在打开构建的输出日志文本文件时,我正在同一位置重写该构建。关闭上次构建的输出日志文件后,我就能够成功构建。

答案 1 :(得分:-1)

颠簸版本为我做到了

项目设置 -> 播放器 -> 版本