Search Issue Tracker

Won't Fix

Votes

2

Found in

2021.2.0b13

2021.2.13f1

Issue ID

1407707

Regression

Yes

GUI and NullReferenceException errors are thrown when entering Play mode

uGUI

-

How to reproduce:
1. Open the user-submitted project
2. Open the scene "SampleScene" (Assets/Scenes/SampleScene.unity)
3. In the Hierarchy window, select the GameObject "Canvas" and enter Play mode
4. While Play mode is loading, start clicking the left mouse button inside the Scene view
5. When Play mode has loaded, inspect the Console window (Window > General > Console)

Expected result: No errors are seen
Actual result: GUI and NullReferenceException errors are seen

Reproducible with: 2021.2.0b13, 2021.2.15f1
Not reproducible with: 2019.4.36f1, 2020.3.31f1, 2021.2.0b12, 2022.1.0a1, 2022.1.0b11, 2022.2.0a7

Note: Might take a few tries to reproduce. Retry from step 3 if the errors didn't appear.

Errors:
NullReferenceException: Object reference not set to an instance of an object
UnityEditor.SceneView.CallOnPreSceneGUI () (at /Users/bokken/buildslave/unity/build/Editor/Mono/SceneView/SceneView.cs:3659)

GUI Error: You are pushing more GUIClips than you are popping. Make sure they are balanced.
UnityEngine.GUIUtility:ProcessEvent (int,intptr,bool&) (at /Users/bokken/buildslave/unity/build/Modules/IMGUI/GUIUtility.cs:189)

  1. Resolution Note (2021.3.X):

    This does not reproduce on the current editor version, and given how inconsistent and low user pain this problem is I am closing with "wont fix".

Comments (25)

  1. keremetisan

    May 30, 2022 09:54

    I have this problem on 2021.3.3f1 and on 2021.2.15f1.

  2. JettGod

    May 23, 2022 09:30

    Same here.

  3. Kyle4D

    May 13, 2022 09:48

    Still exists on 2021.3.2 LTS

  4. ab_zephyrmobile

    Apr 24, 2022 20:25

    Still exists on 2021.3.1f1

  5. bgulanowski

    Apr 23, 2022 00:56

    I have this problem on 2021.3.0f1.

    It is happening for in this project. Maybe you can reproduce it.

    https://github.com/bgulanowski/WarBots

Add comment

Log in to post comment

All about bugs

View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.