예제 #1
0
        /// <summary>
        /// Allows the game to perform any initialization it needs to before starting to run.
        /// This is where it can query for any required services and load any non-graphic
        /// related content.  Calling base.Initialize will enumerate through any components
        /// and initialize them as well.
        /// </summary>
        protected override void Initialize()
        {
            // TODO: Add your initialization logic here
            gameState = GameState.TitleScreen;
            mainMenu = new MainMenu();
            audioManager = new AudioManager(this);
            Texture2D titlepic = Content.Load<Texture2D>("TitleImage");
            titleScreen = new TitleScreen(titlepic, new Vector2(Globals.SCREEN_WIDTH, Globals.SCREEN_HEIGHT), TimeSpan.FromSeconds(1), TimeSpan.FromSeconds(4), true);
            titleScreen.AddImage(Content.Load<Texture2D>("TitleInfo"));

            base.Initialize();
        }
예제 #2
0
 public override void Activate(MainMenu mainMenu)
 {
     mainMenu.DisplayMenu(options);
 }
예제 #3
0
 public override void Activate(MainMenu mainMenu)
 {
     mainMenu.BackToMainMenu();
 }
예제 #4
0
 public override void Activate(MainMenu mainMenu)
 {
     Level level = new Level("Levels/" + name);
     Globals.game.LoadNewLevel(level);
 }
예제 #5
0
 public override void Activate(MainMenu mainMenu)
 {
     mainMenu.DisplayMenu(levels);
 }
예제 #6
0
 public virtual void Activate(MainMenu mainMenu)
 {
 }