Created
June 16, 2019 23:26
-
-
Save SocketWeaver/5ad4b1b9f2c04460866202f4330b1ce8 to your computer and use it in GitHub Desktop.
Add a method in the GameSceneManager.cs script to handle the OnReady event of the SceneSpawner.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public void OnSpawnerReady(bool alreadySetup) | |
{ | |
Debug.Log("OnSpawnerReady " + alreadySetup); | |
if (!alreadySetup) | |
{ | |
int spawnPointIndex = Random.Range(0, 3); | |
NetworkClient.Instance.LastSpawner.SpawnForPlayer(0, spawnPointIndex); | |
NetworkClient.Instance.LastSpawner.PlayerFinishedSceneSetup(); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment