graphics.IsFullScreen = true;
//Add two new screens
screenManager.AddScreen(new BackgroundScreen(), null);
screenManager.AddScreen(new MainMenuScreen(), null);
Note that the constructor also contains a commented out initialization of an “AudioManager” class. We will deal with this class in the next exercise (and un-comment the relevant code to initialize it).
The game’s main menu
Pressing the play menu item will reveal the instructions screen, which will not move on to the game until the next exercise.
The final part of this task will be to add an additional screen, which will be of use later. Create a new class under the “Screens” folder and call it PauseScreen.
Open the new class file and add the following using statements at the top of the file.
Page | 29