Search Issue Tracker
Won't Fix
Votes
1
Found in
5.4.0f3
Issue ID
825232
Regression
No
[Serialization] Object reference becomes undefined when struct is serialized directly
Steps to reproduce:
1. Open attached project
2. Open scene "Main"
3. Run it
4. Notice NullReferenceException - it's caused when struct is serialized directly
Workaround/Works when serializing struct as a field
Reproduced with: 5.3.1f1, 5.3.6p3, 5.4.0p2, 5.5.0a6
No JsonUtility in 5.2 so couldn't test
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
- The Scene View becomes gray and "NullReferenceException" errors are thrown when attaching the Unity Editor process to RenderDoc
- Memory usage rapidly rises when changing colors in the color wheel
- Physically Based Sky's Horizon and Zenith Tint Color Selection Bars don't have immediate access to color pickers
- EmptyAdditionalLightShadowmapTexture leaks from memory when URP quality level is changed using QualitySettings.SetQualityLevel
- Referenced ScriptableObject field does not get updated and cannot be set to "None" when there are no Objects of that type
Resolution Note:
This particular case has been investigated thoroughly and we have decided, in the interests of protecting the stability and features of Unity for users that rely upon the affected versions, to not address this fix for the time being. We understand that this will cause problems for some users, and so may address in a future version.