Example #1
0
    public override void Enter()
    {
        uiMng         = context.GetGameManager().GetUIManager();
        currentUICtrl = uiMng.GetCurrentUIController();

        mainMenuPanel = currentUICtrl.GetMenu <UIMenu_MainMenu>();
        currentUICtrl.SetCurrentMenu <UIMenu_MainMenu>();

        mainMenuPanel.StartButtonPressed += HandleStartButtonPressed;
    }
Example #2
0
    public void Setup(GameManager _gm)
    {
        gm            = _gm;
        mainMenuPanel = gm.GetUIManager().GetMenu <UIMenu_MainMenu>();

        SoundControllersSetup();

        mainMenuPanel.OnSoundToggle += HandleOnSoundToggle;
        soundOn = PlayerPrefs.GetInt("Sound", 0) == 0;
    }
Example #3
0
    public override void Enter()
    {
        gm            = context.GetGameManager();
        musicCtrl     = gm.GetMusicController();
        uiMng         = gm.GetUIManager();
        mainMenuPanel = uiMng.GetMenu <UIMenu_MainMenu>();

        uiMng.SetCurrentMenuAnimation <UIMenu_MainMenu>("MainMenuIn");
        CoroutineController.StartRoutine(() => mainMenuPanel.EnablePanelContainer(true), 0.01f);
        musicCtrl.PlayMainMenuClip();
        mainMenuPanel.StartGameButtonPressed = StartGameButtonPressed;
    }