private void StartGameInit(StartGameplayEvent e) { Time.timeScale = 1f; _ThisLevel = Global.Level; _NextLevel = _ThisLevel + 1; //STAR INIT for (int i = 0; i < Star.Length; i++) { Star[i].SetActive(false); } //LEVEL INIT for (int i = 0; i < _Level.Count; i++) { if (i == Global.Level) { EventManager.TriggerEvent(new ChangeLabirinControlEvent(_Level[i].Labirin.transform)); _Level[i].Labirin.SetActive(true); } else { _Level[i].Labirin.SetActive(false); } } SetTextLevel(); _TimeCounting.InitTime(); OnPause(false); Reset(); EventManager.TriggerEvent(new AchievementAddEvent(2)); }
private void StartChallengeInit(StartChallengeEvent e) { Time.timeScale = 1f; _ThisChallenge = Global.Challenge; //STAR INIT for (int i = 0; i < Star.Length; i++) { Star[i].SetActive(false); } // LEVEL INIT //_Labirin.SetActive(true); for (int i = 0; i < _Level.Count; i++) { if (i == Global.Challenge) { EventManager.TriggerEvent(new ChangeLabirinControlEvent(_Level[i].Labirin.transform)); _Level[i].Labirin.SetActive(true); } else { _Level[i].Labirin.SetActive(false); } } SetTextLevel(); _TimeCounting.InitTime(); OnPause(false); Reset(); }