コード例 #1
0
            public BannerOfYewAddonGump(Mobile from, BannerOfYewAddon addon) : base(150, 50)
            {
                m_From  = from;
                m_Addon = addon;

                AddPage(0);

                AddBackground(0, 0, 220, 170, 0x13BE);
                AddBackground(10, 10, 200, 150, 0xBB8);
                AddHtmlLocalized(20, 30, 180, 60, 1062839, false, false);                   // Do you wish to re-deed this decoration?
                AddHtmlLocalized(55, 100, 160, 25, 1011011, false, false);                  // CONTINUE
                AddButton(20, 100, 0xFA5, 0xFA7, 1, GumpButtonType.Reply, 0);
                AddHtmlLocalized(55, 125, 160, 25, 1011012, false, false);                  // CANCEL
                AddButton(20, 125, 0xFA5, 0xFA7, 0, GumpButtonType.Reply, 0);
            }
コード例 #2
0
        private void PlaceAddon(Mobile from, Point3D loc, bool northWall, bool westWall)
        {
            if (Deleted)
            {
                return;
            }

            BaseHouse house = BaseHouse.FindHouseAt(loc, from.Map, 16);

            if (house == null || !house.IsCoOwner(from))
            {
                from.SendLocalizedMessage(1042036);                   // That location is not in your house.
                return;
            }

            int itemID = 0;

            if (northWall)
            {
                itemID = 0x4B66;
            }
            else if (westWall)
            {
                itemID = 0x4B6F;
            }
            else
            {
                from.SendLocalizedMessage(1062840);                   // The decoration must be placed next to a wall.
            }
            if (itemID > 0)
            {
                Item addon = new BannerOfYewAddon();

                addon.ItemID = itemID;
                addon.MoveToWorld(loc, from.Map);

                house.Addons.Add(addon);
                Delete();
            }
        }
コード例 #3
0
		private void PlaceAddon( Mobile from, Point3D loc, bool northWall, bool westWall )
		{
			if ( Deleted )
				return;

			BaseHouse house = BaseHouse.FindHouseAt( loc, from.Map, 16 );

			if ( house == null || !house.IsCoOwner( from ) )
			{
				from.SendLocalizedMessage( 1042036 ); // That location is not in your house.
				return;
			}

			int itemID = 0;

			if ( northWall )
				itemID = 0x4B66;
			else if ( westWall )
				itemID = 0x4B6F;
			else
				from.SendLocalizedMessage( 1062840 ); // The decoration must be placed next to a wall.

			if ( itemID > 0 )
			{
				Item addon = new BannerOfYewAddon();

				addon.ItemID = itemID;
				addon.MoveToWorld( loc, from.Map );

				house.Addons.Add( addon );
				Delete();
			}
		}
コード例 #4
0
			public BannerOfYewAddonGump( Mobile from, BannerOfYewAddon addon ) : base( 150, 50 )
			{
				m_From = from;
				m_Addon = addon;

				AddPage( 0 );

				AddBackground( 0, 0, 220, 170, 0x13BE );
				AddBackground( 10, 10, 200, 150, 0xBB8 );
				AddHtmlLocalized( 20, 30, 180, 60, 1062839, false, false ); // Do you wish to re-deed this decoration?
				AddHtmlLocalized( 55, 100, 160, 25, 1011011, false, false ); // CONTINUE
				AddButton( 20, 100, 0xFA5, 0xFA7, 1, GumpButtonType.Reply, 0 );
				AddHtmlLocalized( 55, 125, 160, 25, 1011012, false, false ); // CANCEL
				AddButton( 20, 125, 0xFA5, 0xFA7, 0, GumpButtonType.Reply, 0 );
			}