Search Issue Tracker
Fixed in 2021.2.X
Changing the reference value in the ScriptableObject's script and re-opening the project will result in NULL reference error
1. Open the user's attached project "SkyboxRepro.zip"
2. In the Project window open Assets/DATA/Broken/BrokenRefNull Scene
3. In the Hierarchy window expand the "BrokenRefNull Scene" and select "CLICK ME!" GameObject
4. Observe the "CustomScriptableObjectDebugger" script property "SEE BELOW" in the Inspector window
5. Close the project, go to the project's folder and open Assets/DATA/Broken/Buggy Scriptable Object.asset
6. Modify the file's script line 16 from "dummyVal: 4" to "dummyVal: 2"
7. Re-open the project and repeat steps 2-4
Expected result: "CustomScriptableObjectDebugger" script property "SEE BELOW" has no "[ERROR] customScriptableObject.customMonobehavior = NULL"
Actual result: "CustomScriptableObjectDebugger" script property "SEE BELOW" has a "[ERROR] customScriptableObject.customMonobehavior = NULL"
Reproducible with: 2019.4.16f1, 2020.1.17f1, 2020.2.1f1, 2021.1.0a9
Could not test with: 2018.4.30f1 (Multi-object editing not supported)
- In the script, the reference to the customMonobehavior in the prefab is now NULL even though in the Prefab it is clearly seen that the reference is valid
All about bugs
View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.
- [URP] Gizmos position and scale incorrectly when changing camera rect
- Folder name is truncated when dot is used in the name
- Reorderable List elements cannot be edited when using Custom Editors and Serialized Objects
- VideoPlayer does not play video when device is using Android 6.0.1
- Mesh.GetIndexBuffer() requires Mesh's 'Read/Write' flag to be enabled to get its index buffer data in Builds