コード例 #1
0
		public UnattendedMacroGump( Mobile from, Mobile m ) : base( 70, 40 )
		{
			tbutton = ( new Random() ).Next( 6 );
			if( tbutton < 1 )
				tbutton = 1;
			if( tbutton > 6 )
				tbutton = 6;
			( (Account)m.Account ).Comments.Add( new AccountComment( JailSystem.JSName + "-warning", from.Name + " checked to see if " + m.Name + " was macroing unattended on: " + DateTime.Now ) );
			jailor = from;
			badBoy = m;
			Closable = false;
			Dragable = true;
			AddPage( 0 );
			AddBackground( 0, 0, 326, 320, 5054 );
			AddImageTiled( 9, 65, 308, 240, 2624 );
			AddAlphaRegion( 9, 65, 308, 240 );
			//AddLabel( 16, 20, 200, string.Format("{0} is checking to see if you are macroing unattended", jailor.Name));
			AddHtml( 16, 10, 250, 50, string.Format( "{0} is checking to see if you are macroing unattended", jailor.Name ), false, false );
			//let them show that they are there by selecting these buttons
			AddButton( 20, 72, 2472, 2473, 5, GumpButtonType.Reply, 0 );
			AddLabel( 50, 75, 200, tbutton == 5 ? "I'm here!" : "I confess I was macroing unattended." );
			AddButton( 20, 112, 2472, 2473, 1, GumpButtonType.Reply, 0 );
			AddLabel( 50, 115, 200, tbutton == 1 ? "I'm here!" : "I confess I was macroing unattended." );
			AddButton( 20, 152, 2472, 2473, 2, GumpButtonType.Reply, 0 );
			AddLabel( 50, 155, 200, tbutton == 2 ? "I'm here!" : "I confess I was macroing unattended." );
			AddButton( 20, 192, 2472, 2473, 3, GumpButtonType.Reply, 0 );
			AddLabel( 50, 195, 200, tbutton == 3 ? "I'm here!" : "I confess I was macroing unattended." );
			AddButton( 20, 232, 2472, 2473, 4, GumpButtonType.Reply, 0 );
			AddLabel( 50, 235, 200, tbutton == 4 ? "I'm here!" : "I confess I was macroing unattended." );
			AddButton( 20, 272, 2472, 2473, 6, GumpButtonType.Reply, 0 );
			AddLabel( 50, 275, 200, tbutton == 6 ? "I'm here!" : "I confess I was macroing unattended." );
			myTimer = new UAResponseTimer( this );
		}
コード例 #2
0
 public UnattendedMacroGump(Mobile from, Mobile m) : base(70, 40)
 {
     tbutton = (new Random()).Next(6);
     if (tbutton < 1)
     {
         tbutton = 1;
     }
     if (tbutton > 6)
     {
         tbutton = 6;
     }
     ((Account)m.Account).Comments.Add(new AccountComment(JailSystem.JSName + "-warning", from.Name + " checked to see if " + m.Name + " was macroing unattended on: " + DateTime.Now));
     jailor   = from;
     badBoy   = m;
     Closable = false;
     Dragable = true;
     AddPage(0);
     AddBackground(0, 0, 326, 320, 5054);
     AddImageTiled(9, 65, 308, 240, 2624);
     AddAlphaRegion(9, 65, 308, 240);
     //AddLabel( 16, 20, 200, string.Format("{0} is checking to see if you are macroing unattended", jailor.Name));
     AddHtml(16, 10, 250, 50, string.Format("{0} is checking to see if you are macroing unattended", jailor.Name), false, false);
     //let them show that they are there by selecting these buttons
     AddButton(20, 72, 2472, 2473, 5, GumpButtonType.Reply, 0);
     AddLabel(50, 75, 200, tbutton == 5 ? "I'm here!" : "I confess I was macroing unattended.");
     AddButton(20, 112, 2472, 2473, 1, GumpButtonType.Reply, 0);
     AddLabel(50, 115, 200, tbutton == 1 ? "I'm here!" : "I confess I was macroing unattended.");
     AddButton(20, 152, 2472, 2473, 2, GumpButtonType.Reply, 0);
     AddLabel(50, 155, 200, tbutton == 2 ? "I'm here!" : "I confess I was macroing unattended.");
     AddButton(20, 192, 2472, 2473, 3, GumpButtonType.Reply, 0);
     AddLabel(50, 195, 200, tbutton == 3 ? "I'm here!" : "I confess I was macroing unattended.");
     AddButton(20, 232, 2472, 2473, 4, GumpButtonType.Reply, 0);
     AddLabel(50, 235, 200, tbutton == 4 ? "I'm here!" : "I confess I was macroing unattended.");
     AddButton(20, 272, 2472, 2473, 6, GumpButtonType.Reply, 0);
     AddLabel(50, 275, 200, tbutton == 6 ? "I'm here!" : "I confess I was macroing unattended.");
     myTimer = new UAResponseTimer(this);
 }