Search Issue Tracker
Fixed in 2021.2.X
Votes
0
Found in
2018.4
2019.4
2020.3
2020.3.2f1
2021.1
2021.2
Issue ID
1327723
Regression
No
OnDrawGizmos is not called if Game Object is in an additive scene and Draw Gizmos is enabled on the Game View
How to reproduce:
1. Open the attached project
2. Enable Gizmos at Top Right of Game View
3. Click Play
4. Observe Game View
Expected result: You can see a cyan line
Actual result: You cannot see a cyan line
Reproducible with: 2018.4.33f1, 2019.4.23f1, 2020.3.4f1, 2021.1.3f1, 2021.2.0a13
Workaround: Disable/Enable the object that draws Gizmos at Start or select the object in the Scene Hierarchy
Notes:
1. If you go to Scene View and enable Gizmos the line won't be visible there as well
2. You can make sure OnDrawGizmos is not called by adding a Debug.Log statement to the OnDrawGizmos method
3. Gizmos must be enabled in Game View for this to reproduce
Comments (3)
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
- 2D light leaks through ShadowCaster2D when ShadowCaster2D components are disabled then re enabled at runtime in Player builds
- Unity Hub redirects to The Unity Roadmap when navigating to “Send Feedback” option
- UI Toolkit throws warning and fails to clear references when fields are not typed as UnityEngine.Object
- "Shader warning in 'Hidden/Light2D': implicit truncation of vector type" is thrown when building Universal 2D template
- AI Assistant breaks compilation of packages using System.Runtime.CompilerServices.Unsafe via auto-referencing
whalepaha
Jul 19, 2023 10:21
Not fixed in Unity 2021.3.21f
Bryan-Legend
Apr 25, 2023 06:45
Still present in 2021.3.20f1!
Mimimi_Luca
Oct 28, 2022 13:04
I currently still have this issue with Unity 2021.3.11f1
OnDrawGizmos is not called on objects in additive scenes until these objects have been selected at least once in the Hierarchy.