void VelocityManagement() { if (controlClass.GetActiveGame()) { KeepingVelocity(); } }
void FixedUpdate() { if (controlClass.GetActiveGame()) { FollowMouse(); } BonusTimer(); }
SpawnController spawnController; //Just to have time's control void Update() { if (controlClass.GetActiveGame()) { if (Input.GetKeyDown(KeyCode.R)) { Application.LoadLevel(Application.loadedLevel); controlClass.ResetAll(); } } }
void Start() { controlClass = ControlClass.getInstance; startButton.SetActive(!controlClass.GetActiveGame()); timeLeft = 60.0f; UpdateTimer(); // StartCoroutine(spawn()); }
void FixedUpdate() { if (controlClass.GetActiveGame()) { timeLeft -= Time.deltaTime; UpdateTimer(); if (timeLeft < 0) { timeLeft = 0; } } }