void Start() { //print(SceneManager.GetActiveScene().buildIndex + 1); score = 0; AlienBullet.SetActive(true); healthBar = GameObject.FindObjectOfType <HealthBar>(); }
public void publicDeactivates() { rocket.SetActive(false); UI.SetActive(false); Bounder.SetActive(false); AlienCar.SetActive(false); AlienBullet.SetActive(false); AlienCar2.SetActive(false); }
void WinGame() { if (score > 1) { PlayerPrefs.SetInt("levelReached", SceneManager.GetActiveScene().buildIndex); GameWin.SetActive(true); publicDeactivates(); gameWin = true; AlienCar.SetActive(false); AlienBullet.SetActive(false); AlienCar2.SetActive(false); } }