Corrected Spawning Runner Error

This commit is contained in:
2021-10-27 14:22:12 -05:00
parent 8431f67505
commit 5a9f3e9118
3 changed files with 185 additions and 33 deletions

View File

@@ -121,14 +121,14 @@ public class ServerGameNetPortal : MonoBehaviour {
// Spawn in the prefab for the player based on king or runner
NetworkObject go = null;
if (pData.IsKing) {
//go = Instantiate(kingPrefab, kingSpawnPoint, Quaternion.identity);
go = Instantiate(kingPrefab, kingSpawnPoint, Quaternion.identity);
} else {
go = Instantiate(runnerPrefab, runnersSpawnPoints[runnerSpawnIndex], Quaternion.identity);
// Increment the runner spawn index
runnerSpawnIndex++;
}
}
// Disable the character controllers and camera
//go.GetComponent<CharacterController>().enabled = false;