Search Issue Tracker
ISerializationCallback.OnBeforeSerialize sometimes fail to access a reference to ScriptableObject asset
How to reproduce:
1. Open the user-submitted project ("iserializationcallback_scriptableobject_bug.zip")
2. Observe the console errors (Enter and leave Play mode if the errors are not present)
3. Try to rename one of the non-accessible Scriptable Assets and enter Play Mode again
4. Observe that their name/path hasn't updated in the error message
5. Build and run the Player (As a development build) and observe that the paths are updated and no errors are thrown
Expected result: All of the assets get referenced correctly and no errors are thrown
Actual result: Some of the assets don't get referenced correctly and throw errors in Editor only
Reproduced in: 2019.1.0a12, 2018.3.1f1, 2017.4.17f1
Note: The Scriptable assets that return null when referenced are not always the same and differ from version to version
Unity APIs should not be accessed in the ISerializationCallback callbacks and might not work correctly when used. These callbacks main purpose is to allow users to add serialization support of types that the Unity serialization does not support. Unfortunately, we cannot block usage of the Unity APIs in these callbacks, as some use cases work and it would therefore be a breaking change. A bit more background info on this: https://blogs.unity3d.com/2016/06/06/serialization-monobehaviour-constructors-and-unity-5-4/ We won't fix this issue and if you have a use case that is not currently supported with our existing API, please file a feature request through the Unity Feedback website: https://feedback.unity3d.com/
All about bugs
View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.
- [OSX][Settings] When using only the new ISX as Input Handling, mouse position and scroll are still detected by the old system.
- [Scripting] Input Action fails to re-enable after disabled.
- [MacOS] "Bloom" does not work in Standalone Build
- Mesh.CombineMeshes result has different normals if the original mesh has tweaked normals and scale
- [Hub] In licence error screen https://unity3d.com/unity/err/license redirects to not found website