Search Issue Tracker

Fixed in 3.0.6

Votes

0

Found in [Package]

"com.unity.2d.spriteshape": "3.0.2"

Issue ID

1179257

Regression

Yes

[SpriteShape] Error when SpriteShapeProfile is selected

Package: 2D Sprite Shape

-

[SpriteShape] Error when SpriteShapeProfile is selected

Null Reference Exception occurs when SpriteShapeProfile_"Hair" sprite is selected in Assets tab

Repro Steps:
1. Open the attached project
2. Click on SpriteShapeProfile_"Hair" sprite in Assets tab
3. Observe error in Console tab:
NullReferenceException: Object reference not set to an instance of an object
UnityEditor.U2D.SpriteShapeEditor.OnInspectorGUI () (at Library/PackageCache/com.unity.2d.spriteshape@3.0.2/Editor/SpriteShapeEditor.cs:308)
UnityEditor.UIElements.InspectorElement+<>c__DisplayClass53_0.<CreateIMGUIInspectorFromEditor>b__0 () (at <ed82b0b80ec5457da3c2e9cdf90adc95>:0)
UnityEngine.GUIUtility:ProcessEvent(Int32, IntPtr)

Expected Results: No NullReferenceException error should be produced when "Hair" sprite is selected
Actual Results: NullReferenceException error produced when "Hair" sprite is selected

Reproducible with: 2019.1.14f1 (SpriteShape 2.0.0-preview.9), 2019.2.3f1 (SpriteShape 2.1.0-preview.11), 2019.3.0b1 (SpriteShape 3.0.2)

Environment: Windows 10 only

Note:
Could be due to the selected sprites not having a jpg or png file, in the example, "Hair" sprite was from a psb file

Add comment

Log in to post comment

All about bugs

View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.