Search Issue Tracker
Fixed in 2017.1.0f3
Votes
0
Found in
2017.1.0b1
Issue ID
902037
Regression
Yes
Project sometimes fail to build due to different serialization order in Editor and Player
Reproduction steps:
1. Open project attached (PartialClassBuild.zip).
2. Build it on standalone player.
Expected result: It will be built successfully.
Actual result: Building stops, output from console: (NOT ALWAYS!)
Error: "Type '[Assembly-CSharp]Player' has an extra field 'FieldTwo' of type 'System.Int32' in the player and thus can't be serialized (expected 'FieldOne' of type 'System.Int32')"
Error: Type '[Assembly-CSharp]Player' has an extra field 'FieldThree' of type 'System.Int32' in the player and thus can't be serialized (expected 'FieldOne' of type 'System.Int32')
Error: "Fields serialized in Editor, class 'Player'
'FieldOne' of type 'System.Int32'
'FieldTwo' of type 'System.Int32'
'FieldThree' of type 'System.Int32'"
Error: "Fields serialized in target platform, class 'Player'
'FieldTwo' of type 'System.Int32'
'FieldThree' of type 'System.Int32'
'FieldOne' of type 'System.Int32"
Error: "Error building player because script class layout is incompatible between the editor and the player."
Note: This does not appear all the time. If it is not reproducible from first time, just makes some changes (add space) in Player.cs.
Reproduced on: 2017.1.0a3, 2017.1.0b1.
Works fine on: 5.6.0p1.
Regression introduced in 2017.
Add comment
All about bugs
View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.
Latest issues
- ResolveUsePasses now extracts passes from all subshaders including fallbacks, in contrast to documented behaviour
- [UIBuilder] Changes aren't detected on types implementing IList
- [HDRP] Text is rendered with artefacts when using STP and resolution scale is set a float value
- [Settings Search] Search results not always matching search term correctly
- Crash on memcpy when opening a project that loads TSS files
ChLRajesh
Dec 14, 2017 15:43
This issue again happens in Unity 2017.3.0f2 beta for UWP