예제 #1
0
 public static bool CheckCanGrow(BaseCrop crop, Map map, int x, int y)
 {
     if (crop.CanGrowFarm && ValidateFarmLand(map, x, y))
     {
         return(true);
     }
     if (crop.CanGrowDirt && ValidateDirt(map, x, y))
     {
         return(true);
     }
     if (crop.CanGrowGround && ValidateGround(map, x, y))
     {
         return(true);
     }
     if (crop.CanGrowSand && ValidateSand(map, x, y))
     {
         return(true);
     }
     if (crop.CanGrowSwamp && ValidateSwamp(map, x, y))
     {
         return(true);
     }
     if (crop.CanGrowGarden)
     {
         crop.BumpZ = ValidateGardenPlot(map, x, y);
         return(crop.BumpZ);
     }
     return(false);
 }
예제 #2
0
		public UpRootGump( Mobile owner, BaseCrop crop ) : base( 60, 60 )
		{
			owner.CloseGump( typeof( UpRootGump ) );

			m_Owner = owner;
			m_crop = crop;

			Closable = true;
			Disposable = true;
			Dragable = true;
			Resizable = false;

			AddPage( 0 );

			AddImage( 0, 0, 0x816 );
			AddButton( 34, 74, 0x81A, 0x81B, 1, GumpButtonType.Reply, 0 ); // OK
			AddButton( 88, 74, 0x995, 0x996, 2, GumpButtonType.Reply, 0 ); // Cancel

			string msg = "Do you wish to destroy this crop?";
			AddHtml( 30, 25, 120, 40, msg, false, false );
		}
예제 #3
0
        public UpRootGump(Mobile owner, BaseCrop crop) : base(60, 60)
        {
            owner.CloseGump(typeof(UpRootGump));

            m_Owner = owner;
            m_crop  = crop;

            Closable   = true;
            Disposable = true;
            Dragable   = true;
            Resizable  = false;

            AddPage(0);

            AddImage(0, 0, 0x816);
            AddButton(34, 74, 0x81A, 0x81B, 1, GumpButtonType.Reply, 0);               // OK
            AddButton(88, 74, 0x995, 0x996, 2, GumpButtonType.Reply, 0);               // Cancel

            string msg = "Do you wish to destroy this crop?";

            AddHtml(30, 25, 120, 40, msg, false, false);
        }