public override void Update(GameTime gameTime)
        {
            switch (state)
            {
            case (brawlgamestate.settings):
                settingsManager.Update(gameTime);
                break;

            case (brawlgamestate.playerselect):
                playerSelectManager.Update(gameTime);
                break;

            case (brawlgamestate.loadout):
                loadoutManager.Update(gameTime);
                break;

            case (brawlgamestate.brawl):
                if (!boxingManager.Update(gameTime))
                {
                    ChangeState(new Main_Game_State(this.game, inputs, bounds));
                }
                break;

            case (brawlgamestate.stats):
                break;
            }

            base.Update(gameTime);
        }
Beispiel #2
0
        // Updates current state
        public void Update(GameTime gameTime)
        {
            foreach (Input_Handler i in inputs)
            {
                if (i != null)
                {
                    i.Update();
                }
            }

            if (state == GameState.Menu)
            {
                if (Menu.Update(gameTime))
                {
                    state = GameState.Auction;
                    Debug.WriteLine("State Changed to Auction!");
                    Auction.Initialize(Content);
                }
            }
            else if (state == GameState.Auction)
            {
                if (Auction.Update(gameTime))
                {
                    state = GameState.Boxing;
                    Debug.WriteLine("State Changed to Boxing!");
                    ;
                }
            }
            else if (state == GameState.Boxing)
            {
                if (Boxing.Update(gameTime))
                {
                    state = GameState.Menu;
                    Debug.WriteLine("State Changed to Menu!");
                    Boxing.Initialize(Content);
                }
            }
        }