Search Issue Tracker
By Design
Votes
0
Found in
2018.4
2019.3.13f1
2020.2
Issue ID
1262009
Regression
No
GameObject with no Rigidbody starts rotating when it's rotation is getting set to the same Quaternion.Euler value on Update
How to reproduce:
1. Open the attached project "colliderBug.zip"
2. Open the "SampleScene" Scene
3. Expand the "Group" GameObject in the Hierarchy window
4. Expand both "Sphere1" and "Sphere" GameObjects in the Hierarchy window
5. Select the "SpikeNoRig" GameObject in the Hierarchy window
6. Observe the selected GameObject's Transform Component in the Inspector window
7. Enter Play Mode
8. After 5-6 seconds repeat the 6th step
Expected result: Transform Component's rotation remains (-90, 0, 0)
Actual result: Transform Component's rotation keeps changing on the X-axis, while rotation on the Y-axis is set to 90 and to -90 on the Z-axis (Might be -90 on the Y-axis and 90 on the Z-axis on 2020.1, 2020.2)
Reproducible with: 2018.4.27f1, 2019.4.9f1, 2020.1.4f1, 2020.2.0b2
Notes:
- The issue is also reproducible when the GameObject's rotation is getting set to the same Quaternion.Euler value on FixedUpdate
- "SpikeRig" GameObject is identical to the "SpikeNoRig" GameObject, it just has a Rigidbody Component with "Is Kinematic" property set to True, which gets rid of the issue
- The changing rotation of the "SpikeNoRig" GameObject also has an effect on the parent "Sphere1" GameObject's Transform Component
- The issue is not reproducible if the rotation is set to a Vector3 value instead of a Quaternion value
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
- After converting a Built-in project to URP render texture related errors are spammed that can lead to Game view being rendered on top of Scene view
- UI Builder slider value lags and stutters when sliding/modifying certain property values
- "Reset UI Builder Layout" functionality inconsistently changes Canva Size when "Match Game View" is enabled/disabled
- Texture Import Warnings are obscured by other Terrain Layer options in the Inspector
- Burst Inspector middle divider is jittering when resized with the Burst Inspector window docked
Resolution Note:
The rotation is a quaternion and requires a threshold check to verify if the change is more than the epsilon used in the physics engine when used within Update.