Renamed script to AdditiveNetworkManager

This commit is contained in:
Chris Langsenkamp 2019-04-01 19:18:15 -04:00
parent 2c0fa42568
commit 297b671766
2 changed files with 6 additions and 2 deletions

View File

@ -4,7 +4,7 @@
namespace Mirror.Examples.Additive
{
public class NetworkManagerExt : NetworkManager
public class AdditiveNetworkManager : NetworkManager
{
[Scene]
[Tooltip("Add all sub-scenes to this list")]
@ -17,7 +17,11 @@ public override void OnStartServer()
// load all subscenes on the server only
foreach (string sceneName in subScenes)
StartCoroutine(LoadScene(sceneName));
{
SceneManager.LoadSceneAsync(sceneName, LoadSceneMode.Additive);
Debug.LogFormat("Loaded {0}", sceneName);
}
//StartCoroutine(LoadScene(sceneName));
}
IEnumerator LoadScene(string sceneName)