We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 372dda4 commit 9206577Copy full SHA for 9206577
Assets/BossRoom/Scripts/Editor/SceneBootstrapper.cs
@@ -1,6 +1,7 @@
1
using UnityEditor;
2
using UnityEditor.SceneManagement;
3
using UnityEngine;
4
+using UnityEngine.SceneManagement;
5
6
namespace Unity.Multiplayer.Samples.BossRoom.Editor
7
{
@@ -99,6 +100,15 @@ static void DisableDoNotLoadBootstrapSceneOnPlay()
99
100
101
static void EditorApplicationOnplayModeStateChanged(PlayModeStateChange obj)
102
103
+ // detects whether playmode has been initiated by a TestRunner Playmode test; if so disable Boostrap loading
104
+ for (int i = 0; i < SceneManager.sceneCount; i++)
105
+ {
106
+ if (SceneManager.GetSceneAt(i).name.Contains("InitTestScene"))
107
108
+ return;
109
+ }
110
111
+
112
if (!LoadBootstrapScene)
113
114
return;
0 commit comments