Bricklayer.Client.Game.Update C# (CSharp) Method

Update() protected method

Allows the game to run logic such as updating the world, checking for collisions, gathering input, and playing audio.
protected Update ( GameTime gameTime ) : void
gameTime Microsoft.Xna.Framework.GameTime Provides a snapshot of timing values.
return void
        protected override void Update(GameTime gameTime)
        {
            //Update input states
            Input.Update();
            //Process multiplayer
            if (NetManager.Client != null)
            {
                MsgHandler.ProcessNetworkMessages();
            }

            //Update input states
            IsMouseOnControl = !CheckPosition(Input.MousePosition.ToPoint());

            switch (CurrentGameState)
            {
                case GameState.Login:
                    {
                        break;
                    }
                case GameState.Game:
                    {
                        Map.Update(gameTime);
                        break;
                    }
            }
            base.Update(gameTime);
        }