Search Issue Tracker
Duplicate
Duplicate in 2023.2.X
Votes
0
Found in
2022.3.5f1
2023.1.3f1
2023.2.0a23
Issue ID
UUM-42567
Regression
No
RaycastCommand throws assertion errors when the Raycast Direction is other than Vector3.forward
How to reproduce:
1. Open the user-attached project “2023.1 Bug Reports Project”
2. Open the "RaycastCommandBug" scene
3. Enter the Play Mode
4. Select the “RaycastCommandBug” GameObject in the Hierarchy
5. In the Inspector, under the “Raycast Command Test” Script Component change the “Direction” field to 0, 0, 2
6. Enable the Script Component and observe the Console
Expected result: The Script runs correctly and doesn’t throw any errors
Actual result: There are assertion errors
Reproducible with: 2022.3.5f1, 2023.1.3f1, 2023.2.0a23
Couldn’t test with: 2021.3.28f1 (Scripts can’t be compiled)
Reproducible on: Windows 11 Pro
Full error:
Assertion failed on expression: 'IsNormalized(Vec3FromPx(direction))'
UnityEngine.StackTraceUtility:ExtractStackTrace ()
Unity.Jobs.JobHandle:Complete ()
RaycastCommandTest:OnEnable () (at Assets/RaycastCommandTest.cs:33)
UnityEngine.GUIUtility:ProcessEvent (int,intptr,bool&)
-
Resolution Note:
Currently, the direction specified for the batch queries should be normalised before usage. Valid examples could be (1, 0, 0), or (0, 1, 0), as well as many others that are unit length.
Duplicate of https://issuetracker.unity3d.com/product/unity/issues/guid/UUM-41893 -
Resolution Note (2023.2.X):
Currently, the direction specified for the batch queries should be normalised before usage. Valid examples could be (1, 0, 0), or (0, 1, 0), as well as many others that are unit length.
Duplicate of https://issuetracker.unity3d.com/product/unity/issues/guid/UUM-41893
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
- Required SpriteMask class (ID 331) is stripped when "Strip Engine Code" is enabled
- “Maximized serialized file backup not found” error is thrown when minimizing a window in a newly opened project
- Build stack trace contains invalid lines when building with IL2CPP using scripts with delegates containing generic types in the signature
- Entities Systems window has a “Show Full Player Loop” dropdown which does nothing when clicked after enabling “Show Full Player Loop”
- Entities Hierarchy Search “Show/Hide” button’s Lens Icon is blurry when the Editor is on an external monitor
This is a duplicate of issue #UUM-41893