Search Issue Tracker
Fixed in 7.0.0-pre.1
Fixed in 3.0.16, 5.1.2, 6.0.1
Votes
1
Found in [Package]
3.0.15, 5.1.1
Issue ID
1320015
Regression
Yes
Disabling Edit Spline on Sprite Shape Controller while Cache Geometry is enabled throws an ArgumentException error
Steps to reproduce:
1. Create a new 2D Unity project
2. Create -> 2D Object -> Sprite Shape in Hierarchy
3. Click Edit Spline on Sprite Shape Controller in Inspector
4. Enable Cache Geometry
5. Disable Edit Spline on Sprite Shape Controller
Expected result: No errors are thrown
Actual result: ArgumentException error is thrown
Reproduced with: 2D SpriteShape 3.0.15 (2019.4.22f1), 5.1.1 (2020.3.0f1),
Didn't reproduce with: 2D SpriteShape 3.0.14 (2019.4.22f1)
Full error:
ArgumentException: Slice start + length (6) range must be <= slice.Length (1)
Unity.Collections.NativeSlice`1[T]..ctor (Unity.Collections.NativeSlice`1[T] slice, System.Int32 start, System.Int32 length) (at /Users/bokken/buildslave/unity/build/Runtime/Export/NativeArray/NativeSlice.cs:72)
UnityEngine.U2D.SpriteShapeCopyUtility`1[T].Copy (T[] dst, Unity.Collections.NativeSlice`1[T] src, System.Int32 length) (at Library/PackageCache/com.unity.2d.spriteshape@3.0.15/Runtime/SplineUtility.cs:81)
SpriteShapeGeometryCache.UpdateGeometryCache () (at Library/PackageCache/com.unity.2d.spriteshape@3.0.15/Runtime/SpriteShapeGeometryCache.cs:108)
UnityEditor.U2D.SpriteShapeUpdateCache.UpdateCache (UnityEngine.Object[] targets) (at Library/PackageCache/com.unity.2d.spriteshape@3.0.15/Editor/SpriteShapeControllerEditor.cs:597)
UnityEditor.U2D.SpriteShapeControllerEditor.OnInspectorGUI () (at Library/PackageCache/com.unity.2d.spriteshape@3.0.15/Editor/SpriteShapeControllerEditor.cs:354)
UnityEditor.UIElements.InspectorElement+<>c__DisplayClass58_0.<CreateIMGUIInspectorFromEditor>b__0 () (at /Users/bokken/buildslave/unity/build/Editor/Mono/Inspector/InspectorElement.cs:527)
UnityEngine.GUIUtility:ProcessEvent(Int32, IntPtr) (at /Users/bokken/buildslave/unity/build/Modules/IMGUI/GUIUtility.cs:197)
-
AlanPereiraArt
Apr 19, 2021 16:31
Also happening on 2020.3.4f1, since the package version is the same 5.1.1.
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
- Crash when attempting to create a custom FMOD DSP unit
- [Linux] Floating windows do not keep their size after restarting the Editor
- .framework plugin is mistakenly treated as a directory when building for Universal Windows Platform
- Artifacts appear on GameObjects when using the WebGL Player on Silicon macOS
- Only the icon of the disabled child GameObject is faded when a parent GameObject is a Prefab
Resolution Note (fix version 7.0.0-pre.1):
A fix for this issue is available on 2D SpriteShape package 7.0.0-pre.1 and above
Resolution Note (fix version 6.0.1):
A fix for this issue is available on 2D Sprite Shape package 6.0.1 and above with Unity 2021.1.14f1 and above
Resolution Note (fix version 5.1.2):
A fix for this issue is available on Unity 2020.3.11f1 and above
Resolution Note (fix version 3.0.16):
A fix for this issue is available on 2D SpriteShape package 3.0.16 and above with Unity 2019.4.29f1 and above