Exemplo n.º 1
0
    public override void StateBegin()
    {
        m_menu = DouduckGameCore.GetModule <GameObjectControlModule> ().GetGameObjectSet <MainMenuSet> ("MainMenu");
        m_menu.Show();

        m_menu.Events.OnButtonClick += OnButtonClick;
    }
Exemplo n.º 2
0
 private void OnButtonClick(GameObject go, string name)
 {
     if (name == "BackMenu")
     {
         DouduckGameCore.GetModule <GameFlowModule> ().TransTo(new MainMenuState());
     }
 }
Exemplo n.º 3
0
    public override void StateBegin()
    {
        m_resultUI = DouduckGameCore.GetModule <GameObjectControlModule> ().GetGameObjectSet <ResultSet> ("Result");
        m_resultUI.Show();
        m_resultUI.SetScore(m_score);

        m_resultUI.Events.OnButtonClick += OnButtonClick;
    }
Exemplo n.º 4
0
 private void OnButtonClick(GameObject go, string name)
 {
     if (name == "Start")
     {
         m_menu.SetTutorialActive();
     }
     else
     {
         DouduckGameCore.GetModule <GameFlowModule> ().TransTo(new InGameState());
     }
 }
Exemplo n.º 5
0
    public void GameStart()
    {
        GameObjectControlModule controller_ = DouduckGameCore.GetModule <GameObjectControlModule> ();

        GameObjectSet[] sets_ = GameObject.FindObjectsOfType <GameObjectSet> ();
        for (int i = 0; i < sets_.Length; i++)
        {
            controller_.AddGameObjectSet(sets_[i]);
            sets_[i].Hide();
        }

        DouduckGameCore.AddModule <GameFlowModule> ().TransTo(new MainMenuState());
    }
Exemplo n.º 6
0
    public override void StateBegin()
    {
        DouduckGameCore.GetSystem <AudioInterface> ().PlayBGM(BGMAudio.InGame);
        m_inGameUI = DouduckGameCore.GetModule <GameObjectControlModule> ().GetGameObjectSet <InGameSet> ("InGame");
        m_inGameUI.Show();

        m_ItemManager = DouduckGameCore.GetSystem <ItemManager> ();
        m_ItemManager.Reset();

        m_LastTime  = GAME_TIME;
        m_itemTimer = 0f;
        m_inGameUI.timerText.text = string.Format("{0:###.}", m_LastTime);
    }