protected void Start() { _playerAction = PlayerAction.Instance; _timeManager = TimeManager.Instance; courseController = CoursesController.Instance; _gameManager = GameManager.Instance; _switchScene = SwitchScene.Instance; courseDisplayed = CourseDisplayed.AllCourse; _gameManager.OnGameStateChanged.AddListener(HandleGameStateChanged); all_course.SetActive(false); my_course.SetActive(false); ActivedNotificationCanvas(false); ActivedAllCourse(); }
public void ActivedAllCourse() { if (_gameManager.CurrentGameState == GameManager.GameState.COURSE) { if (all_course.activeSelf == false) { if (preDisplay != null) { preDisplay.SetActive(false); } all_course.SetActive(true); preDisplay = all_course; CreateAllCourses(); } else { CreateAllCourses(); } courseDisplayed = CourseDisplayed.AllCourse; } }