public void Restart() { startScreen.SetActive(false); winScreen.SetActive(false); loseScreen.SetActive(false); BallSpawner.SetActive(false); InputManager.SetActive(false); Hole.GetComponent <Hole>().Restart(); BallSpawner.GetComponent <BallSpawner>().Restart(); layout.SetActive(true); BallSpawner.SetActive(true); InputManager.SetActive(true); }
void SetBallNumber() { int ballNum = BallSpawner.GetComponent <BallSpawner>().avaliableSpawnBall + 1; ballText.text = ballNum.ToString(); }