Ejemplo n.º 1
0
        public void HandleInput(GameTime gameTime, World world, 
            Actor currentActor)
        {
            Vector2 leftThumbstick = GamePad.GetState(playerIndex).ThumbSticks.Left;
            Vector2 rightThumbstick = GamePad.GetState(playerIndex).ThumbSticks.Right;

            if (leftThumbstick.X != 0 || leftThumbstick.Y != 0)
            {
                currentActor.ExCommand(new MoveCommand(leftThumbstick, currentActor.GetSpeed(), currentActor.GetPosition()));
            }

            if (rightThumbstick.X != 0 || rightThumbstick.Y != 0)
            {

            }
        }