My Unity project seems seriously buggered.
My scene is loaded but my hierarchy is empty. It does this in EVERY scene, not just one. It looks like this:
I’m getting tons of errors, but the one one that is repeating is this:
KeyNotFoundException: The given key was not present in the dictionary.
System.Collections.Generic.Dictionary`2[System.String,UnityEditor.BaseHierarchySort].get_Item (System.String key) (at /Users/builduser/buildslave/mono-runtime-and-classlibs/build/mcs/class/corlib/System.Collections.Generic/Dictionary.cs:150)
UnityEditor.SceneHierarchyWindow.SortMethodsDropDown () (at /Users/builduser/buildslave/unity/build/Editor/Mono/SceneHierarchyWindow.cs:645)
UnityEditor.SceneHierarchyWindow.DoToolbar () (at /Users/builduser/buildslave/unity/build/Editor/Mono/SceneHierarchyWindow.cs:560)
UnityEditor.SceneHierarchyWindow.OnGUI () (at /Users/builduser/buildslave/unity/build/Editor/Mono/SceneHierarchyWindow.cs:318)
System.Reflection.MonoMethod.Invoke (System.Object obj, BindingFlags invokeAttr, System.Reflection.Binder binder, System.Object[] parameters, System.Globalization.CultureInfo culture) (at /Users/builduser/buildslave/mono-runtime-and-classlibs/build/mcs/class/corlib/System.Reflection/MonoMethod.cs:222)
And I’m occasionally getting this one too:
ArgumentException: Getting control 0's position in a group with only 0 controls when doing Repaint
Aborting
UnityEngine.GUILayoutGroup.GetNext ()
UnityEngine.GUILayoutUtility.BeginLayoutGroup (UnityEngine.GUIStyle style, UnityEngine.GUILayoutOption[] options, System.Type layoutType)
UnityEngine.GUILayout.BeginHorizontal (UnityEngine.GUIContent content, UnityEngine.GUIStyle style, UnityEngine.GUILayoutOption[] options)
UnityEngine.GUILayout.BeginHorizontal (UnityEngine.GUIStyle style, UnityEngine.GUILayoutOption[] options)
UnityEditor.SceneHierarchyWindow.DoToolbar () (at /Users/builduser/buildslave/unity/build/Editor/Mono/SceneHierarchyWindow.cs:513)
UnityEditor.SceneHierarchyWindow.OnGUI () (at /Users/builduser/buildslave/unity/build/Editor/Mono/SceneHierarchyWindow.cs:318)
System.Reflection.MonoMethod.Invoke (System.Object obj, BindingFlags invokeAttr, System.Reflection.Binder binder, System.Object[] parameters, System.Globalization.CultureInfo culture) (at /Users/builduser/buildslave/mono-runtime-and-classlibs/build/mcs/class/corlib/System.Reflection/MonoMethod.cs:222)
I suspect it’s an Editor class or something that’s gone out of whack - but can anyone help me understand the error and get to the bottom of it?
Cheers!