public override void Load()
        {
            fntText = Content.Load <SpriteFont>("Fonts/Arial10");

            Gametype GametypeCampaign    = new Gametype("Campaign", "Classic mission based mode, no respawn.", null);
            Gametype GametypeHorde       = new Gametype("Horde", "Wave survival mode, respawn at the start of each wave.", null);
            Gametype GametypeBaseDefense = new Gametype("Base Defense", "Wave survival mode, respawn at the start of each wave. Must defend a base by building turrets.", null);

            Gametype GametypeDeathmatch    = new Gametype("Deathmatch", "Gain points for kills and assists, respawn on death.", null);
            Gametype GametypeObjective     = new Gametype("Objective", "One team must complete objectives while another prevent them.", null);
            Gametype GametypeAssault       = new Gametype("Assault", "Team deathmatch with limited respawns.", null);
            Gametype GametypeConquest      = new Gametype("Conquest", "Teams must fight to capture respawn bases that give them points. The starting base may or may not be capturable.", null);
            Gametype GametypeOnslaught     = new Gametype("Onslaught", "Teams must fight to capture respawn bases that give them access to the enemy base's core. Last team with a core win.", null);
            Gametype GametypeKingOfTheHill = new Gametype("King Of The Hill", "Hold a position without enemies to win points.", null);
            Gametype GametypeBunny         = new Gametype("Bunny", "Unit that holds the flag become the bunny and gets points for kills, everyone else try to kill the bunny.", null);
            Gametype GametypeFreezeTag     = new Gametype("Freeze Tag", "Killing an enemy freeze him, when every enemies are frozen you win. Teamates can unfreeze allie by staying next to them for 2 turns.", null);
            Gametype GametypeJailbreak     = new Gametype("Jailbreak", "Killing an enemy send him to your prison, capture everyone to win. Teamates can be freed by standing on a switch.", null);
            Gametype GametypeMutant        = new Gametype("Mutant", "First kill transform you into the mutant, a unit with overpowered stats and attacks. Only the Mutant can kill or be killed.", null);
            Gametype GametypeKaiju         = new Gametype("Kaiju", "One player controls giant monsters while the other players use their units.", null);

            SelectedGametype         = GametypeCampaign;
            ArrayGametypeCategory    = new GametypeCategory[2];
            ArrayGametypeCategory[0] = new GametypeCategory("PVE", new Gametype[] { GametypeCampaign, GametypeHorde });
            ArrayGametypeCategory[1] = new GametypeCategory("PVP", new Gametype[]
            {
                GametypeDeathmatch, GametypeObjective, GametypeAssault, GametypeConquest,
                GametypeOnslaught, GametypeKingOfTheHill, GametypeBunny, GametypeFreezeTag,
                GametypeJailbreak, GametypeMutant, GametypeKaiju,
            });

            int PanelY      = (int)(Constants.Height * 0.15);
            int PanelWidth  = (int)(Constants.Width * 0.4);
            int PanelHeight = (int)(Constants.Height * 0.75);

            int LeftPanelX = (int)(Constants.Width * 0.03);

            GametypeScrollbar = new BoxScrollbar(new Vector2(LeftPanelX + PanelWidth - 20, PanelY), PanelHeight, 10, OnGametypeScrollbarChange);
        }
예제 #2
0
        public override void Load()
        {
            sndButtonOver  = new FMODSound(FMODSystem, "Content/Triple Thunder/Menus/SFX/Button Over.wav");
            sndButtonClick = new FMODSound(FMODSystem, "Content/Triple Thunder/Menus/SFX/Button Click.wav");

            fntArial12 = Content.Load <SpriteFont>("Fonts/Arial12");

            ListPlayerProfile = BattleMapPlayer.GetProfileNames();

            int   MenuWidth  = (int)(Constants.Width * 0.45);
            int   MenuHeight = (int)(Constants.Height * 0.45);
            float MenuX      = Constants.Width / 2 - MenuWidth / 2;
            float MenuY      = Constants.Height / 2 - MenuHeight / 2;

            ProfilesScrollbar = new BoxScrollbar(new Vector2(MenuX + MenuWidth - 20, MenuY), MenuHeight, Math.Max(0, ListPlayerProfile.Count - 9), OnProfileScrollbarChange);
            ConfirmButton     = new BoxButton(new Rectangle((int)MenuX + 10, (int)MenuY + MenuHeight + 5, 70, 30), fntArial12, "Confirm", OnButtonOver, OnConfirmButtonPressed);
            CancelButton      = new BoxButton(new Rectangle((int)MenuX + MenuWidth - 80, (int)MenuY + MenuHeight + 5, 70, 30), fntArial12, "Cancel", OnButtonOver, OnCancelButtonPressed);

            ArrayUIElement = new IUIElement[]
            {
                ConfirmButton, CancelButton, ProfilesScrollbar,
            };
        }
        public override void Load()
        {
            fntText = Content.Load<SpriteFont>("Fonts/Arial10");
            for (int i = 0; i < 40; ++i)
            {
                ListAvailableMutators.Add(new Mutator("Test" + i, "Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum"));
            }
            AvailableMutatorsScrollbar = new BoxScrollbar(new Vector2(LeftPanelX + PanelWidth - 20, PanelY + 30), PanelHeight - 30, ListAvailableMutators.Count, OnAvailableMutatorsScrollbarChange);
            ActiveMutatorsScrollbar = new BoxScrollbar(new Vector2(RightPanelX + PanelWidth - 20, PanelY + 30), PanelHeight - 30, 10, OnActiveMutatorsScrollbarChange);

            AddButton = new BoxButton(new Rectangle(ButtonsX, ButtonsY, ButtonsWidth, ButtonsHeight), fntText, "Add", OnButtonOver, OnAddPressed);
            ButtonsY += 40;
            AddAllButton = new BoxButton(new Rectangle(ButtonsX, ButtonsY, ButtonsWidth, ButtonsHeight), fntText, "Add All", OnButtonOver, OnAddAllPressed);
            ButtonsY += 90;
            RemoveButton = new BoxButton(new Rectangle(ButtonsX, ButtonsY, ButtonsWidth, ButtonsHeight), fntText, "Remove", OnButtonOver, OnRemovePressed);
            ButtonsY += 40;
            RemoveAllButton = new BoxButton(new Rectangle(ButtonsX, ButtonsY, ButtonsWidth, ButtonsHeight), fntText, "Remove All", OnButtonOver, OnRemoveAllPressed);

            ArrayMenuButton = new IUIElement[]
            {
                AvailableMutatorsScrollbar, ActiveMutatorsScrollbar,
                AddButton, AddAllButton, RemoveButton, RemoveAllButton,
            };
        }
        public override void Load()
        {
            fntText = Content.Load <SpriteFont>("Fonts/Arial10");

            MapScrollbar = new BoxScrollbar(new Vector2(LeftPanelX + PanelWidth - 20, PanelY), PanelHeight, 10, OnGametypeScrollbarChange);
        }