AddLabel() public method

public AddLabel ( int x, int y, int hue, string text ) : void
x int
y int
hue int
text string
return void
Esempio n. 1
0
		public override void WriteToGump( Gump g, ref int y )
		{
			string amount = m_DesiredAmount.ToString();

			g.AddHtmlLocalized( 98, y, 312, 16, 1072204, 0x15F90, false, false ); // Slay
			g.AddLabel( 133, y, 0x481, amount );

			if ( m_Name.Number > 0 )
				g.AddHtmlLocalized( 133 + amount.Length * 15, y, 190, 18, m_Name.Number, 0x77BF, false, false );
			else if ( m_Name.String != null )
				g.AddLabel( 133 + amount.Length * 15, y, 0x481, m_Name.String );

			y += 16;

			#region Location
			if ( m_Area != null )
			{
				g.AddHtmlLocalized( 103, y, 312, 20, 1018327, 0x15F90, false, false ); // Location

				if ( m_Area.Name.Number > 0 )
					g.AddHtmlLocalized( 223, y, 312, 20, m_Area.Name.Number, 0xFFFFFF, false, false );
				else if ( m_Area.Name.String != null )
					g.AddLabel( 223, y, 0x481, m_Area.Name.String );

				y += 16;
			}
			#endregion
		}
Esempio n. 2
0
		public override void WriteToGump( Gump g, ref int y )
		{
			if ( ShowDetailed )
			{
				string amount = m_DesiredAmount.ToString();

				g.AddHtmlLocalized( 98, y, 350, 16, 1072205, 0x15F90, false, false ); // Obtain
				g.AddLabel( 143, y, 0x481, amount );

				if ( m_Name.Number > 0 )
				{
					g.AddHtmlLocalized( 143 + amount.Length * 15, y, 190, 18, m_Name.Number, 0x77BF, false, false );
					g.AddItem( 350, y, LabelToItemID( m_Name.Number ) );
				}
				else if ( m_Name.String != null )
				{
					g.AddLabel( 143 + amount.Length * 15, y, 0x481, m_Name.String );
				}
			}
			else
			{
				if ( m_Name.Number > 0 )
					g.AddHtmlLocalized( 98, y, 312, 32, m_Name.Number, 0x15F90, false, false );
				else if ( m_Name.String != null )
					g.AddLabel( 98, y, 0x481, m_Name.String );
			}

			y += 32;
		}
Esempio n. 3
0
 public virtual void AddText(Gump gump)
 {
     gump.AddLabel(Location.X, Location.Y, Hue, DisplayText);
     if (Underlined)
     {
         gump.AddImageTiled(Location.X, Location.Y + FontHandling.FONT_LINE_HEIGHT - 1, LabelWidthInPixels, HYPERLINK_UNDERLINE_HEIGHT_IN_PIXELS, HyperLinkUnderlineGumpId); //Top Divisor Image
     }
 }
Esempio n. 4
0
		public override void WriteToGump( Gump g, ref int y )
		{
			g.AddHtmlLocalized( 98, y, 312, 16, 1072206, 0x15F90, false, false ); // Escort to

			if ( m_Destination.Name.Number > 0 )
				g.AddHtmlLocalized( 173, y, 312, 20, m_Destination.Name.Number, 0xFFFFFF, false, false );
			else if ( m_Destination.Name.String != null )
				g.AddLabel( 173, y, 0x481, m_Destination.Name.String );

			y += 16;
		}
Esempio n. 5
0
        /// <summary>
        /// Sets up a new page for the GumpList to add items to.
        /// </summary>
        /// <param name="title">The title of the page.</param>
        /// <param name="first">Determines if actions for the first page should be taken.</param>
        /// <param name="last">Determines if actions for the last page should be taken.</param>
        /// <param name="pg">The page number of this page.</param>
        private void SetupPage(string title, bool first, bool last, int pg)
        {
            if (topbar != null)
            {
                topbar.X = X;                //+sk.ListStartX;
                topbar.Y = Y;                //+sk.ListStartY;
                topbar.AppendTo(page);
            }
            ButtonInfo ListPrevButton = sk.ButtonInfo["ListPrevButton"];
            ButtonInfo ListNextButton = sk.ButtonInfo["ListNextButton"];

            //ButtonInfo inf2 = sk.ButtonInfo["ListDoneButton"];
            page.AddPage(pg);
            page.AddLabel(sk.ListTitleX, sk.ListTitleY, sk.ListTitleHue, title);
            DebugWrite("Page: " + pg);
            if (!first)
            {
                DebugWrite("Adding previous button: " + (pg - 1));
                if (ListPrevButton.bgID != 0)
                {
                    this.AddSuperButton(X + ListPrevButton.X, Y + ListPrevButton.Y, ListPrevButton.H, ListPrevButton.W, ListPrevButton.bgID, sk.ListUnderButtonN, sk.ListUnderButtonP, ListPrevButton.text, GumpButtonType.Page, 0, pg - 1);
                }
                else
                {
                    page.AddButton(ListPrevButton.X, ListPrevButton.Y, ListPrevButton.up, ListPrevButton.down, 1, GumpButtonType.Page, pg - 1);
                }
            }
            if (!last)
            {
                DebugWrite("Adding next button: " + (pg + 1));
                if (ListNextButton.bgID != 0)
                {
                    this.AddSuperButton(X + ListNextButton.X, Y + ListNextButton.Y, ListNextButton.H, ListNextButton.W, ListNextButton.bgID, sk.ListUnderButtonN, sk.ListUnderButtonP, ListNextButton.text, GumpButtonType.Page, 0, pg + 1);
                }
                else
                {
                    page.AddButton(ListNextButton.X, ListNextButton.Y, ListNextButton.up, ListNextButton.down, 1, GumpButtonType.Page, pg + 1);
                }
            }
            //AddSuperButton(inf2.X, inf2.Y, inf2.H, inf2.W, inf2.bgID, sk.EntryButtonUnderlay, sk.EntryButtonUnderlay, inf2.text, GumpButtonType.Reply, 1, 0);
        }
Esempio n. 6
0
        // same as above but with two entries side by side and label included
        public static void AddTextEntryMinMaxLabel(Gump g, string s, int imageid, int x, int y, int hue, int entryIdMin, int entryIdMax, string initialText, int size, string name = "")
        {
            //Label
            g.AddLabel(x, y, hue, s);

            // Min
            g.AddImageTiled((x + 10 - (StringWitdth(s) / 2)) + 35, y - 1, /*height*/ 52, /*width*/ 20, imageid);
            g.AddTextEntry((x + 10 - (StringWitdth(s) / 2)) + 35, y - 1, 52, 20, hue, entryIdMin, "Min", size);

            // Max
            g.AddImageTiled((x + 10 - (StringWitdth(s) / 2)) + 97, y - 1, 52, 20, imageid);
            g.AddTextEntry((x + 10 - (StringWitdth(s) / 2)) + 97, y - 1, 52, 20, hue, entryIdMax, "Max", size);
        }
Esempio n. 7
0
        // same as above but with two entries side by side and label included
        public static void AddTextEntryMinMaxLabel( Gump g, string s, int imageid, int x, int y, int hue, int entryIdMin, int entryIdMax, string initialText, int size, string name = "")
        {
            //Label
            g.AddLabel(x, y, hue, s);

            // Min
            g.AddImageTiled( (x + 10 -  (StringWitdth(s) / 2)) + 35 , y -1 , /*height*/ 52, /*width*/ 20, imageid);
            g.AddTextEntry( (x + 10 - (StringWitdth(s) / 2))+ 35 , y- 1 , 52, 20, hue, entryIdMin, "Min", size);

            // Max
            g.AddImageTiled( (x + 10 - (StringWitdth(s) / 2)) + 97 , y -1 , 52, 20, imageid);
            g.AddTextEntry( (x + 10 - (StringWitdth(s) / 2)) + 97 , y -1 , 52, 20, hue, entryIdMax, "Max", size );
        }
Esempio n. 8
0
        // same as above but with two entries side by side and label included
        public static void AddTextEntryMinMax(Gump g, string s, int imageid, int labelX, int entryX, int y, int hue, int entryIdMin, int entryIdMax, string initialText, int size, string name = "")
        {
            //Label
            g.AddLabel(labelX, y, hue, s);

            // Min
            g.AddImageTiled(entryX - 1, y - 2, 52 + 2, 20 + 2, 9204);
            g.AddImageTiled(entryX, y - 1, /*height*/ 52, /*width*/ 20, imageid);
            g.AddTextEntry(entryX, y - 1, 52, 20, hue, entryIdMin, "Min", size);

            // Max
            g.AddImageTiled(entryX + 62 - 1, y - 2, 52 + 2, 20 + 2, 9204);
            g.AddImageTiled(entryX + 62, y - 1, 52, 20, imageid);
            g.AddTextEntry(entryX + 62, y - 1, 52, 20, hue, entryIdMax, "Max", size);
        }
Esempio n. 9
0
        // same as above but with two entries side by side and label included
        public static void AddTextEntryMinMax( Gump g, string s, int imageid, int labelX, int entryX , int y, int hue, int entryIdMin, int entryIdMax, string initialText, int size, string name = "")
        {
            //Label
            g.AddLabel(labelX, y, hue, s);

            // Min
            g.AddImageTiled( entryX - 1, y - 2, 52 + 2, 20 + 2, 9204);
            g.AddImageTiled( entryX, y -1 , /*height*/ 52, /*width*/ 20, imageid);
            g.AddTextEntry( entryX, y- 1 , 52, 20, hue, entryIdMin, "Min", size );

            // Max
            g.AddImageTiled( entryX + 62 - 1, y - 2, 52 + 2, 20 + 2, 9204);
            g.AddImageTiled( entryX + 62 , y -1 , 52, 20, imageid);
            g.AddTextEntry( entryX + 62 , y -1 , 52, 20, hue, entryIdMax, "Max", size );
        }
Esempio n. 10
0
		public override void WriteToGump( Gump g, ref int y )
		{
			string amount = m_Amount.ToString();

			g.AddHtmlLocalized( 98, y, 312, 16, 1072207, 0x15F90, false, false ); // Deliver
			g.AddLabel( 143, y, 0x481, amount );

			if ( m_Name.Number > 0 )
			{
				g.AddHtmlLocalized( 143 + amount.Length * 15, y, 190, 18, m_Name.Number, 0x77BF, false, false );
				g.AddItem( 350, y, CollectObjective.LabelToItemID( m_Name.Number ) );
			}
			else if ( m_Name.String != null )
			{
				g.AddLabel( 143 + amount.Length * 15, y, 0x481, m_Name.String );
			}

			y += 32;

			g.AddHtmlLocalized( 103, y, 120, 16, 1072379, 0x15F90, false, false ); // Deliver to
			g.AddLabel( 223, y, 0x481, QuesterNameAttribute.GetQuesterNameFor( m_Destination ) );

			y += 16;
		}
        public static void AddLabelledButton( Gump gump, KeyValuePair<string, int> kvp, int index )
        {
            if( kvp.Key == null )
                return;

            gump.AddButton( gump.X, gump.Y, 1209, 1210, index, GumpButtonType.Reply, 0 );
            gump.AddLabel( gump.X + 18, gump.Y - 1, 0, kvp.Key );
            gump.Y += 23;
        }
Esempio n. 12
0
		public static void WriteTimeRemaining( Gump g, ref int y, TimeSpan timeRemaining )
		{
			g.AddHtmlLocalized( 103, y, 120, 16, 1062379, 0x15F90, false, false ); // Est. time remaining:
			g.AddLabel( 223, y, 0x481, timeRemaining.TotalSeconds.ToString( "F0" ) );
			y += 16;
		}
		public override void Gump( Mobile from, Gump gump, object[] subParams )
		{
			gump.AddButton( 190, 40, 2445, 2445, 101, GumpButtonType.Reply, 0 );
			gump.AddLabel(  204, 42, 1153, "List Mobiles" );
			gump.AddButton( 310, 40, 2445, 2445, 102, GumpButtonType.Reply, 0 );
			gump.AddLabel(  331, 42, 1153, "List Items" );
			gump.AddButton( 430, 40, 2445, 2445, 103, GumpButtonType.Reply, 0 );
			gump.AddLabel(  450, 42, 1153, "List Types" );
//			gump.AddButton( 190, 70, 2445, 2445, 104, GumpButtonType.Reply, 0 );
//			gump.AddLabel(  208, 72, 1153, "Add Module" );
//			gump.AddButton( 310, 70, 2445, 2445, 105, GumpButtonType.Reply, 0 );
//			gump.AddLabel(  326, 72, 1153, "Edit Module" );
//			gump.AddButton( 430, 70, 2445, 2445, 106, GumpButtonType.Reply, 0 );
//			gump.AddLabel(  439, 72, 1153, "Delete Module" );

			if( subParams == null )
			{
				gump.AddHtml( 215, 15, 300,  25, "<basefont size=7 color=white><center>Central Memory</center></font>", false, false );
				gump.AddHtml( 140, 95, 450, 250, "<basefont color=white><center>Welcome to the Central Memory Admin Gump!</center><br>With this gump, you can see a list of all entries that the CM contains.  You can add new Modules or modify or delete existing Modules.<br><br>Make your selection from the top buttons, either List Mobiles or Items.  This will bring up a list of all Mobiles or Items that the CM is keeping track of.<br><br>You may then select one of the entries to list the Modules that are stored to that entry.  You can then add, modify or remove modules to that entry.</font>", false, false );
				return;
			}

			Params = subParams;

			if( subParams[0] is int && (int)subParams[0] == -2 )
			{//Mobiles
				gump.AddLabel( 120, 95, 1153, "Listing all Mobiles:" );

				e_List = GetMobiles();
				if( e_List == null || e_List.Count == 0 )
					return;

				int p = 0;
				if( subParams.Length == 2 && subParams[1] is int )
					p = (int)subParams[1];

				if( p < 0 )
					p = 0;


				if( p > 0 )
					gump.AddButton( 120, 332, 4014, 4015, 104, GumpButtonType.Reply, 0 );
				if( (p+1)*21 <= e_List.Count )
					gump.AddButton( 540, 332, 4005, 4006, 105, GumpButtonType.Reply, 0 );

				for( int i = p*21, r = 0, c = 0; i < e_List.Count; i++ )
				{
					Mobile m = (Mobile)e_List[i];
					if( m == null )
						continue;
					gump.AddButton( 120+c*155, 125+r*30, 2501, 2501, 1000+i, GumpButtonType.Reply, 0 );
					gump.AddLabel(  130+c*155, 126+r*30, 1153, (m.Name==null?m.Serial.ToString():m.Name) );
				}
			}

			else if( subParams[0] is int && (int)subParams[0] == -3 )
			{//Items
				gump.AddLabel( 120, 95, 1153, "Listing all Items:" );

				e_List = GetItems();
				if( e_List == null || e_List.Count == 0 )
					return;

				int p = 0;
				if( subParams.Length == 2 && subParams[1] is int )
					p = (int)subParams[1];

				if( p < 0 )
					p = 0;

				if( p > 0 )
					gump.AddButton( 120, 332, 4014, 4015, 104, GumpButtonType.Reply, 0 );
				if( (p+1)*21 <= e_List.Count )
					gump.AddButton( 540, 332, 4005, 4006, 105, GumpButtonType.Reply, 0 );

				for( int i = p*21, r = 0, c = 0; i < e_List.Count; i++ )
				{
					Item m = (Item)e_List[i];
					if( m == null )
						continue;
					gump.AddButton( 120+c*155, 125+r*30, 2501, 2501, 1000+i, GumpButtonType.Reply, 0 );
					gump.AddLabel(  130+c*155, 126+r*30, 1153, (m.Name==null?m.Serial.ToString():m.Name) );
				}
			}

			else if( subParams[0] is Serial )
			{//List the Modules for that serial
				Serial s = (Serial)subParams[0];
				if( !m_Modules.Contains( s ) )
				{
					gump.AddLabel( 120, 95, 1153, "This entity no longer exists in the Central Memory!" );
					return;
				}

				ModuleList ml = (ModuleList)m_Modules[s];
				if( ml == null || ml.Count == 0 )
				{
					gump.AddLabel( 120, 95, 1153, "This entity has no Modules!" );
					Remove( s );
					return;
				}

				string name = "";
				if( s.IsMobile )
					name = World.FindMobile( s ).Name;
				else if( s.IsItem )
					name = World.FindItem( s ).Name;

				if( name == null || name.Length == 0 )
					name = s.ToString();

				gump.AddLabel( 120, 95, 1153, String.Format( "Listing all Modules for {0}:", name ) );

				m_List = new ArrayList( ml.Values );
				if( m_List == null || m_List.Count == 0 )
					return;

				int p = 0;
				if( subParams.Length == 3 && subParams[2] is int )
					p = (int)subParams[2];

				if( p < 0 )
					p = 0;
				if( p*21 >= m_List.Count )
					p = m_List.Count-21;

				if( p > 0 )
					gump.AddButton( 120, 332, 4014, 4015, 104, GumpButtonType.Reply, 0 );
				if( (p+1)*21 <= m_List.Count )
					gump.AddButton( 540, 332, 4005, 4006, 105, GumpButtonType.Reply, 0 );

				gump.AddButton( 331, 332, 4008, 4009, 106, GumpButtonType.Reply, 0 );

				for( int i = p*21, r = 0, c = 0; i < m_List.Count; i++ )
				{
					Module m = (Module)m_List[i];
					if( m == null )
						continue;

					gump.AddButton( 120+c*155, 125+r*30, 2501, 2501, 1000+i, GumpButtonType.Reply, 0 );
					gump.AddLabel(  130+c*155, 126+r*30, 1153, (m.Name().Length==0?m.Owner.ToString():m.Name()) );
				}
			}
		}
Esempio n. 14
0
		public override void WriteToGump( Gump g, ref int y )
		{
			m_Objective.WriteToGump( g, ref y );
			y -= 16;

			if ( m_Objective.ShowDetailed )
			{
				base.WriteToGump( g, ref y );

				g.AddHtmlLocalized( 103, y, 120, 16, 3000087, 0x15F90, false, false ); // Total
				g.AddLabel( 223, y, 0x481, GetCurrentTotal().ToString() );
				y += 16;

				g.AddHtmlLocalized( 103, y, 120, 16, 1074782, 0x15F90, false, false ); // Return to
				g.AddLabel( 223, y, 0x481, QuesterNameAttribute.GetQuesterNameFor( Instance.QuesterType ) );
				y += 16;
			}
		}
Esempio n. 15
0
 public void AppendToGump(Gump g, int x, int y)
 {
     g.AddLabel(x, y, 1150, Name);
     g.AddButton(x - 18, y + 5, 5032, 2361, ItemID, GumpButtonType.Reply, 0);
 }
Esempio n. 16
0
 public virtual void AddText(Gump gump)
 {
     gump.AddLabel(Location.X, Location.Y, Hue, DisplayText);
     if (Underlined)
     {
         gump.AddImageTiled(Location.X, Location.Y + FontHandling.FONT_LINE_HEIGHT - 1, LabelWidthInPixels, HYPERLINK_UNDERLINE_HEIGHT_IN_PIXELS, HyperLinkUnderlineGumpId); //Top Divisor Image
     }
 }
		public void AddTitle(string title, string type, Gump g)
		{
			switch (type)
			{
				case "Control":
					g.AddLabel(Skin.NameLabelX, Skin.NameLabelY, Skin.White, title);
					break;
			}
		}
		public void AddSuperButton(int x, int y, int height, int width, int overlayID, int underID, int underIDpr, string text, GumpButtonType type, int replyID, int pageNum, Gump g)
		{
			g.AddImageTiledButton(x, y, underID, underIDpr, replyID, type, pageNum, 0, 0, width, height);
			//this.AddButton(x + 1, y+((height - 20) / 2), underID, underIDpr, replyID, type, pageNum);
			g.AddImageTiled(x, y, width, height, overlayID);
			g.AddLabel(x + 5, y + ((height - 18) / 2), Skin.NormalText, text);
		}
Esempio n. 19
0
        public override void Gump(Mobile from, Gump gump, ACCGumpParams subParams)
        {
            gump.AddButton(195, 40, 2445, 2445, 101, GumpButtonType.Reply, 0);
            gump.AddLabel(200, 41, 1153, "Manage System");
            gump.AddButton(310, 40, 2445, 2445, 102, GumpButtonType.Reply, 0);
            gump.AddLabel(342, 41, 1153, "Import");

            if (subParams == null || !(subParams is PGGumpParams))
            {
                gump.AddHtml(215, 65, 300, 25, "<basefont size=7 color=white><center>Public Gates</center></font>", false, false);
                gump.AddHtml(140, 95, 450, 250, "<basefont color=white><center>Welcome to the Public Gate Admin Gump!</center><br>With this gump, you can manage the entire system and import and export locations or full categories.  Please choose an option from the top bar.<br><br>Manage System allows you to add/change/delete locations and categories from anywhere in the world.<br><br>Im/Ex port allows you to import or export categories and locations to files that you can distribute to other servers that use this system.</font>", false, false);
                return;
            }

            Params = subParams as PGGumpParams;

            switch ((int)Params.Page)
            {
                #region Manage Gump Code
                case (int)Pages.Manage:
                    {
                        gump.AddBackground(640, 0, 160, 400, 5120);
                        gump.AddButton(425, 40, 2445, 2445, 123, GumpButtonType.Reply, 0);
                        gump.AddLabel(456, 41, 1153, "Export");

                        for (int i = 0; i < m_CategoryList.Count && i < 50; i++)
                        {
                            PGCategory PGC = m_CategoryList[i];
                            if (PGC != null)
                            {
                                gump.AddButton(650, 10 + i * 30, 2501, 2501, 150 + i, GumpButtonType.Reply, 0);
                                gump.AddButton(655, 12 + i * 30, (Params.SelectedCategory.Key == PGC ? 5401 : 5402), (Params.SelectedCategory.Key == PGC ? 5402 : 5401), 150 + i, GumpButtonType.Reply, 0);
                                gump.AddLabel(675, 10 + i * 30, 1153, PGC.Name);
                            }
                        }

                        if (Params.SelectedCategory.Key != null)
                        {
                            gump.AddBackground(425, 75, 170, 285, 5120);
                            gump.AddButton(195, 65, 2445, 2445, 121, GumpButtonType.Reply, 0);
                            gump.AddLabel(206, 66, 1153, "Add Category");
                            gump.AddButton(310, 65, 2445, 2445, 122, GumpButtonType.Reply, 0);
                            gump.AddLabel(322, 66, 1153, "Add Location");

                            for (int i = 0, c = 0, r = 0; i < Params.SelectedCategory.Key.Locations.Count; i++)
                            {
                                PGLocation PGL = Params.SelectedCategory.Key.Locations[i];
                                if (PGL != null)
                                {
                                    gump.AddButton(120 + c * 150, 100 + r * 30, 2501, 2501, 200 + i, GumpButtonType.Reply, 0);
                                    gump.AddButton(125 + c * 150, 102 + r * 30, (Params.SelectedLocation.Key == PGL ? 5401 : 5402), (Params.SelectedLocation.Key == PGL ? 5402 : 5401), 200 + i, GumpButtonType.Reply, 0);
                                    gump.AddLabel(145 + c * 150, 100 + r * 30, 1153, PGL.Name);
                                    r += (c == 1 ? 1 : 0);
                                    c += (c == 1 ? -1 : 1);
                                }
                            }

                            if (Params.SelectedLocation.Key != null)
                            {
                                gump.AddButton(550, 265, 2642, 2643, 103, GumpButtonType.Reply, 0); //Apply Location

                                gump.AddImage(440, 85, 2501);
                                gump.AddTextEntry(446, 85, 130, 20, 0, 105, Params.SelectedLocation.Key.Name);

                                gump.AddImage(445, 110, 2443);
                                gump.AddImage(513, 110, 2443);
                                gump.AddImage(445, 135, 2443);
                                gump.AddImage(513, 135, 2443);
                                gump.AddImage(445, 160, 2443);

                                gump.AddTextEntry(450, 110, 53, 20, 0, 106, Params.SelectedLocation.Key.Location.X.ToString());
                                gump.AddTextEntry(518, 110, 53, 20, 0, 107, Params.SelectedLocation.Key.Location.Y.ToString());
                                gump.AddTextEntry(450, 135, 53, 20, 0, 108, Params.SelectedLocation.Key.Location.Z.ToString());
                                gump.AddTextEntry(518, 135, 53, 20, 0, 109, Params.SelectedLocation.Key.Hue.ToString());
                                gump.AddTextEntry(450, 160, 53, 20, 0, 110, Params.SelectedLocation.Key.Cost.ToString());

                                gump.AddLabel(435, 112, 1153, "X");
                                gump.AddLabel(578, 112, 1153, "Y");
                                gump.AddLabel(435, 137, 1153, "Z");
                                gump.AddLabel(578, 137, 1153, "H");
                                gump.AddLabel(435, 162, 1153, "C");

                                gump.AddRadio(435, 190, 208, 209, (Params.SelectedLocation.Key.Map == Map.Trammel), 111);
                                gump.AddRadio(570, 190, 208, 209, (Params.SelectedLocation.Key.Map == Map.Malas), 112);
                                gump.AddRadio(435, 215, 208, 209, (Params.SelectedLocation.Key.Map == Map.Felucca), 113);
                                gump.AddRadio(570, 215, 208, 209, (Params.SelectedLocation.Key.Map == Map.Ilshenar), 114);
                                gump.AddRadio(435, 240, 208, 209, (Params.SelectedLocation.Key.Map == Map.Tokuno), 115);

                                gump.AddLabel(460, 192, 1153, "Tram");
                                gump.AddLabel(530, 192, 1153, "Malas");
                                gump.AddLabel(460, 217, 1153, "Fel");
                                gump.AddLabel(542, 217, 1153, "Ilsh");
                                gump.AddLabel(460, 242, 1153, "Tokuno");

                                gump.AddLabel(465, 282, 1153, "Young?");
                                gump.AddCheck(440, 280, 210, 211, Params.SelectedLocation.Key.GetFlag(EntryFlag.Young), 120);
                                gump.AddLabel(465, 307, 1153, "Gen?");
                                gump.AddCheck(440, 305, 210, 211, Params.SelectedLocation.Key.GetFlag(EntryFlag.Generate), 116);
                                gump.AddLabel(515, 307, 1153, "Staff?");
                                gump.AddCheck(565, 305, 210, 211, Params.SelectedLocation.Key.GetFlag(EntryFlag.StaffOnly), 117);
                                gump.AddLabel(465, 332, 1153, "Reds?");
                                gump.AddCheck(440, 330, 210, 211, Params.SelectedLocation.Key.GetFlag(EntryFlag.Reds), 118);
                                gump.AddLabel(522, 332, 1153, "Chrg?");
                                gump.AddCheck(565, 330, 210, 211, Params.SelectedLocation.Key.GetFlag(EntryFlag.Charge), 119);
                            }

                            else
                            {
                                gump.AddButton(550, 265, 2642, 2643, 104, GumpButtonType.Reply, 0); //Apply Category

                                gump.AddImage(440, 110, 2501);
                                gump.AddTextEntry(446, 110, 130, 20, 0, 105, Params.SelectedCategory.Key.Name);

                                gump.AddImage(445, 160, 2443);
                                gump.AddTextEntry(450, 160, 53, 20, 0, 110, Params.SelectedCategory.Key.Cost.ToString());
                                gump.AddLabel(435, 162, 1153, "C");

                                gump.AddLabel(465, 282, 1153, "Young?");
                                gump.AddCheck(440, 280, 210, 211, Params.SelectedCategory.Key.GetFlag(EntryFlag.Young), 120);
                                gump.AddLabel(465, 307, 1153, "Gen?");
                                gump.AddCheck(440, 305, 210, 211, Params.SelectedCategory.Key.GetFlag(EntryFlag.Generate), 116);
                                gump.AddLabel(515, 307, 1153, "Staff?");
                                gump.AddCheck(565, 305, 210, 211, Params.SelectedCategory.Key.GetFlag(EntryFlag.StaffOnly), 117);
                                gump.AddLabel(465, 332, 1153, "Reds?");
                                gump.AddCheck(440, 330, 210, 211, Params.SelectedCategory.Key.GetFlag(EntryFlag.Reds), 118);
                                gump.AddLabel(522, 332, 1153, "Chrg?");
                                gump.AddCheck(565, 330, 210, 211, Params.SelectedCategory.Key.GetFlag(EntryFlag.Charge), 119);
                            }
                        }
                        break;
                    }
                #endregion //Manage Gump Code

                #region Import Gump Code
                case (int)Pages.Import:
                    {//Import
                        if (!Directory.Exists("ACC Exports"))
                        {
                            from.SendMessage("There are no files to import!");
                            return;
                        }

                        gump.AddButton(195, 65, 2445, 2445, 124, GumpButtonType.Reply, 0); //Switch to Systems
                        gump.AddLabel(220, 66, 1153, "Systems");

                        gump.AddButton(310, 65, 2445, 2445, 125, GumpButtonType.Reply, 0); //Switch to Categories
                        gump.AddLabel(328, 66, 1153, "Categories");

                        gump.AddButton(425, 65, 2445, 2445, 126, GumpButtonType.Reply, 0); //Switch to Locations
                        gump.AddLabel(447, 66, 1153, "Locations");
                        switch ((int)Params.ImportSelection)
                        {
                            case (int)ImportSelections.Systems: { Dirs = Directory.GetFiles("ACC Exports/", "*.pgs"); break; }
                            case (int)ImportSelections.Categories: { Dirs = Directory.GetFiles("ACC Exports/", "*.pgc"); break; }
                            case (int)ImportSelections.Locations: { Dirs = Directory.GetFiles("ACC Exports/", "*.pgl"); break; }
                            default: { return; }
                        }
                        if (Dirs == null || Dirs.Length == 0)
                        {
                            from.SendMessage("There are no files of that type!");
                            return;
                        }
                        for (int i = 0, r = 0, c = 0; i < Dirs.Length && c < 3; i++)
                        {
                            string s = Dirs[i];
                            s = s.Remove(0, 12);
                            s = s.Remove(s.Length - 4, 4);
                            if (Params.ImportSelection == ImportSelections.Systems)
                                s = s.Remove(0, 9);

                            gump.AddButton(120 + c * 150, 100 + r * 30, 2501, 2501, 300 + i, GumpButtonType.Reply, 0);
                            gump.AddLabelCropped(125 + c * 150, 101 + r * 30, 140, 30, 1153, s);

                            c += (r == 7 ? 1 : 0);
                            r += (r == 7 ? -7 : 1);
                        }
                        break;
                    }
                #endregion //Import Gump Code
            }
        }