本文整理汇总了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;
}
示例2: CentralGumpInformationUI
public CentralGumpInformationUI(PlayerMobile user, Gump parent, string msg)
: base(user, parent, 115, 0)
{
CanMove = true;
Modal = false;
HTML = msg;
}
示例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);
*/
}
示例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
}
示例5: DonationTransactionOverviewGump
public DonationTransactionOverviewGump(
PlayerMobile user, Gump parent, DonationProfile profile, DonationTransaction trans)
: base(user, parent)
{
Profile = profile;
Transaction = trans;
}
示例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;
}
示例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;
}
示例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);
}
示例9: DonationGiftGump
public DonationGiftGump(
PlayerMobile user, Gump parent, DonationProfile profile, DonationTransaction trans, PlayerMobile to = null)
: base(user, parent)
{
Profile = profile;
Transaction = trans;
To = to;
}
示例10: CloseGumpTimer
public CloseGumpTimer( Mobile from, Gump g, TimeSpan delay )
: base( delay )
{
m_From = from;
m_Gump = g;
Priority = TimerPriority.OneSecond;
}
示例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;
}
示例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;
}
示例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;
}
示例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;
}
示例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;
}