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.
- Applied velocity is inconsistent when using Rigidbody AddForce() with ForceMode.VelocityChange
- Crash on AudioUtil_CUSTOM_HasAudioCallback when exiting Play Mode while the Inspector is displaying a GameObject with an empty script attached
- Scroll offset is framerate-dependent when scrolling with velocity in the Device Simulator
- "Object.FindObjectsOfType<T>() is obsolete" warning is thrown when using "Transitions Plus" asset
- [Mono] Crash on SystemNative_ReadDirR() when building for IOS/Android on a macOS machine