// Use this for initialization void Start() { Delay = 2; SpawnWithNoControls = true; ES = GameObject.Find("EternalHolder").GetComponent <EternalScript> (); RHS = GameObject.Find("WinTextObj").GetComponent <RoundHandlerScript> (); SpawnInQue = new bool[4]; for (int i = 0; i < 4; i++) { SpawnInQue[i] = false; SpawnPointsProtection[i].SetActive(false); } if (ES.GetActivePlayer(0)) { Respawn(0); } if (ES.GetActivePlayer(1)) { Respawn(1); } if (ES.GetActivePlayer(2)) { Respawn(2); } if (ES.GetActivePlayer(3)) { Respawn(3); } }
// Use this for initialization void Start() { CCS = GameObject.Find("Main Camera").GetComponent <CameraControllerScript>(); PCS = GetComponent <PlayerControlScript> (); PlayerColor = GetComponent <SpriteRenderer> ().color; RHS = GameObject.Find("WinTextObj").GetComponent <RoundHandlerScript> (); BoarderColor = HitBoarder.color; SPS = GameObject.Find("SoundObject").GetComponent <SoundPlayerScript> (); Stats = GameObject.Find("TotalStatsHolder").GetComponent <EndGameStatsScript>(); ES = GameObject.Find("EternalHolder").GetComponent <EternalScript> (); Invincible = true; bulletNumbers = new int[4]; for (int x = 0; x < 4; x++) { bulletNumbers[x] = -1; } Invoke("RemoveIncincible", 2f); }