public override void Draw(SpriteBatch spriteBatch)
 {
     base.Draw(spriteBatch);
     if (confirm == true)
     {
         quitScreen.Draw(spriteBatch);
     }
 }
Example #2
0
        /// <summary>
        /// This is called when the game should draw itself.
        /// </summary>
        /// <param name="gameTime">Provides a snapshot of timing values.</param>
        protected override void Draw(GameTime gameTime)
        {
            // TODO: Add your drawing code here
            this.GraphicsDevice.Clear(Color.Black);

            switch (appState)
            {
            case ApplicationState.Splash:       splashScreen.Draw(spriteBatch);
                break;

            case ApplicationState.Home:         homeScreen.Draw(spriteBatch);
                break;

            case ApplicationState.Quit:         homeScreen.Draw(spriteBatch);
                quitScreen.Draw(spriteBatch);
                break;

            case ApplicationState.Options:      optionsScreen.Draw(spriteBatch);
                break;

            case ApplicationState.Trial:        trialScreen.Draw(spriteBatch);
                break;

            case ApplicationState.GameOver:     gameOverScreen.Draw(spriteBatch);
                break;

            case ApplicationState.GameComplete: break;

            case ApplicationState.InitaliseApp: break;

            case ApplicationState.InitaliseGame: break;

            //ApplicationState.Playing || ApplicationState.Paused || ApplicationState.LevelComplete
            default:                            gameState.Draw(gameTime, appState, spriteBatch);
                break;
            }

            base.Draw(gameTime);
        }