Esempio n. 1
0
        private void ConstructSubMenus()
        {
            submenus = new List<Submenu>();

            Submenu s2 = new Submenu();
            s2.AddItem(new DelegateItem("Yes", restartEverything, Color.White, Color.Gray));
            s2.AddItem(new DelegateItem("No, exit", No, Color.White, Color.Gray));

            submenus.Add(s2);

            currentSubMenuIndex = 0;

        }
Esempio n. 2
0
        private void ConstructSubMenus()
        {
            submenus = new List<Submenu>();

            Submenu s2 = new Submenu();
            s2.AddItem(new DelegateItem("Back to Main Menu", openMenu, Color.White, Color.Gray));
            s2.AddItem(new DelegateItem("Resume Game", backToGame, Color.White, Color.Gray));

            submenus.Add(s2);  

            currentSubMenuIndex = 0;

        }
Esempio n. 3
0
        private void ConstructSubMenus()
        {
            submenus = new List<Submenu>();

            Submenu s2 = new Submenu();
            s2.AddItem(new ToggleItem("Music", new String[] { "On", "Off" }, (int)Globals.audioManager.Music));
            s2.AddItem(new ToggleItem("Volume", new String[] { "Low", "Medium", "High" }, (int)Globals.audioManager.Volume));
            s2.AddItem(new DelegateItem("Back", backToMain, Color.White, Color.Gray));

            submenus.Add(s2);  

            currentSubMenuIndex = 0;

        }
Esempio n. 4
0
        private void ConstructSubMenus(bool gameRunning)
        {
            submenus = new List<Submenu>();

            Submenu s0 = new Submenu();
            //s0.items.ElementAt(0)

            if (gameRunning == true)
            {
                s0.AddItem(new DelegateItem("Resume Game", goBack, Color.White, Color.Gray));
                s0.AddItem(new DelegateItem("New Game", RestartQuestion, Color.White, Color.Gray));
            }
            else
            {
                s0.AddItem(new TransitionItem("New Game", 1));
            }

            
            s0.AddItem(new DelegateItem("Controls", OpenControl, Color.White, Color.Gray));
            s0.AddItem(new DelegateItem("Settings", OpenSettings, Color.White, Color.Gray));
            s0.AddItem(new DelegateItem("About", OpenAbout, Color.White, Color.Gray));
            s0.AddItem(new DelegateItem("Exit", ExitQuestion, Color.White, Color.Gray));

            submenus.Add(s0);

            Submenu s1 = new Submenu();
            s1.AddItem(new DelegateItem("Start Game", StartGame, Color.LightBlue, Color.CornflowerBlue));
            s1.AddItem(new ToggleItem("Players", new String[] { "1", "2" }, 0));
            s1.AddItem(new ToggleItem("Level Length", new String[] { "Short", "Medium", "Tiring" }, 0));
            s1.AddItem(new ToggleItem("Difficulty", new String[] { "Easy", "Medium", "Hard" }, 0));

            submenus.Add(s1);

            currentSubMenuIndex = 0;

        }