Skip to main content
New Participant
September 8, 2023

[BUG] UnityObjectAddedBroadcaster error when opening a scene via editor

There is an error with the latest Oculus Integration package for Unity version 56 on the UnityObjectAddedBroadcaster class at line 76. When using EditorSceneManager.OpenScene.

Because somehow it intercepts that even if the scene is not yet loaded

This is using Unity 2022.3.9f1

 

ArgumentException: The scene is not loaded.
UnityEngine.SceneManagement.Scene.GetRootGameObjects (System.Collections.Generic.List`1[T] rootGameObjects) (at <10871f9e312b442cb78b9b97db88fdcb>:0)
UnityEngine.SceneManagement.Scene.GetRootGameObjects () (at <10871f9e312b442cb78b9b97db88fdcb>:0)
Oculus.Interaction.Editor.UnityObjectAddedBroadcaster.HandleSceneOpened (UnityEngine.SceneManagement.Scene scene, UnityEditor.SceneManagement.OpenSceneMode mode, System.Collections.Generic.HashSet`1[T] knownIds) (at Assets/Oculus/Interaction/Editor/AutoWiring/UnityObjectAddedBroadcaster.cs:88)
Oculus.Interaction.Editor.UnityObjectAddedBroadcaster+<>c__DisplayClass8_0.<.cctor>b__0 (UnityEngine.SceneManagement.Scene scene, UnityEditor.SceneManagement.OpenSceneMode mode) (at Assets/Oculus/Interaction/Editor/AutoWiring/UnityObjectAddedBroadcaster.cs:44)
Oculus.Interaction.Editor.UnityObjectAddedBroadcaster..cctor () (at Assets/Oculus/Interaction/Editor/AutoWiring/UnityObjectAddedBroadcaster.cs:77)
Rethrow as TypeInitializationException: The type initializer for 'Oculus.Interaction.Editor.UnityObjectAddedBroadcaster' threw an exception.
Oculus.Interaction.Editor.UnityObjectAddedBroadcaster+<>c__DisplayClass8_0.<.cctor>b__3 () (at Assets/Oculus/Interaction/Editor/AutoWiring/UnityObjectAddedBroadcaster.cs:60)
UnityEditor.AssemblyReloadEvents.OnBeforeAssemblyReload () (at <2e279d988b9d4542841de511fbfdf8c2>:0)

 

 

    This topic has been closed for replies.

    1 reply

    Inspiring
    November 14, 2024

    I am having the same issue with 6000.0.26f1. Was there a workaround?