So for a bit now almost every time i open unity I get a nullreference exception error except i think it’s like in the code that unity comes with not the code that I wrote here’s the error:
NullReferenceException: Object reference not set to an instance of an object
UnityEngine.UIElements.StyleSheets.StyleSelectorHelper.FastLookup (System.Collections.Generic.IDictionary2[TKey,TValue] table, System.Collections.Generic.List
1[T] matchedSelectors, UnityEngine.UIElements.StyleMatchingContext context, System.String input, UnityEngine.UIElements.StyleSheets.SelectorMatchRecord& record) (at /Users/bokken/buildslave/unity/build/Modules/UIElements/StyleSheets/StyleSelectorHelper.cs:199)
UnityEngine.UIElements.StyleSheets.StyleSelectorHelper.FindMatches (UnityEngine.UIElements.StyleMatchingContext context, System.Collections.Generic.List`1[T] matchedSelectors) (at /Users/bokken/buildslave/unity/build/Modules/UIElements/StyleSheets/StyleSelectorHelper.cs:226)
UnityEngine.UIElements.VisualTreeStyleUpdaterTraversal.TraverseRecursive (UnityEngine.UIElements.VisualElement element, System.Int32 depth) (at /Users/bokken/buildslave/unity/build/Modules/UIElements/VisualTreeStyleUpdater.cs:229)
UnityEngine.UIElements.StyleSheets.HierarchyTraversal.Recurse (UnityEngine.UIElements.VisualElement element, System.Int32 depth) (at /Users/bokken/buildslave/unity/build/Modules/UIElements/HierarchyTraversal.cs:24)
UnityEngine.UIElements.VisualTreeStyleUpdaterTraversal.TraverseRecursive (UnityEngine.UIElements.VisualElement element, System.Int32 depth) (at /Users/bokken/buildslave/unity/build/Modules/UIElements/VisualTreeStyleUpdater.cs:253)
UnityEngine.UIElements.StyleSheets.HierarchyTraversal.Traverse (UnityEngine.UIElements.VisualElement element) (at /Users/bokken/buildslave/unity/build/Modules/UIElements/HierarchyTraversal.cs:11)
UnityEngine.UIElements.VisualTreeStyleUpdater.ApplyStyles () (at /Users/bokken/buildslave/unity/build/Modules/UIElements/VisualTreeStyleUpdater.cs:108)
UnityEngine.UIElements.VisualTreeStyleUpdater.Update () (at /Users/bokken/buildslave/unity/build/Modules/UIElements/VisualTreeStyleUpdater.cs:91)
UnityEngine.UIElements.VisualTreeUpdater.UpdateVisualTreePhase (UnityEngine.UIElements.VisualTreeUpdatePhase phase) (at /Users/bokken/buildslave/unity/build/Modules/UIElements/VisualTreeUpdater.cs:83)
UnityEngine.UIElements.Panel.UpdateForRepaint () (at /Users/bokken/buildslave/unity/build/Modules/UIElements/Panel.cs:723)
UnityEngine.UIElements.Panel.Repaint (UnityEngine.Event e) (at /Users/bokken/buildslave/unity/build/Modules/UIElements/Panel.cs:761)
UnityEngine.UIElements.UIElementsUtility.DoDispatch (UnityEngine.UIElements.BaseVisualElementPanel panel) (at /Users/bokken/buildslave/unity/build/Modules/UIElements/UIElementsUtility.cs:439)
UnityEngine.UIElements.UIElementsUtility.UnityEngine.UIElements.IUIElementsUtility.ProcessEvent (System.Int32 instanceID, System.IntPtr nativeEventPtr, System.Boolean& eventHandled) (at /Users/bokken/buildslave/unity/build/Modules/UIElements/UIElementsUtility.cs:209)
UnityEngine.UIElements.UIEventRegistration.ProcessEvent (System.Int32 instanceID, System.IntPtr nativeEventPtr) (at /Users/bokken/buildslave/unity/build/Modules/UIElements/UIElementsUtility.cs:74)
UnityEngine.UIElements.UIEventRegistration+<>c.<.cctor>b__1_2 (System.Int32 i, System.IntPtr ptr) (at /Users/bokken/buildslave/unity/build/Modules/UIElements/UIElementsUtility.cs:28)
UnityEngine.GUIUtility.ProcessEvent (System.Int32 instanceID, System.IntPtr nativeEventPtr, System.Boolean& result) (at /Users/bokken/buildslave/unity/build/Modules/IMGUI/GUIUtility.cs:189)
UnityEditor.EditorApplicationLayout:SetPausemodeLayout() (at /Users/bokken/buildslave/unity/build/Editor/Mono/GUI/EditorApplicationLayout.cs:46)