예제 #1
0
 public GameOptions() :
     base(Engine.Instance.SpriteBatch, "MenuChoice", Engine.Instance.Width, Engine.Instance.Height, 210, 100)
 {
     AddChoice("play", "Play");
     AddChoice("playerCnt", "Players:", "1", "2");
     AddChoice("level", "Start at level: ", "1", "2", "3", "4", "5", "6", "7", "8", "9", "10", "12", "15", "20");
     AddChoice("back", "Back");
     SelectChoice += new OnSelectChoice(GameOptions_SelectChoice);
 }
예제 #2
0
        public MainMenu() :
            base(Engine.Instance.SpriteBatch, "MenuChoice", Engine.Instance.Width, Engine.Instance.Height, 210, 100)
        {
            //Texture = Common.str2Tex("Menu/MainBG01");
            Engine.Instance.Audio.PlayMusic("music");
            Engine.Instance.Audio.SetMusicVolume(5);
            Engine.Instance.Audio.SetSoundVolume(4);

            AddChoice("play", "Play");
            AddChoice("fullscreen", "Toggle full screen");
            AddChoice("credits", "Credits");
            AddChoice("exit", "Exit");
            SelectChoice += new OnSelectChoice(MainMenu_SelectChoice);
        }
예제 #3
0
 public MainMenu(bool replayMusic) :
     base(Engine.Instance.SpriteBatch, "MenuChoice", Engine.Instance.Width, Engine.Instance.Height, 250, 160)
 {
     if (replayMusic)
     {
         MP3MusicMgr.Instance.PlayMusic("mainTheme");
     }
     Texture = Common.str2Tex("Menu/spaceBG");
     AddChoice("play", "Play");
     AddChoice("highScores", "HighScores");
     AddChoice("options", "Options");
     AddChoice("credits", "Credits");
     AddChoice("exit", "Exit");
     SelectChoice += new OnSelectChoice(MainMenu_SelectChoice);
 }
        public OptionsMenu() :
            base(Engine.Instance.SpriteBatch, "MenuChoice", Engine.Instance.Width, Engine.Instance.Height, 250, 160)
        {
            Texture = Common.str2Tex("Menu/spaceBG");

            AddChoice("music", "Enable Music", "Yes", "No");
            if (!SettingsMgr.Instance.EnableMusic)
            {
                Choices[Choices.Count - 1].SetSelectedIdx(1);
            }

            AddChoice("fullscreen", "FullScreen", "Yes", "No");
            if (!SettingsMgr.Instance.IsFullScreen)
            {
                Choices[Choices.Count - 1].SetSelectedIdx(1);
            }

            AddChoice("ctrlType", "Control Type:", "Keyboard", "Mouse");
            if (SettingsMgr.Instance.ControlType1 == eControlType.Mouse)
            {
                Choices[Choices.Count - 1].SetSelectedIdx(1);
            }

            AddChoice("showSpawnTimer", "Show Spawn Timer:", "Yes", "No");
            if (!SettingsMgr.Instance.ShowSpawnTimer)
            {
                Choices[Choices.Count - 1].SetSelectedIdx(1);
            }

            AddChoice("skipTutorial", "Disable Tutorial:", "No", "Yes");
            if (SettingsMgr.Instance.SkipTutorial)
            {
                Choices[Choices.Count - 1].SetSelectedIdx(1);
            }

            AddChoice("showRoundGUI", "Enable Round GUI:", "No", "Yes");
            if (SettingsMgr.Instance.ShowRoundGUI)
            {
                Choices[Choices.Count - 1].SetSelectedIdx(1);
            }

            AddChoice("roundGUIAlpha", "Round GUI Alpha:", "32", "64", "96", "128", "160", "192", "224", "255");
            Choices[Choices.Count - 1].SetSelectedIdx((int)Math.Ceiling(SettingsMgr.Instance.RoundGUIAlpha / (float)32) - 1);

            AddChoice("back", "Back");
            SelectChoice     += new OnSelectChoice(OptionsMenu_SelectChoice);
            SelectionChanged += new OnSelectionChanged(OptionsMenu_SelectionChanged);
        }
        public GameOptions() :
            base(Engine.Instance.SpriteBatch, "MenuChoice", Engine.Instance.Width, Engine.Instance.Height, 250, 160, 400)
        {
            Texture = Common.str2Tex("Menu/spaceBG");
            AddChoice("play", "Play");
            AddChoice("playerShip", "Ship:", "Normal", "Destroyer", "Regeneration", "Cruiser", "Tanker");
            AddChoice("startWave", "Starting Wave:", 1, 3, 5, 10, 15, 20, 25, 30, 35, 40, 45, 50);
            AddChoice("area", "Area:", "Ireland", "Spain", "Siberia", "Artic Region");
            AddChoice("dropRate", "DropRate:", eDropRateMod.None, eDropRateMod.Low, eDropRateMod.Normal, eDropRateMod.High);
            Choices[Choices.Count - 1].SetSelectedIdx(2);
            AddChoice("waveDelay", "Wave Delay (s):", 10, 13, 16, 18, 20);
            Choices[Choices.Count - 1].SetSelectedIdx(3);
            AddChoice("music", "Music:", "Random", "Techno1", "Airship", "Poss");
            AddChoice("back", "Back");
            SelectChoice += new OnSelectChoice(GameOptions_SelectChoice);

            ScoreModifier     = GetScoreMod();
            SelectionChanged += new OnSelectionChanged(GameOptions_SelectionChanged);
            ValueChanged     += new OnValueChanged(GameOptions_ValueChanged);
        }