Search Issue Tracker
By Design
Votes
0
Found in
2019.3.0a4
2019.4
2019.4.19f1
2020.2
2021.1
2021.2
Issue ID
1313367
Regression
Yes
CharacterController isGrounded property affected when changing the Editor layout so that Scene/Game/Animator windows are visible
How to reproduce:
1. Open the attached project (case-1313367_CharacterController)
2. Click Play
3. Observe the character jumping and the values printed to the console
4. Change the layout in such a way that both the Scene window and the Game window are visible
5. Observe the character no longer jumping and the values printed to the console
Expected result: The behaviour of the isGrounded property does not change
Actual result: The behaviour of the isGrounded property changes
Reproducible with: 2019.3.0a4, 2019.4.19f1, 2020.2.5f1, 2021.1.0b7, 2021.2.0a4
Not reproducible with: 2018.4.30f1, 2019.3.0a3
Notes:
1. In Unity 2020.2.5f1, 2021.1.0b7, 2021.2.0a4 all 3 windows (Scene, Game, Animator) have to be visible for the change in behaviour to occur
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
- Mouse input is registered incorrectly in Custom RP when downscaling Render Target and rendering Overlay UI before final upscale
- Time.deltaTime is locked to the display's refresh rate when the built Player is moved to a Secondary Display and Windowed Mode is used
- Crash on RaiseException when importing a specific asset
- Crash on RaiseException when opening a specific project
- DownloadHandlerScript.CompleteContent is called twice when building for WebGL
Resolution Note:
Based on the project setup calling CharacterController.Move every frame in the direction of the box forces the object to overlap with the box collider. This results in the Character controller being pushed out of the box collider on the next Physics Update and causing weird behaviour where sometimes IsGrounded would return True and sometimes it would return False. This behaviour is circumvented if CharacterController.Move is called from FixedUpdate (IsGrounded always returns true, no matter what window you are looking from)