当前位置: 首页>>代码示例>>C#>>正文


C# Gumps.Gump类代码示例

本文整理汇总了C#中Server.Gumps.Gump的典型用法代码示例。如果您正苦于以下问题:C# Gump类的具体用法?C# Gump怎么用?C# Gump使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。


Gump类属于Server.Gumps命名空间,在下文中一共展示了Gump类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: AnalogClock

		public AnalogClock(
			PlayerMobile user, Gump parent = null, int? x = null, int? y = null, int radius = -1, TimeSpan? time = null)
			: base(user, parent, x, y)
		{
			Radius = radius <= 0 ? DefaultRadius : radius;

			RomanNumerals = false;

			DisplayNumerals = true;
			DisplayHourHand = true;
			DisplayMinuteHand = true;
			DisplaySecondHand = true;

			ColorNumerals = DefaultNumeralsColor;
			ColorHourHand = DefaultHourHandColor;
			ColorMinuteHand = DefaultMinuteHandColor;
			ColorSecondHand = DefaultSecondHandColor;

			if (time != null)
			{
				Time = time.Value;
				RealTime = false;
			}
			else
			{
				Time = DateTime.Now.TimeOfDay;
				RealTime = true;
			}

			ForceRecompile = true;

			AutoRefresh = RealTime;
		}
开发者ID:greeduomacro,项目名称:RuneUO,代码行数:33,代码来源:AnalogClock.cs

示例2: CentralGumpInformationUI

 public CentralGumpInformationUI(PlayerMobile user, Gump parent, string msg)
     : base(user, parent, 115, 0)
 {
     CanMove = true;
     Modal = false;
     HTML = msg;
 }
开发者ID:greeduomacro,项目名称:UO-Forever,代码行数:7,代码来源:CentralGumpInformationUI.cs

示例3:

        void IHTMLBookGump.DrawToSurface(Gump gump, int x, int y, string page1Text, string page2Text, int page)
        {
            /*gump.AddImage(x, y, m_Book.GumpID);

            gump.AddHtml( 29 + x + m_Book.HTMLOffset.X, 23 + y + m_Book.HTMLOffset.Y, 147, 167, page1Text, (bool)false, (bool)false);
            gump.AddHtml( 186 + x + m_Book.HTMLOffset.X, 23 + y + m_Book.HTMLOffset.Y, 147, 167, page2Text, (bool)false, (bool)false);*/
            gump.AddBackground(x-22+22, y+4, 646, 362, 5120);
            gump.AddBackground(x+22, y+13, 606, 343, 9300);
            if ( page + 2 < m_Book.HTMLContent.CachedHTMLContent.Length )
                gump.AddButton(x+576, y+0, 2469, 2471, (int)Buttons.NextPage, GumpButtonType.Reply, 0);
            if ( page - 2 >= 0 )
                gump.AddButton(x+492, y+0, 2466, 2468, (int)Buttons.PreviousPage, GumpButtonType.Reply, 0);

            gump.AddHtml( x+31, y+26, 274, 314, page1Text, (bool)false, (bool)false);
            gump.AddHtml( x+343, y+26, 274, 314, page2Text, (bool)false, (bool)false);
            gump.AddImage(x+316, y+341, 10204);
            gump.AddImageTiled(x+316, y+28, 17, 318, 10201);
            gump.AddImage(x+316, y+13, 10202);
            gump.AddHtml( x+31, y+333, 274, 20, "<CENTER><SMALL><B>" + (page+1), (bool)false, (bool)false);
            gump.AddHtml( x+343, y+333, 274, 20, "<CENTER><SMALL><B>" + (page+2), (bool)false, (bool)false);

            /*if ( page + 2 < m_Book.HTMLContent.CachedHTMLContent.Length )
                gump.AddButton(294 + x + m_Book.NextPageButtonOffset.X, 4 + y + m_Book.NextPageButtonOffset.Y, 2236, 2236, (int)Buttons.NextPage, GumpButtonType.Reply, 0);

            if ( page - 2 >= 0 )
                gump.AddButton(23 + x + m_Book.PrevPageButtonOffset.X, 5 + y + m_Book.PrevPageButtonOffset.Y, 2235, 2235, (int)Buttons.PreviousPage, GumpButtonType.Reply, 0);
            */
        }
开发者ID:justdanofficial,项目名称:khaeros,代码行数:28,代码来源:OffsetableBookGump.cs

示例4: WriteToGump

		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
		}
开发者ID:greeduomacro,项目名称:last-wish,代码行数:28,代码来源:KillObjective.cs

示例5: DonationTransactionOverviewGump

		public DonationTransactionOverviewGump(
			PlayerMobile user, Gump parent, DonationProfile profile, DonationTransaction trans)
			: base(user, parent)
		{
			Profile = profile;
			Transaction = trans;
		}
开发者ID:greeduomacro,项目名称:RuneUO,代码行数:7,代码来源:TransactionGump.cs

示例6: DialogGump

		public DialogGump(
			PlayerMobile user,
			Gump parent = null,
			int? x = null,
			int? y = null,
			string title = null,
			string html = null,
			int icon = -1,
			Action<GumpButton> onAccept = null,
			Action<GumpButton> onCancel = null)
			: base(user, parent, x, y)
		{
			Modal = true;
			CanDispose = false;
			HtmlBackground = false;
			HtmlColor = DefaultHtmlColor;

			Width = Defaultwidth;
			Height = DefaultHeight;

			Title = title ?? DefaultTitle;
			Html = html;
			Icon = (icon >= 0) ? icon : DefaultIcon;

			AcceptHandler = onAccept;
			CancelHandler = onCancel;
		}
开发者ID:jasegiffin,项目名称:JustUO,代码行数:27,代码来源:Dialog.cs

示例7: WriteToGump

		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;
		}
开发者ID:jackuoll,项目名称:Pre-AOS-RunUO,代码行数:29,代码来源:CollectObjective.cs

示例8: Draw

 public void Draw(Gump g, int x, int y, bool player)
 {
     if (!player)
         g.AddBackground(x, y, 90, 115, 3000);
     g.AddHtml(x, y + 5, 32, 25, String.Format("<BODY TEXT='{0}'><center>{1}</center></BODY>", GetHue(), GetValueString(false)), false, false);
     g.AddHtml(x, y + 25, 32, 25, String.Format("<BODY TEXT='{0}'><center>{1}</center></BODY>", GetHue(), String.Format("{0}", (char)GetSymbol())), false, false);
 }
开发者ID:kamronbatman,项目名称:DefianceUO-Pre1.10,代码行数:7,代码来源:Card.cs

示例9: DonationGiftGump

		public DonationGiftGump(
			PlayerMobile user, Gump parent, DonationProfile profile, DonationTransaction trans, PlayerMobile to = null)
			: base(user, parent)
		{
			Profile = profile;
			Transaction = trans;
			To = to;
		}
开发者ID:jasegiffin,项目名称:JustUO,代码行数:8,代码来源:GiftGump.cs

示例10: CloseGumpTimer

		public CloseGumpTimer( Mobile from, Gump g, TimeSpan delay )
			: base( delay )
		{
			m_From = from;
			m_Gump = g;

			Priority = TimerPriority.OneSecond;
		}
开发者ID:greeduomacro,项目名称:hubroot,代码行数:8,代码来源:CloseGumpTimer.cs

示例11: PokerWebsiteGump

 public PokerWebsiteGump(PlayerMobile user, int handid, Gump parent = null)
     : base(user, parent, 200, 270)
 {
     Closable = true;
     Disposable = false;
     Dragable = true;
     Resizable = false;
     HandId = handid;
 }
开发者ID:AdamUOF,项目名称:UOFTexasHoldem,代码行数:9,代码来源:PokerWebsiteGump.cs

示例12: PokerBetGump

 public PokerBetGump(PlayerMobile user, PokerGame game, PokerPlayer player, Gump parent = null)
     : base(user, parent, 526, 449)
 {
     Closable = false;
     Disposable = false;
     Dragable = true;
     Resizable = false;
     _Player = player;
     _Game = game;
 }
开发者ID:AdamUOF,项目名称:UOFTexasHoldem,代码行数:10,代码来源:PokerBetGump.cs

示例13: TrashHandlerIgnoreListGump

		public TrashHandlerIgnoreListGump(PlayerMobile user, BaseTrashHandler handler, Gump parent = null)
			: base(
				user,
				parent,
				list: handler.Ignored,
				title: handler.GetType().Name + " Ignore List",
				emptyText: "There are no Types in the list.")
		{
			TrashHandler = handler;
		}
开发者ID:greeduomacro,项目名称:UO-Forever,代码行数:10,代码来源:HandlerIgnoreList.cs

示例14: InvasionDetailsUI

        public InvasionDetailsUI(PlayerMobile user, Gump parent = null, Invasion invasion = null)
            : base(user, parent, 0, 0)
        {
            CanMove = true;
            Modal = false;

            ForceRecompile = true;

            Invasion = invasion;
        }
开发者ID:greeduomacro,项目名称:UO-Forever,代码行数:10,代码来源:Invasiondetails.cs

示例15: TrashHandlerAcceptListGump

		public TrashHandlerAcceptListGump(Mobile user, BaseTrashHandler handler, Gump parent = null)
			: base(
				user,
				parent,
				list: handler.Accepted,
				title: handler.GetType().Name + " Accept List",
				emptyText: "There are no Types in the list.")
		{
			TrashHandler = handler;
		}
开发者ID:Ravenwolfe,项目名称:Core,代码行数:10,代码来源:HandlerAcceptList.cs


注:本文中的Server.Gumps.Gump类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。