示例#1
0
        // process input
        public void ProcessInput(float elapsedTime)
        {
            inputManager.BeginInputProcessing(
                gameManager.GameMode == GameMode.SinglePlayer);

            // process input for currently active screen
            if (current != null && next == null)
            {
                current.ProcessInput(elapsedTime, inputManager);
            }

            // toggle full screen with F5 key
            if (inputManager.IsKeyPressed(0, Keys.F5) ||
                inputManager.IsKeyPressed(1, Keys.F5))
            {
                shipGame.ToggleFullScreen();
            }

            inputManager.EndInputProcessing();
        }