Search Issue Tracker
Fixed in 12.0.0
Votes
0
Found in [Package]
11.0
Issue ID
1332320
Regression
No
2D Sprite Light is missing a Sprite reference when created
Make a new 2D project in 2021.1.4f1. Install the Universal Render Pipeline and setup the 2D Renderer. Create a 2D Sprite Light.
This error occurs:
NullReferenceException: Object reference not set to an instance of an object
UnityEngine.Experimental.Rendering.Universal.LightUtility.GenerateSpriteMesh (UnityEngine.Experimental.Rendering.Universal.Light2D light, UnityEngine.Sprite sprite) (at Library/PackageCache/com.unity.render-pipelines.universal@11.0.0/Runtime/2D/LightUtility.cs:446)
UnityEngine.Experimental.Rendering.Universal.Light2D.UpdateMesh (System.Boolean forceUpdate) (at Library/PackageCache/com.unity.render-pipelines.universal@11.0.0/Runtime/2D/Light2D.cs:262)
UnityEngine.Experimental.Rendering.Universal.Light2D.LateUpdate () (at Library/PackageCache/com.unity.render-pipelines.universal@11.0.0/Runtime/2D/Light2D.cs:329)
Should probably assign a sprite by default.
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
- Articulation Body with 'Revolute' Joint Type has erratic behavior when Upper Limit is set to above 360
- WebGL Player fails to render Scene when Terrain with Detail Mesh is added and WebGPU Graphics API is used
- Inconsistent errors are logged when different types are passed into the Query "Q<>" method in UIToolkit and the ancestor VisualElement is null
- Crash on GetMaterialPropertyByIndex when opening a specific Scene
- Discrepancies in the styling are present when using a TSS file instead of a USS file in custom EditorWindow
Resolution Note (fix version 12.0.0):
Fix for this issue is available on Unity 2022.1.0a8 and above