public CityMallToken( CityLandLord lord, CivicSign sign, Mobile owner, MallDuration duration, int rent ) : base( null, duration, rent, owner ) { Name = String.Format( "A market token for the city of {0}", sign.Stone.CityName ); Hue = 1159; m_Lord = lord; m_Sign = sign; }
public override void Deserialize( GenericReader reader ) { base.Deserialize( reader ); int version = reader.ReadInt(); m_Lord = (CityLandLord)reader.ReadMobile(); m_Sign = (CivicSign)reader.ReadItem(); }
public CityMarketGump( CityLandLord lord ) : base( 0, 0 ) { m_lord = lord; this.Closable=true; this.Disposable=true; this.Dragable=true; this.Resizable=false; this.AddPage(0); this.AddBackground(59, 21, 286, 276, 9200); this.AddLabel(122, 44, 48, @"City Market Control"); this.AddLabel(89, 111, 92, @"Rent Fee:"); this.AddTextEntry(172, 111, 159, 20, 0, 0, @""); this.AddLabel(71, 84, 92, @"Current Rent:"); this.AddLabel(195, 85, 92, String.Format( "{0}",m_lord.RentCost.ToString() ) ); this.AddLabel(126, 142, 46, @"Rental Duration (Changing this does not affect current vendors"); this.AddButton(83, 175, 209, 208, 1, GumpButtonType.Reply, 0); this.AddButton(83, 200, 209, 208, 2, GumpButtonType.Reply, 0); this.AddButton(83, 225, 209, 208, 3, GumpButtonType.Reply, 0); this.AddButton(83, 250, 209, 208, 4, GumpButtonType.Reply, 0); this.AddLabel(107, 199, 92, @"Two Weeks"); this.AddLabel(107, 174, 92, @"One Week"); this.AddLabel(106, 223, 92, @"Three Weeks"); this.AddLabel(107, 249, 92, @"Four Weeks"); this.AddButton(297, 111, 2714, 2715, 5, GumpButtonType.Reply, 0); int index = (int)m_lord.Duration; switch ( index ) { case 0 : { this.AddImage(233, 174, 211); break; } case 1: { this.AddImage(233, 199, 211); break; } case 2: { this.AddImage(233, 223, 211); break; } case 3: { this.AddImage(233, 249, 211); break; } } }
public CityMarketRegion( CityManagementStone stone, CityLandLord lord, Map map, Rectangle3D[] area, CivicSign sign ) : base( PickRegionName(), map, MarketPriority, area ) { m_Stone = stone; m_LandLord = lord; m_Sign = sign; }
public void FinishPlacement( Mobile from, Point3D p ) { if ( Type == CivicStrutureType.FieldStoneCityHall ) { // City Bounds int offset = PlayerGovernmentSystem.L1CLOffset; Point2D center = new Point2D( p.X - m_Offset.X, p.Y - m_Offset.Y ); Point2D start = new Point2D( center.X - offset, center.Y - offset ); Point2D end = new Point2D( center.X + offset, center.Y + offset ); Rectangle2D box = new Rectangle2D( start, end ); ArrayList cityCoords = new ArrayList(); cityCoords.Add( box ); //Remove List ArrayList toDelete = new ArrayList(); // Add Mayor As Citizen ArrayList citizens = new ArrayList(); citizens.Add( from ); // Add Sponsor List ArrayList sponsor = new ArrayList(); // Add Ban List ArrayList ban = new ArrayList(); // Add Lockdown List ArrayList ld = new ArrayList(); // Add Waring List ArrayList war = new ArrayList(); // Add Wars Declare List ArrayList dwar = new ArrayList(); // Add Wars Invite List ArrayList iwar = new ArrayList(); // Add Allegiances List ArrayList allies = new ArrayList(); // Add Allegiances Declared List ArrayList dallies = new ArrayList(); // Add Allegiances Invited List ArrayList iallies = new ArrayList(); // Add Gardens And Parks ArrayList gardens = new ArrayList(); ArrayList parks = new ArrayList(); ArrayList vendor = new ArrayList(); ArrayList addon = new ArrayList(); // Add Management Stone CityManagementStone mStone = new CityManagementStone(); // Add City Region Rectangle3D[] area = PlayerGovernmentSystem.FormatRegion( box ); PlayerCityRegion reg = new PlayerCityRegion( mStone, from.Map, area ); reg.Register(); // Setup Stone mStone.RegionCoords = area; mStone.Coords = cityCoords; mStone.CityName = from.Name + "'s City"; mStone.Level = 1; mStone.Center = center; mStone.Mayor = from; mStone.PCRegion = reg; mStone.Citizens = citizens; mStone.Banned = ban; mStone.isLockedDown = ld; mStone.Sponsored = sponsor; mStone.Vendors = vendor; mStone.AddOns = addon; mStone.Waring = war; mStone.WarsDeclared = dwar; mStone.WarsInvited = iwar; mStone.Allegiances = allies; mStone.AllegiancesDeclared = dallies; mStone.AllegiancesInvited = iallies; mStone.Gardens = gardens; mStone.Parks = parks; // Setup Mayor PlayerMobile pm = (PlayerMobile)from; pm.City = mStone; pm.CityTitle = "Mayor"; pm.ShowCityTitle = true; FieldstoneCityHallAddon building = new FieldstoneCityHallAddon(); building.MoveToWorld( new Point3D( p.X - m_Offset.X, p.Y - m_Offset.Y, p.Z - m_Offset.Z ), from.Map ); BaseDoor d1 = new StrongWoodDoor( DoorFacing.WestCW ); BaseDoor d2 = new StrongWoodDoor( DoorFacing.EastCCW ); d1.Link = d2; d2.Link = d1; d1.MoveToWorld( new Point3D( p.X - 4, p.Y - 1, p.Z + 7 ), from.Map ); d2.MoveToWorld( new Point3D( p.X - 3, p.Y - 1, p.Z + 7 ), from.Map ); // Add Voters List ArrayList voters = new ArrayList(); CityVotingStone vStone = new CityVotingStone(); vStone.Voters = voters; vStone.Stone = mStone; mStone.VoteStone = vStone; toDelete.Add( vStone ); vStone.MoveToWorld( new Point3D( p.X, p.Y - 14, p.Z + 17 ), from.Map ); toDelete.Add( d1 ); toDelete.Add( d2 ); toDelete.Add( building ); mStone.toDelete = toDelete; mStone.MoveToWorld( new Point3D( p.X - 1, p.Y - 14, p.Z + 17 ), from.Map ); } else if ( Type == CivicStrutureType.SandstoneCityHall ) { // City Bounds int offset = PlayerGovernmentSystem.L1CLOffset; Point2D center = new Point2D( p.X - m_Offset.X, p.Y - m_Offset.Y ); Point2D start = new Point2D( center.X - offset, center.Y - offset ); Point2D end = new Point2D( center.X + offset, center.Y + offset ); Rectangle2D box = new Rectangle2D( start, end ); ArrayList cityCoords = new ArrayList(); cityCoords.Add( box ); //Remove List ArrayList toDelete = new ArrayList(); // Add Mayor As Citizen ArrayList citizens = new ArrayList(); citizens.Add( from ); // Add Sponsor List ArrayList sponsor = new ArrayList(); // Add Ban List ArrayList ban = new ArrayList(); // Add Lockdown List ArrayList ld = new ArrayList(); // Add Waring List ArrayList war = new ArrayList(); // Add Wars Declare List ArrayList dwar = new ArrayList(); // Add Wars Invite List ArrayList iwar = new ArrayList(); // Add Allegiances List ArrayList allies = new ArrayList(); // Add Allegiances Declared List ArrayList dallies = new ArrayList(); // Add Allegiances Invited List ArrayList iallies = new ArrayList(); // Add Gardens And Parks ArrayList gardens = new ArrayList(); ArrayList parks = new ArrayList(); ArrayList vendor = new ArrayList(); ArrayList addon = new ArrayList(); // Add Management Stone CityManagementStone mStone = new CityManagementStone(); // Add City Region Rectangle3D[] area = PlayerGovernmentSystem.FormatRegion( box ); PlayerCityRegion reg = new PlayerCityRegion( mStone, from.Map, area ); reg.Register(); // Setup Stone mStone.RegionCoords = area; mStone.Coords = cityCoords; mStone.CityName = from.Name + "'s City"; mStone.Level = 1; mStone.Center = center; mStone.Mayor = from; mStone.PCRegion = reg; mStone.Citizens = citizens; mStone.Banned = ban; mStone.isLockedDown = ld; mStone.Sponsored = sponsor; mStone.Vendors = vendor; mStone.AddOns = addon; mStone.Waring = war; mStone.WarsDeclared = dwar; mStone.WarsInvited = iwar; mStone.Allegiances = allies; mStone.AllegiancesDeclared = dallies; mStone.AllegiancesInvited = iallies; mStone.Gardens = gardens; mStone.Parks = parks; // Setup Mayor PlayerMobile pm = (PlayerMobile)from; pm.City = mStone; pm.CityTitle = "Mayor"; pm.ShowCityTitle = true; SandstoneCityHallAddon building = new SandstoneCityHallAddon(); building.MoveToWorld( new Point3D( p.X - m_Offset.X, p.Y - m_Offset.Y, p.Z - m_Offset.Z ), from.Map ); BaseDoor d1 = new StrongWoodDoor( DoorFacing.WestCW ); BaseDoor d2 = new StrongWoodDoor( DoorFacing.EastCCW ); d1.Link = d2; d2.Link = d1; d1.MoveToWorld( new Point3D( p.X + 3, p.Y - 1, p.Z + 7 ), from.Map ); d2.MoveToWorld( new Point3D( p.X + 4, p.Y - 1, p.Z + 7 ), from.Map ); // Add Voters List ArrayList voters = new ArrayList(); CityVotingStone vStone = new CityVotingStone(); vStone.Voters = voters; vStone.Stone = mStone; mStone.VoteStone = vStone; toDelete.Add( vStone ); vStone.MoveToWorld( new Point3D( p.X - 5, p.Y - 14, p.Z + 7 ), from.Map ); toDelete.Add( d1 ); toDelete.Add( d2 ); toDelete.Add( building ); mStone.toDelete = toDelete; mStone.MoveToWorld( new Point3D( p.X - 6, p.Y - 14, p.Z + 7 ), from.Map ); } else if ( Type == CivicStrutureType.MarbleCityHall ) { // City Bounds int offset = PlayerGovernmentSystem.L1CLOffset; Point2D center = new Point2D( p.X - m_Offset.X, p.Y - m_Offset.Y ); Point2D start = new Point2D( center.X - offset, center.Y - offset ); Point2D end = new Point2D( center.X + offset, center.Y + offset ); Rectangle2D box = new Rectangle2D( start, end ); ArrayList cityCoords = new ArrayList(); cityCoords.Add( box ); //Remove List ArrayList toDelete = new ArrayList(); // Add Mayor As Citizen ArrayList citizens = new ArrayList(); citizens.Add( from ); // Add Sponsor List ArrayList sponsor = new ArrayList(); // Add Ban List ArrayList ban = new ArrayList(); // Add Lockdown List ArrayList ld = new ArrayList(); // Add Waring List ArrayList war = new ArrayList(); // Add Wars Declare List ArrayList dwar = new ArrayList(); // Add Wars Invite List ArrayList iwar = new ArrayList(); // Add Allegiances List ArrayList allies = new ArrayList(); // Add Allegiances Declared List ArrayList dallies = new ArrayList(); // Add Allegiances Invited List ArrayList iallies = new ArrayList(); // Add Gardens And Parks ArrayList gardens = new ArrayList(); ArrayList parks = new ArrayList(); ArrayList vendor = new ArrayList(); ArrayList addon = new ArrayList(); // Add Management Stone CityManagementStone mStone = new CityManagementStone(); // Add City Region Rectangle3D[] area = PlayerGovernmentSystem.FormatRegion( box ); PlayerCityRegion reg = new PlayerCityRegion( mStone, from.Map, area ); reg.Register(); // Setup Stone mStone.RegionCoords = area; mStone.Coords = cityCoords; mStone.CityName = from.Name + "'s City"; mStone.Level = 1; mStone.Center = center; mStone.Mayor = from; mStone.PCRegion = reg; mStone.Citizens = citizens; mStone.Banned = ban; mStone.isLockedDown = ld; mStone.Sponsored = sponsor; mStone.Vendors = vendor; mStone.AddOns = addon; mStone.Waring = war; mStone.WarsDeclared = dwar; mStone.WarsInvited = iwar; mStone.Allegiances = allies; mStone.AllegiancesDeclared = dallies; mStone.AllegiancesInvited = iallies; mStone.Gardens = gardens; mStone.Parks = parks; // Setup Mayor PlayerMobile pm = (PlayerMobile)from; pm.City = mStone; pm.CityTitle = "Mayor"; pm.ShowCityTitle = true; MarbleCityHallAddon building = new MarbleCityHallAddon(); building.MoveToWorld( new Point3D( p.X - m_Offset.X, p.Y - m_Offset.Y, p.Z - m_Offset.Z ), from.Map ); BaseDoor d1 = new StrongWoodDoor( DoorFacing.WestCW ); BaseDoor d2 = new StrongWoodDoor( DoorFacing.EastCCW ); d1.Link = d2; d2.Link = d1; d1.MoveToWorld( new Point3D( p.X - 1, p.Y - 1, p.Z + 7 ), from.Map ); d2.MoveToWorld( new Point3D( p.X, p.Y - 1, p.Z + 7 ), from.Map ); // Add Voters List ArrayList voters = new ArrayList(); CityVotingStone vStone = new CityVotingStone(); vStone.Voters = voters; vStone.Stone = mStone; mStone.VoteStone = vStone; toDelete.Add( vStone ); vStone.MoveToWorld( new Point3D( p.X - 5, p.Y - 14, p.Z + 7 ), from.Map ); toDelete.Add( d1 ); toDelete.Add( d2 ); toDelete.Add( building ); mStone.toDelete = toDelete; mStone.MoveToWorld( new Point3D( p.X - 6, p.Y - 14, p.Z + 7 ), from.Map ); } else if ( Type == CivicStrutureType.NecroCityHall ) { // City Bounds int offset = PlayerGovernmentSystem.L1CLOffset; Point2D center = new Point2D( p.X - m_Offset.X, p.Y - m_Offset.Y ); Point2D start = new Point2D( center.X - offset, center.Y - offset ); Point2D end = new Point2D( center.X + offset, center.Y + offset ); Rectangle2D box = new Rectangle2D( start, end ); ArrayList cityCoords = new ArrayList(); cityCoords.Add( box ); //Remove List ArrayList toDelete = new ArrayList(); // Add Mayor As Citizen ArrayList citizens = new ArrayList(); citizens.Add( from ); // Add Sponsor List ArrayList sponsor = new ArrayList(); // Add Ban List ArrayList ban = new ArrayList(); // Add Lockdown List ArrayList ld = new ArrayList(); // Add Waring List ArrayList war = new ArrayList(); // Add Wars Declare List ArrayList dwar = new ArrayList(); // Add Wars Invite List ArrayList iwar = new ArrayList(); // Add Allegiances List ArrayList allies = new ArrayList(); // Add Allegiances Declared List ArrayList dallies = new ArrayList(); // Add Allegiances Invited List ArrayList iallies = new ArrayList(); // Add Gardens And Parks ArrayList gardens = new ArrayList(); ArrayList parks = new ArrayList(); ArrayList vendor = new ArrayList(); ArrayList addon = new ArrayList(); // Add Management Stone CityManagementStone mStone = new CityManagementStone(); // Add City Region Rectangle3D[] area = PlayerGovernmentSystem.FormatRegion( box ); PlayerCityRegion reg = new PlayerCityRegion( mStone, from.Map, area ); reg.Register(); // Setup Stone mStone.RegionCoords = area; mStone.Coords = cityCoords; mStone.CityName = from.Name + "'s City"; mStone.Level = 1; mStone.Center = center; mStone.Mayor = from; mStone.PCRegion = reg; mStone.Citizens = citizens; mStone.Banned = ban; mStone.isLockedDown = ld; mStone.Sponsored = sponsor; mStone.Vendors = vendor; mStone.AddOns = addon; mStone.Waring = war; mStone.WarsDeclared = dwar; mStone.WarsInvited = iwar; mStone.Allegiances = allies; mStone.AllegiancesDeclared = dallies; mStone.AllegiancesInvited = iallies; mStone.Gardens = gardens; mStone.Parks = parks; // Setup Mayor PlayerMobile pm = (PlayerMobile)from; pm.City = mStone; pm.CityTitle = "Mayor"; pm.ShowCityTitle = true; NecroCityHallAddon building = new NecroCityHallAddon(); building.MoveToWorld( new Point3D( p.X - m_Offset.X, p.Y - m_Offset.Y, p.Z - m_Offset.Z ), from.Map ); BaseDoor d1 = new StrongWoodDoor( DoorFacing.WestCW ); BaseDoor d2 = new StrongWoodDoor( DoorFacing.EastCCW ); d1.Link = d2; d2.Link = d1; d1.MoveToWorld( new Point3D( p.X - 5, p.Y - 1, p.Z + 7 ), from.Map ); d2.MoveToWorld( new Point3D( p.X - 4, p.Y - 1, p.Z + 7 ), from.Map ); // Add Voters List ArrayList voters = new ArrayList(); CityVotingStone vStone = new CityVotingStone(); vStone.Voters = voters; vStone.Stone = mStone; mStone.VoteStone = vStone; toDelete.Add( vStone ); vStone.MoveToWorld( new Point3D( p.X - 5, p.Y - 14, p.Z + 7 ), from.Map ); toDelete.Add( d1 ); toDelete.Add( d2 ); toDelete.Add( building ); mStone.toDelete = toDelete; mStone.MoveToWorld( new Point3D( p.X - 6, p.Y - 14, p.Z + 7 ), from.Map ); } else if ( Type == CivicStrutureType.PlasterCityHall ) { // City Bounds int offset = PlayerGovernmentSystem.L1CLOffset; Point2D center = new Point2D( p.X - m_Offset.X, p.Y - m_Offset.Y ); Point2D start = new Point2D( center.X - offset, center.Y - offset ); Point2D end = new Point2D( center.X + offset, center.Y + offset ); Rectangle2D box = new Rectangle2D( start, end ); ArrayList cityCoords = new ArrayList(); cityCoords.Add( box ); //Remove List ArrayList toDelete = new ArrayList(); // Add Mayor As Citizen ArrayList citizens = new ArrayList(); citizens.Add( from ); // Add Sponsor List ArrayList sponsor = new ArrayList(); // Add Ban List ArrayList ban = new ArrayList(); // Add Lockdown List ArrayList ld = new ArrayList(); // Add Waring List ArrayList war = new ArrayList(); // Add Wars Declare List ArrayList dwar = new ArrayList(); // Add Wars Invite List ArrayList iwar = new ArrayList(); // Add Allegiances List ArrayList allies = new ArrayList(); // Add Allegiances Declared List ArrayList dallies = new ArrayList(); // Add Allegiances Invited List ArrayList iallies = new ArrayList(); // Add Gardens And Parks ArrayList gardens = new ArrayList(); ArrayList parks = new ArrayList(); ArrayList vendor = new ArrayList(); ArrayList addon = new ArrayList(); // Add Management Stone CityManagementStone mStone = new CityManagementStone(); // Add City Region Rectangle3D[] area = PlayerGovernmentSystem.FormatRegion( box ); PlayerCityRegion reg = new PlayerCityRegion( mStone, from.Map, area ); reg.Register(); // Setup Stone mStone.RegionCoords = area; mStone.Coords = cityCoords; mStone.CityName = from.Name + "'s City"; mStone.Level = 1; mStone.Center = center; mStone.Mayor = from; mStone.PCRegion = reg; mStone.Citizens = citizens; mStone.Banned = ban; mStone.isLockedDown = ld; mStone.Sponsored = sponsor; mStone.Vendors = vendor; mStone.AddOns = addon; mStone.Waring = war; mStone.WarsDeclared = dwar; mStone.WarsInvited = iwar; mStone.Allegiances = allies; mStone.AllegiancesDeclared = dallies; mStone.AllegiancesInvited = iallies; mStone.Gardens = gardens; mStone.Parks = parks; // Setup Mayor PlayerMobile pm = (PlayerMobile)from; pm.City = mStone; pm.CityTitle = "Mayor"; pm.ShowCityTitle = true; PlasterCityHallAddon building = new PlasterCityHallAddon(); building.MoveToWorld( new Point3D( p.X - m_Offset.X, p.Y - m_Offset.Y, p.Z - m_Offset.Z ), from.Map ); BaseDoor d1 = new StrongWoodDoor( DoorFacing.WestCW ); BaseDoor d2 = new StrongWoodDoor( DoorFacing.EastCCW ); d1.Link = d2; d2.Link = d1; d1.MoveToWorld( new Point3D( p.X - 1, p.Y - 1, p.Z + 7 ), from.Map ); d2.MoveToWorld( new Point3D( p.X, p.Y - 1, p.Z + 7 ), from.Map ); // Add Voters List ArrayList voters = new ArrayList(); CityVotingStone vStone = new CityVotingStone(); vStone.Voters = voters; vStone.Stone = mStone; mStone.VoteStone = vStone; toDelete.Add( vStone ); vStone.MoveToWorld( new Point3D( p.X - 5, p.Y - 14, p.Z + 7 ), from.Map ); toDelete.Add( d1 ); toDelete.Add( d2 ); toDelete.Add( building ); mStone.toDelete = toDelete; mStone.MoveToWorld( new Point3D( p.X - 6, p.Y - 14, p.Z + 7 ), from.Map ); } else if ( Type == CivicStrutureType.WoodCityHall ) { // City Bounds int offset = PlayerGovernmentSystem.L1CLOffset; Point2D center = new Point2D( p.X - m_Offset.X, p.Y - m_Offset.Y ); Point2D start = new Point2D( center.X - offset, center.Y - offset ); Point2D end = new Point2D( center.X + offset, center.Y + offset ); Rectangle2D box = new Rectangle2D( start, end ); ArrayList cityCoords = new ArrayList(); cityCoords.Add( box ); //Remove List ArrayList toDelete = new ArrayList(); // Add Mayor As Citizen ArrayList citizens = new ArrayList(); citizens.Add( from ); // Add Sponsor List ArrayList sponsor = new ArrayList(); // Add Ban List ArrayList ban = new ArrayList(); // Add Lockdown List ArrayList ld = new ArrayList(); // Add Waring List ArrayList war = new ArrayList(); // Add Wars Declare List ArrayList dwar = new ArrayList(); // Add Wars Invite List ArrayList iwar = new ArrayList(); // Add Allegiances List ArrayList allies = new ArrayList(); // Add Allegiances Declared List ArrayList dallies = new ArrayList(); // Add Allegiances Invited List ArrayList iallies = new ArrayList(); // Add Gardens And Parks ArrayList gardens = new ArrayList(); ArrayList parks = new ArrayList(); ArrayList vendor = new ArrayList(); ArrayList addon = new ArrayList(); // Add Management Stone CityManagementStone mStone = new CityManagementStone(); // Add City Region Rectangle3D[] area = PlayerGovernmentSystem.FormatRegion( box ); PlayerCityRegion reg = new PlayerCityRegion( mStone, from.Map, area ); reg.Register(); // Setup Stone mStone.RegionCoords = area; mStone.Coords = cityCoords; mStone.CityName = from.Name + "'s City"; mStone.Level = 1; mStone.Center = center; mStone.Mayor = from; mStone.PCRegion = reg; mStone.Citizens = citizens; mStone.Banned = ban; mStone.isLockedDown = ld; mStone.Sponsored = sponsor; mStone.Vendors = vendor; mStone.AddOns = addon; mStone.Waring = war; mStone.WarsDeclared = dwar; mStone.WarsInvited = iwar; mStone.Allegiances = allies; mStone.AllegiancesDeclared = dallies; mStone.AllegiancesInvited = iallies; mStone.Gardens = gardens; mStone.Parks = parks; // Setup Mayor PlayerMobile pm = (PlayerMobile)from; pm.City = mStone; pm.CityTitle = "Mayor"; pm.ShowCityTitle = true; WoodCityHallAddon building = new WoodCityHallAddon(); building.MoveToWorld( new Point3D( p.X - m_Offset.X, p.Y - m_Offset.Y, p.Z - m_Offset.Z ), from.Map ); BaseDoor d1 = new StrongWoodDoor( DoorFacing.WestCW ); BaseDoor d2 = new StrongWoodDoor( DoorFacing.EastCCW ); d1.Link = d2; d2.Link = d1; d1.MoveToWorld( new Point3D( p.X, p.Y - 1, p.Z + 7 ), from.Map ); d2.MoveToWorld( new Point3D( p.X + 1, p.Y - 1, p.Z + 7 ), from.Map ); // Add Voters List ArrayList voters = new ArrayList(); CityVotingStone vStone = new CityVotingStone(); vStone.Voters = voters; vStone.Stone = mStone; mStone.VoteStone = vStone; toDelete.Add( vStone ); vStone.MoveToWorld( new Point3D( p.X - 5, p.Y - 14, p.Z + 7 ), from.Map ); toDelete.Add( d1 ); toDelete.Add( d2 ); toDelete.Add( building ); mStone.toDelete = toDelete; mStone.MoveToWorld( new Point3D( p.X - 6, p.Y - 14, p.Z + 7 ), from.Map ); } else if ( Type == CivicStrutureType.StoneCityHall ) { // City Bounds int offset = PlayerGovernmentSystem.L1CLOffset; Point2D center = new Point2D( p.X - m_Offset.X, p.Y - m_Offset.Y ); Point2D start = new Point2D( center.X - offset, center.Y - offset ); Point2D end = new Point2D( center.X + offset, center.Y + offset ); Rectangle2D box = new Rectangle2D( start, end ); ArrayList cityCoords = new ArrayList(); cityCoords.Add( box ); //Remove List ArrayList toDelete = new ArrayList(); // Add Mayor As Citizen ArrayList citizens = new ArrayList(); citizens.Add( from ); // Add Sponsor List ArrayList sponsor = new ArrayList(); // Add Ban List ArrayList ban = new ArrayList(); // Add Lockdown List ArrayList ld = new ArrayList(); // Add Waring List ArrayList war = new ArrayList(); // Add Wars Declare List ArrayList dwar = new ArrayList(); // Add Wars Invite List ArrayList iwar = new ArrayList(); // Add Allegiances List ArrayList allies = new ArrayList(); // Add Allegiances Declared List ArrayList dallies = new ArrayList(); // Add Allegiances Invited List ArrayList iallies = new ArrayList(); // Add Gardens And Parks ArrayList gardens = new ArrayList(); ArrayList parks = new ArrayList(); ArrayList vendor = new ArrayList(); ArrayList addon = new ArrayList(); // Add Management Stone CityManagementStone mStone = new CityManagementStone(); // Add City Region Rectangle3D[] area = PlayerGovernmentSystem.FormatRegion( box ); PlayerCityRegion reg = new PlayerCityRegion( mStone, from.Map, area ); reg.Register(); // Setup Stone mStone.RegionCoords = area; mStone.Coords = cityCoords; mStone.CityName = from.Name + "'s City"; mStone.Level = 1; mStone.Center = center; mStone.Mayor = from; mStone.PCRegion = reg; mStone.Citizens = citizens; mStone.Banned = ban; mStone.isLockedDown = ld; mStone.Sponsored = sponsor; mStone.Vendors = vendor; mStone.AddOns = addon; mStone.Waring = war; mStone.WarsDeclared = dwar; mStone.WarsInvited = iwar; mStone.Allegiances = allies; mStone.AllegiancesDeclared = dallies; mStone.AllegiancesInvited = iallies; mStone.Gardens = gardens; mStone.Parks = parks; // Setup Mayor PlayerMobile pm = (PlayerMobile)from; pm.City = mStone; pm.CityTitle = "Mayor"; pm.ShowCityTitle = true; StoneCityHallAddon building = new StoneCityHallAddon(); building.MoveToWorld( new Point3D( p.X - m_Offset.X, p.Y - m_Offset.Y, p.Z - m_Offset.Z ), from.Map ); BaseDoor d1 = new StrongWoodDoor( DoorFacing.WestCW ); BaseDoor d2 = new StrongWoodDoor( DoorFacing.EastCCW ); d1.Link = d2; d2.Link = d1; d1.MoveToWorld( new Point3D( p.X - 1, p.Y - 1, p.Z + 7 ), from.Map ); d2.MoveToWorld( new Point3D( p.X, p.Y - 1, p.Z + 7 ), from.Map ); // Add Voters List ArrayList voters = new ArrayList(); CityVotingStone vStone = new CityVotingStone(); vStone.Voters = voters; vStone.Stone = mStone; mStone.VoteStone = vStone; toDelete.Add( vStone ); vStone.MoveToWorld( new Point3D( p.X - 5, p.Y - 14, p.Z + 7 ), from.Map ); toDelete.Add( d1 ); toDelete.Add( d2 ); toDelete.Add( building ); mStone.toDelete = toDelete; mStone.MoveToWorld( new Point3D( p.X - 6, p.Y - 14, p.Z + 7 ), from.Map ); } else if ( Type == CivicStrutureType.AsianCityHall ) { // City Bounds int offset = PlayerGovernmentSystem.L1CLOffset; Point2D center = new Point2D( p.X - m_Offset.X, p.Y - m_Offset.Y ); Point2D start = new Point2D( center.X - offset, center.Y - offset ); Point2D end = new Point2D( center.X + offset, center.Y + offset ); Rectangle2D box = new Rectangle2D( start, end ); ArrayList cityCoords = new ArrayList(); cityCoords.Add( box ); //Remove List ArrayList toDelete = new ArrayList(); // Add Mayor As Citizen ArrayList citizens = new ArrayList(); citizens.Add( from ); // Add Sponsor List ArrayList sponsor = new ArrayList(); // Add Ban List ArrayList ban = new ArrayList(); // Add Lockdown List ArrayList ld = new ArrayList(); // Add Waring List ArrayList war = new ArrayList(); // Add Wars Declare List ArrayList dwar = new ArrayList(); // Add Wars Invite List ArrayList iwar = new ArrayList(); // Add Allegiances List ArrayList allies = new ArrayList(); // Add Allegiances Declared List ArrayList dallies = new ArrayList(); // Add Allegiances Invited List ArrayList iallies = new ArrayList(); // Add Gardens And Parks ArrayList gardens = new ArrayList(); ArrayList parks = new ArrayList(); ArrayList vendor = new ArrayList(); ArrayList addon = new ArrayList(); // Add Management Stone CityManagementStone mStone = new CityManagementStone(); // Add City Region Rectangle3D[] area = PlayerGovernmentSystem.FormatRegion( box ); PlayerCityRegion reg = new PlayerCityRegion( mStone, from.Map, area ); reg.Register(); // Setup Stone mStone.RegionCoords = area; mStone.Coords = cityCoords; mStone.CityName = from.Name + "'s City"; mStone.Level = 1; mStone.Center = center; mStone.Mayor = from; mStone.PCRegion = reg; mStone.Citizens = citizens; mStone.Banned = ban; mStone.isLockedDown = ld; mStone.Sponsored = sponsor; mStone.Vendors = vendor; mStone.AddOns = addon; mStone.Waring = war; mStone.WarsDeclared = dwar; mStone.WarsInvited = iwar; mStone.Allegiances = allies; mStone.AllegiancesDeclared = dallies; mStone.AllegiancesInvited = iallies; mStone.Gardens = gardens; mStone.Parks = parks; // Setup Mayor PlayerMobile pm = (PlayerMobile)from; pm.City = mStone; pm.CityTitle = "Mayor"; pm.ShowCityTitle = true; AsianCityHallAddon building = new AsianCityHallAddon(); building.MoveToWorld( new Point3D( p.X - m_Offset.X, p.Y - m_Offset.Y, p.Z - m_Offset.Z ), from.Map ); BaseDoor d1 = new StrongWoodDoor( DoorFacing.WestCW ); BaseDoor d2 = new StrongWoodDoor( DoorFacing.EastCCW ); d1.Link = d2; d2.Link = d1; d1.MoveToWorld( new Point3D( p.X - 2, p.Y - 1, p.Z + 7 ), from.Map ); d2.MoveToWorld( new Point3D( p.X - 1, p.Y - 1, p.Z + 7 ), from.Map ); // Add Voters List ArrayList voters = new ArrayList(); CityVotingStone vStone = new CityVotingStone(); vStone.Voters = voters; vStone.Stone = mStone; mStone.VoteStone = vStone; toDelete.Add( vStone ); vStone.MoveToWorld( new Point3D( p.X - 5, p.Y - 14, p.Z + 7 ), from.Map ); toDelete.Add( d1 ); toDelete.Add( d2 ); toDelete.Add( building ); mStone.toDelete = toDelete; mStone.MoveToWorld( new Point3D( p.X - 6, p.Y - 14, p.Z + 7 ), from.Map ); } else if ( Type == CivicStrutureType.WoodCityHealer ) { WoodCityHealerAddon building = new WoodCityHealerAddon(); building.MoveToWorld( new Point3D( p.X - m_Offset.X, p.Y - m_Offset.Y, p.Z - m_Offset.Z ), from.Map ); PlayerMobile pm = (PlayerMobile)from; //Remove List ArrayList toDelete = new ArrayList(); CivicSign sign = new CivicSign(); sign.Stone = pm.City; sign.toDelete = toDelete; pm.City.HasHealer = true; CityResurrectionStone ank = new CityResurrectionStone(); ank.Sign = sign; pm.City.ResStone = ank; //Initialize the Ghost Record Hashtable table = new Hashtable(); ank.Ghosts = table; BaseDoor d1 = new StrongWoodDoor( DoorFacing.WestCW ); BaseDoor d2 = new StrongWoodDoor( DoorFacing.EastCCW ); d1.Link = d2; d2.Link = d1; d1.MoveToWorld( new Point3D( p.X - 3, p.Y - 2, p.Z + 7 ), from.Map ); d2.MoveToWorld( new Point3D( p.X - 2, p.Y - 2, p.Z + 7 ), from.Map ); ank.MoveToWorld( new Point3D( p.X + 1, p.Y - 1, p.Z + 7 ), from.Map ); sign.toDelete.Add( d1 ); sign.toDelete.Add( d2 ); sign.toDelete.Add( ank ); sign.toDelete.Add( building ); sign.Type = CivicSignType.Healer; pm.City.toDelete.Add( sign ); sign.Name = "City Healer"; sign.MoveToWorld( new Point3D( p.X - 3, p.Y - 10, p.Z + 7 ), from.Map ); } else if ( Type == CivicStrutureType.PlasterCityHealer ) { PlasterCityHealerAddon building = new PlasterCityHealerAddon(); building.MoveToWorld( new Point3D( p.X - m_Offset.X, p.Y - m_Offset.Y, p.Z - m_Offset.Z ), from.Map ); PlayerMobile pm = (PlayerMobile)from; //Remove List ArrayList toDelete = new ArrayList(); CivicSign sign = new CivicSign(); sign.Stone = pm.City; sign.toDelete = toDelete; pm.City.HasHealer = true; CityResurrectionStone ank = new CityResurrectionStone(); ank.Sign = sign; pm.City.ResStone = ank; //Initialize the Ghost Record Hashtable table = new Hashtable(); ank.Ghosts = table; BaseDoor d1 = new StrongWoodDoor( DoorFacing.WestCW ); BaseDoor d2 = new StrongWoodDoor( DoorFacing.EastCCW ); d1.Link = d2; d2.Link = d1; d1.MoveToWorld( new Point3D( p.X - 3, p.Y - 2, p.Z + 7 ), from.Map ); d2.MoveToWorld( new Point3D( p.X - 2, p.Y - 2, p.Z + 7 ), from.Map ); ank.MoveToWorld( new Point3D( p.X + 1, p.Y - 1, p.Z + 7 ), from.Map ); sign.toDelete.Add( d1 ); sign.toDelete.Add( d2 ); sign.toDelete.Add( ank ); sign.toDelete.Add( building ); sign.Type = CivicSignType.Healer; pm.City.toDelete.Add( sign ); sign.Name = "City Healer"; sign.MoveToWorld( new Point3D( p.X - 3, p.Y - 10, p.Z + 7 ), from.Map ); } else if ( Type == CivicStrutureType.StoneCityHealer ) { StoneCityHealerAddon building = new StoneCityHealerAddon(); building.MoveToWorld( new Point3D( p.X - m_Offset.X, p.Y - m_Offset.Y, p.Z - m_Offset.Z ), from.Map ); PlayerMobile pm = (PlayerMobile)from; //Remove List ArrayList toDelete = new ArrayList(); CivicSign sign = new CivicSign(); sign.Stone = pm.City; sign.toDelete = toDelete; pm.City.HasHealer = true; CityResurrectionStone ank = new CityResurrectionStone(); ank.Sign = sign; pm.City.ResStone = ank; //Initialize the Ghost Record Hashtable table = new Hashtable(); ank.Ghosts = table; BaseDoor d1 = new StrongWoodDoor( DoorFacing.WestCW ); BaseDoor d2 = new StrongWoodDoor( DoorFacing.EastCCW ); d1.Link = d2; d2.Link = d1; d1.MoveToWorld( new Point3D( p.X - 2, p.Y - 2, p.Z + 7 ), from.Map ); d2.MoveToWorld( new Point3D( p.X - 1, p.Y - 2, p.Z + 7 ), from.Map ); ank.MoveToWorld( new Point3D( p.X + 1, p.Y - 1, p.Z + 7 ), from.Map ); sign.toDelete.Add( d1 ); sign.toDelete.Add( d2 ); sign.toDelete.Add( ank ); sign.toDelete.Add( building ); sign.Type = CivicSignType.Healer; sign.Name = "City Healer"; pm.City.toDelete.Add( sign ); sign.MoveToWorld( new Point3D( p.X - 3, p.Y - 10, p.Z + 7 ), from.Map ); } else if ( Type == CivicStrutureType.FieldStoneCityHealer ) { FieldstoneCityHealerAddon building = new FieldstoneCityHealerAddon(); building.MoveToWorld( new Point3D( p.X - m_Offset.X, p.Y - m_Offset.Y, p.Z - m_Offset.Z ), from.Map ); PlayerMobile pm = (PlayerMobile)from; //Remove List ArrayList toDelete = new ArrayList(); CivicSign sign = new CivicSign(); sign.Stone = pm.City; sign.toDelete = toDelete; pm.City.HasHealer = true; CityResurrectionStone ank = new CityResurrectionStone(); ank.Sign = sign; pm.City.ResStone = ank; //Initialize the Ghost Record Hashtable table = new Hashtable(); ank.Ghosts = table; BaseDoor d1 = new StrongWoodDoor( DoorFacing.WestCW ); BaseDoor d2 = new StrongWoodDoor( DoorFacing.EastCCW ); d1.Link = d2; d2.Link = d1; d1.MoveToWorld( new Point3D( p.X - 3, p.Y - 2, p.Z + 7 ), from.Map ); d2.MoveToWorld( new Point3D( p.X - 2, p.Y - 2, p.Z + 7 ), from.Map ); ank.MoveToWorld( new Point3D( p.X + 1, p.Y - 1, p.Z + 7 ), from.Map ); sign.toDelete.Add( d1 ); sign.toDelete.Add( d2 ); sign.toDelete.Add( ank ); sign.toDelete.Add( building ); sign.Type = CivicSignType.Healer; pm.City.toDelete.Add( sign ); sign.Name = "City Healer"; sign.MoveToWorld( new Point3D( p.X - 3, p.Y - 10, p.Z + 7 ), from.Map ); } else if ( Type == CivicStrutureType.SandstoneCityHealer ) { SandstoneCityHealerAddon building = new SandstoneCityHealerAddon(); building.MoveToWorld( new Point3D( p.X - m_Offset.X, p.Y - m_Offset.Y, p.Z - m_Offset.Z ), from.Map ); PlayerMobile pm = (PlayerMobile)from; //Remove List ArrayList toDelete = new ArrayList(); CivicSign sign = new CivicSign(); sign.Stone = pm.City; sign.toDelete = toDelete; pm.City.HasHealer = true; CityResurrectionStone ank = new CityResurrectionStone(); ank.Sign = sign; pm.City.ResStone = ank; //Initialize the Ghost Record Hashtable table = new Hashtable(); ank.Ghosts = table; BaseDoor d1 = new StrongWoodDoor( DoorFacing.WestCW ); BaseDoor d2 = new StrongWoodDoor( DoorFacing.EastCCW ); d1.Link = d2; d2.Link = d1; d1.MoveToWorld( new Point3D( p.X - 2, p.Y - 2, p.Z + 7 ), from.Map ); d2.MoveToWorld( new Point3D( p.X - 1, p.Y - 2, p.Z + 7 ), from.Map ); ank.MoveToWorld( new Point3D( p.X + 1, p.Y - 1, p.Z + 7 ), from.Map ); sign.toDelete.Add( d1 ); sign.toDelete.Add( d2 ); sign.toDelete.Add( ank ); sign.toDelete.Add( building ); sign.Type = CivicSignType.Healer; pm.City.toDelete.Add( sign ); sign.Name = "City Healer"; sign.MoveToWorld( new Point3D( p.X - 2, p.Y - 10, p.Z + 7 ), from.Map ); } else if ( Type == CivicStrutureType.MarbleCityHealer ) { MarbleCityHealerAddon building = new MarbleCityHealerAddon(); building.MoveToWorld( new Point3D( p.X - m_Offset.X, p.Y - m_Offset.Y, p.Z - m_Offset.Z ), from.Map ); PlayerMobile pm = (PlayerMobile)from; //Remove List ArrayList toDelete = new ArrayList(); CivicSign sign = new CivicSign(); sign.Stone = pm.City; sign.toDelete = toDelete; pm.City.HasHealer = true; CityResurrectionStone ank = new CityResurrectionStone(); ank.Sign = sign; pm.City.ResStone = ank; //Initialize the Ghost Record Hashtable table = new Hashtable(); ank.Ghosts = table; BaseDoor d1 = new StrongWoodDoor( DoorFacing.WestCW ); BaseDoor d2 = new StrongWoodDoor( DoorFacing.EastCCW ); d1.Link = d2; d2.Link = d1; d1.MoveToWorld( new Point3D( p.X - 2, p.Y - 2, p.Z + 7 ), from.Map ); d2.MoveToWorld( new Point3D( p.X - 1, p.Y - 2, p.Z + 7 ), from.Map ); ank.MoveToWorld( new Point3D( p.X + 1, p.Y - 1, p.Z + 7 ), from.Map ); sign.toDelete.Add( d1 ); sign.toDelete.Add( d2 ); sign.toDelete.Add( ank ); sign.toDelete.Add( building ); sign.Type = CivicSignType.Healer; pm.City.toDelete.Add( sign ); sign.Name = "City Healer"; sign.MoveToWorld( new Point3D( p.X - 2, p.Y - 10, p.Z + 7 ), from.Map ); } else if ( Type == CivicStrutureType.NecroCityHealer ) { NecroCityHealerAddon building = new NecroCityHealerAddon(); building.MoveToWorld( new Point3D( p.X - m_Offset.X, p.Y - m_Offset.Y, p.Z - m_Offset.Z ), from.Map ); PlayerMobile pm = (PlayerMobile)from; //Remove List ArrayList toDelete = new ArrayList(); CivicSign sign = new CivicSign(); sign.Stone = pm.City; sign.toDelete = toDelete; pm.City.HasHealer = true; CityResurrectionStone ank = new CityResurrectionStone(); ank.Sign = sign; pm.City.ResStone = ank; //Initialize the Ghost Record Hashtable table = new Hashtable(); ank.Ghosts = table; BaseDoor d1 = new StrongWoodDoor( DoorFacing.WestCW ); BaseDoor d2 = new StrongWoodDoor( DoorFacing.EastCCW ); d1.Link = d2; d2.Link = d1; d1.MoveToWorld( new Point3D( p.X - 2, p.Y - 2, p.Z + 7 ), from.Map ); d2.MoveToWorld( new Point3D( p.X - 1, p.Y - 2, p.Z + 7 ), from.Map ); ank.MoveToWorld( new Point3D( p.X + 2, p.Y - 1, p.Z + 7 ), from.Map ); sign.toDelete.Add( d1 ); sign.toDelete.Add( d2 ); sign.toDelete.Add( ank ); sign.toDelete.Add( building ); sign.Type = CivicSignType.Healer; pm.City.toDelete.Add( sign ); sign.Name = "City Healer"; sign.MoveToWorld( new Point3D( p.X - 3, p.Y - 10, p.Z + 7 ), from.Map ); } else if ( Type == CivicStrutureType.AsianCityHealer ) { AsianCityHealerAddon building = new AsianCityHealerAddon(); building.MoveToWorld( new Point3D( p.X - m_Offset.X, p.Y - m_Offset.Y, p.Z - m_Offset.Z ), from.Map ); PlayerMobile pm = (PlayerMobile)from; //Remove List ArrayList toDelete = new ArrayList(); CivicSign sign = new CivicSign(); sign.Stone = pm.City; sign.toDelete = toDelete; pm.City.HasHealer = true; CityResurrectionStone ank = new CityResurrectionStone(); ank.Sign = sign; pm.City.ResStone = ank; //Initialize the Ghost Record Hashtable table = new Hashtable(); ank.Ghosts = table; BaseDoor d1 = new StrongWoodDoor( DoorFacing.WestCW ); BaseDoor d2 = new StrongWoodDoor( DoorFacing.EastCCW ); d1.Link = d2; d2.Link = d1; d1.MoveToWorld( new Point3D( p.X - 3, p.Y - 2, p.Z + 7 ), from.Map ); d2.MoveToWorld( new Point3D( p.X - 2, p.Y - 2, p.Z + 7 ), from.Map ); ank.MoveToWorld( new Point3D( p.X + 1, p.Y - 1, p.Z + 7 ), from.Map ); sign.toDelete.Add( d1 ); sign.toDelete.Add( d2 ); sign.toDelete.Add( ank ); sign.toDelete.Add( building ); sign.Type = CivicSignType.Healer; pm.City.toDelete.Add( sign ); sign.Name = "City Healer"; sign.MoveToWorld( new Point3D( p.X - 3, p.Y - 10, p.Z + 7 ), from.Map ); } else if ( Type == CivicStrutureType.WoodCityBank ) { WoodCityBankAddon building = new WoodCityBankAddon(); building.MoveToWorld( new Point3D( p.X - m_Offset.X, p.Y - m_Offset.Y, p.Z - m_Offset.Z ), from.Map ); PlayerMobile pm = (PlayerMobile)from; //Remove List ArrayList toDelete = new ArrayList(); CivicSign sign = new CivicSign(); sign.Stone = pm.City; sign.toDelete = toDelete; pm.City.HasBank = true; CityBankStone bStone = new CityBankStone(); BaseDoor d1 = new StrongWoodDoor( DoorFacing.WestCW ); BaseDoor d2 = new StrongWoodDoor( DoorFacing.EastCCW ); d1.Link = d2; d2.Link = d1; d1.MoveToWorld( new Point3D( p.X - 1, p.Y - 2, p.Z + 7 ), from.Map ); d2.MoveToWorld( new Point3D( p.X, p.Y - 2, p.Z + 7 ), from.Map ); bStone.MoveToWorld( new Point3D( p.X, p.Y - 8, p.Z + 7 ), from.Map ); sign.toDelete.Add( d1 ); sign.toDelete.Add( d2 ); sign.toDelete.Add( bStone ); sign.toDelete.Add( building ); sign.Type = CivicSignType.Bank; pm.City.toDelete.Add( sign ); sign.ItemID = 3026; sign.Name = "City Bank"; sign.MoveToWorld( new Point3D( p.X - 4, p.Y - 1, p.Z + 7 ), from.Map ); } else if ( Type == CivicStrutureType.StoneCityBank ) { StoneCityBankAddon building = new StoneCityBankAddon(); building.MoveToWorld( new Point3D( p.X - m_Offset.X, p.Y - m_Offset.Y, p.Z - m_Offset.Z ), from.Map ); PlayerMobile pm = (PlayerMobile)from; //Remove List ArrayList toDelete = new ArrayList(); CivicSign sign = new CivicSign(); sign.Stone = pm.City; sign.toDelete = toDelete; pm.City.HasBank = true; CityBankStone bStone = new CityBankStone(); BaseDoor d1 = new StrongWoodDoor( DoorFacing.WestCW ); BaseDoor d2 = new StrongWoodDoor( DoorFacing.EastCCW ); d1.Link = d2; d2.Link = d1; d1.MoveToWorld( new Point3D( p.X, p.Y - 2, p.Z + 7 ), from.Map ); d2.MoveToWorld( new Point3D( p.X + 1, p.Y - 2, p.Z + 7 ), from.Map ); bStone.MoveToWorld( new Point3D( p.X + 1, p.Y - 8, p.Z + 7 ), from.Map ); sign.toDelete.Add( d1 ); sign.toDelete.Add( d2 ); sign.toDelete.Add( bStone ); sign.toDelete.Add( building ); sign.Type = CivicSignType.Bank; pm.City.toDelete.Add( sign ); sign.ItemID = 3026; sign.Name = "City Bank"; sign.MoveToWorld( new Point3D( p.X - 3, p.Y - 1, p.Z + 7 ), from.Map ); } else if ( Type == CivicStrutureType.PlasterCityBank ) { PlasterCityBankAddon building = new PlasterCityBankAddon(); building.MoveToWorld( new Point3D( p.X - m_Offset.X, p.Y - m_Offset.Y, p.Z - m_Offset.Z ), from.Map ); PlayerMobile pm = (PlayerMobile)from; //Remove List ArrayList toDelete = new ArrayList(); CivicSign sign = new CivicSign(); sign.Stone = pm.City; sign.toDelete = toDelete; pm.City.HasBank = true; CityBankStone bStone = new CityBankStone(); BaseDoor d1 = new StrongWoodDoor( DoorFacing.WestCW ); BaseDoor d2 = new StrongWoodDoor( DoorFacing.EastCCW ); d1.Link = d2; d2.Link = d1; d1.MoveToWorld( new Point3D( p.X - 1, p.Y - 2, p.Z + 7 ), from.Map ); d2.MoveToWorld( new Point3D( p.X, p.Y - 2, p.Z + 7 ), from.Map ); bStone.MoveToWorld( new Point3D( p.X, p.Y - 8, p.Z + 7 ), from.Map ); sign.toDelete.Add( d1 ); sign.toDelete.Add( d2 ); sign.toDelete.Add( bStone ); sign.toDelete.Add( building ); sign.Type = CivicSignType.Bank; pm.City.toDelete.Add( sign ); sign.ItemID = 3026; sign.Name = "City Bank"; sign.MoveToWorld( new Point3D( p.X - 4, p.Y - 1, p.Z + 7 ), from.Map ); } else if ( Type == CivicStrutureType.FieldStoneCityBank ) { FieldstoneCityBankAddon building = new FieldstoneCityBankAddon(); building.MoveToWorld( new Point3D( p.X - m_Offset.X, p.Y - m_Offset.Y, p.Z - m_Offset.Z ), from.Map ); PlayerMobile pm = (PlayerMobile)from; //Remove List ArrayList toDelete = new ArrayList(); CivicSign sign = new CivicSign(); sign.Stone = pm.City; sign.toDelete = toDelete; pm.City.HasBank = true; CityBankStone bStone = new CityBankStone(); BaseDoor d1 = new StrongWoodDoor( DoorFacing.WestCW ); BaseDoor d2 = new StrongWoodDoor( DoorFacing.EastCCW ); d1.Link = d2; d2.Link = d1; d1.MoveToWorld( new Point3D( p.X - 1, p.Y - 2, p.Z + 7 ), from.Map ); d2.MoveToWorld( new Point3D( p.X, p.Y - 2, p.Z + 7 ), from.Map ); bStone.MoveToWorld( new Point3D( p.X, p.Y - 8, p.Z + 7 ), from.Map ); sign.toDelete.Add( d1 ); sign.toDelete.Add( d2 ); sign.toDelete.Add( bStone ); sign.toDelete.Add( building ); sign.Type = CivicSignType.Bank; pm.City.toDelete.Add( sign ); sign.ItemID = 3026; sign.Name = "City Bank"; sign.MoveToWorld( new Point3D( p.X - 4, p.Y - 1, p.Z + 7 ), from.Map ); } else if ( Type == CivicStrutureType.SandstoneCityBank ) { SandstoneCityBankAddon building = new SandstoneCityBankAddon(); building.MoveToWorld( new Point3D( p.X - m_Offset.X, p.Y - m_Offset.Y, p.Z - m_Offset.Z ), from.Map ); PlayerMobile pm = (PlayerMobile)from; //Remove List ArrayList toDelete = new ArrayList(); CivicSign sign = new CivicSign(); sign.Stone = pm.City; sign.toDelete = toDelete; pm.City.HasBank = true; CityBankStone bStone = new CityBankStone(); BaseDoor d1 = new StrongWoodDoor( DoorFacing.WestCW ); BaseDoor d2 = new StrongWoodDoor( DoorFacing.EastCCW ); d1.Link = d2; d2.Link = d1; d1.MoveToWorld( new Point3D( p.X, p.Y - 2, p.Z + 7 ), from.Map ); d2.MoveToWorld( new Point3D( p.X + 1, p.Y - 2, p.Z + 7 ), from.Map ); bStone.MoveToWorld( new Point3D( p.X + 1, p.Y - 8, p.Z + 7 ), from.Map ); sign.toDelete.Add( d1 ); sign.toDelete.Add( d2 ); sign.toDelete.Add( bStone ); sign.toDelete.Add( building ); sign.Type = CivicSignType.Bank; pm.City.toDelete.Add( sign ); sign.ItemID = 3026; sign.Name = "City Bank"; sign.MoveToWorld( new Point3D( p.X - 3, p.Y - 1, p.Z + 7 ), from.Map ); } else if ( Type == CivicStrutureType.MarbleCityBank ) { MarbleCityBankAddon building = new MarbleCityBankAddon(); building.MoveToWorld( new Point3D( p.X - m_Offset.X, p.Y - m_Offset.Y, p.Z - m_Offset.Z ), from.Map ); PlayerMobile pm = (PlayerMobile)from; //Remove List ArrayList toDelete = new ArrayList(); CivicSign sign = new CivicSign(); sign.Stone = pm.City; sign.toDelete = toDelete; pm.City.HasBank = true; CityBankStone bStone = new CityBankStone(); BaseDoor d1 = new StrongWoodDoor( DoorFacing.WestCW ); BaseDoor d2 = new StrongWoodDoor( DoorFacing.EastCCW ); d1.Link = d2; d2.Link = d1; d1.MoveToWorld( new Point3D( p.X - 1, p.Y - 2, p.Z + 7 ), from.Map ); d2.MoveToWorld( new Point3D( p.X, p.Y - 2, p.Z + 7 ), from.Map ); bStone.MoveToWorld( new Point3D( p.X, p.Y - 8, p.Z + 7 ), from.Map ); sign.toDelete.Add( d1 ); sign.toDelete.Add( d2 ); sign.toDelete.Add( bStone ); sign.toDelete.Add( building ); sign.Type = CivicSignType.Bank; pm.City.toDelete.Add( sign ); sign.ItemID = 3026; sign.Name = "City Bank"; sign.MoveToWorld( new Point3D( p.X - 3, p.Y - 1, p.Z + 7 ), from.Map ); } else if ( Type == CivicStrutureType.NecroCityBank ) { NecroCityBankAddon building = new NecroCityBankAddon(); building.MoveToWorld( new Point3D( p.X - m_Offset.X, p.Y - m_Offset.Y, p.Z - m_Offset.Z ), from.Map ); PlayerMobile pm = (PlayerMobile)from; //Remove List ArrayList toDelete = new ArrayList(); CivicSign sign = new CivicSign(); sign.Stone = pm.City; sign.toDelete = toDelete; pm.City.HasBank = true; CityBankStone bStone = new CityBankStone(); bStone.MoveToWorld( new Point3D( p.X + 1, p.Y - 8, p.Z + 7 ), from.Map ); sign.toDelete.Add( bStone ); sign.toDelete.Add( building ); sign.Type = CivicSignType.Bank; pm.City.toDelete.Add( sign ); sign.ItemID = 3026; sign.Name = "City Bank"; sign.MoveToWorld( new Point3D( p.X - 3, p.Y - 1, p.Z + 7 ), from.Map ); } else if ( Type == CivicStrutureType.AsianCityBank ) { AsianCityBankAddon building = new AsianCityBankAddon(); building.MoveToWorld( new Point3D( p.X - m_Offset.X, p.Y - m_Offset.Y, p.Z - m_Offset.Z ), from.Map ); PlayerMobile pm = (PlayerMobile)from; //Remove List ArrayList toDelete = new ArrayList(); CivicSign sign = new CivicSign(); sign.Stone = pm.City; sign.toDelete = toDelete; pm.City.HasBank = true; CityBankStone bStone = new CityBankStone(); BaseDoor d1 = new StrongWoodDoor( DoorFacing.WestCW ); BaseDoor d2 = new StrongWoodDoor( DoorFacing.EastCCW ); d1.Link = d2; d2.Link = d1; d1.MoveToWorld( new Point3D( p.X - 1, p.Y - 2, p.Z + 7 ), from.Map ); d2.MoveToWorld( new Point3D( p.X, p.Y - 2, p.Z + 7 ), from.Map ); bStone.MoveToWorld( new Point3D( p.X, p.Y - 8, p.Z + 7 ), from.Map ); sign.toDelete.Add( d1 ); sign.toDelete.Add( d2 ); sign.toDelete.Add( bStone ); sign.toDelete.Add( building ); sign.Type = CivicSignType.Bank; pm.City.toDelete.Add( sign ); sign.ItemID = 3026; sign.Name = "City Bank"; sign.MoveToWorld( new Point3D( p.X - 4, p.Y - 1, p.Z + 7 ), from.Map ); } else if ( Type == CivicStrutureType.WoodCityStable ) { WoodCityStableAddon building = new WoodCityStableAddon(); building.MoveToWorld( new Point3D( p.X - m_Offset.X, p.Y - m_Offset.Y, p.Z - m_Offset.Z ), from.Map ); PlayerMobile pm = (PlayerMobile)from; //Remove List ArrayList toDelete = new ArrayList(); CivicSign sign = new CivicSign(); sign.Stone = pm.City; sign.toDelete = toDelete; pm.City.HasStable = true; CityStableStone sStone = new CityStableStone(); sStone.MoveToWorld( new Point3D( p.X, p.Y - 5, p.Z + 7 ), from.Map ); sStone.Sign = sign; sign.toDelete.Add( sStone ); BaseDoor d1 = new StrongWoodDoor( DoorFacing.WestCW ); BaseDoor d2 = new StrongWoodDoor( DoorFacing.EastCCW ); d1.Link = d2; d2.Link = d1; d1.MoveToWorld( new Point3D( p.X + 2, p.Y - 2, p.Z + 7 ), from.Map ); d2.MoveToWorld( new Point3D( p.X + 3, p.Y - 2, p.Z + 7 ), from.Map ); sign.toDelete.Add( d1 ); sign.toDelete.Add( d2 ); sign.toDelete.Add( building ); sign.Type = CivicSignType.Stable; pm.City.toDelete.Add( sign ); sign.ItemID = 3026; sign.Name = "City Stables"; sign.MoveToWorld( new Point3D( p.X - 5, p.Y - 1, p.Z + 7 ), from.Map ); } else if ( Type == CivicStrutureType.StoneCityStable ) { StoneCityStableAddon building = new StoneCityStableAddon(); building.MoveToWorld( new Point3D( p.X - m_Offset.X, p.Y - m_Offset.Y, p.Z - m_Offset.Z ), from.Map ); PlayerMobile pm = (PlayerMobile)from; //Remove List ArrayList toDelete = new ArrayList(); CivicSign sign = new CivicSign(); sign.Stone = pm.City; sign.toDelete = toDelete; pm.City.HasStable = true; CityStableStone sStone = new CityStableStone(); sStone.MoveToWorld( new Point3D( p.X, p.Y - 5, p.Z + 7 ), from.Map ); sStone.Sign = sign; sign.toDelete.Add( sStone ); BaseDoor d1 = new StrongWoodDoor( DoorFacing.WestCW ); BaseDoor d2 = new StrongWoodDoor( DoorFacing.EastCCW ); d1.Link = d2; d2.Link = d1; d1.MoveToWorld( new Point3D( p.X + 2, p.Y - 2, p.Z + 7 ), from.Map ); d2.MoveToWorld( new Point3D( p.X + 3, p.Y - 2, p.Z + 7 ), from.Map ); sign.toDelete.Add( d1 ); sign.toDelete.Add( d2 ); sign.toDelete.Add( building ); sign.Type = CivicSignType.Stable; pm.City.toDelete.Add( sign ); sign.ItemID = 3026; sign.Name = "City Stables"; sign.MoveToWorld( new Point3D( p.X - 5, p.Y - 1, p.Z + 7 ), from.Map ); } else if ( Type == CivicStrutureType.FieldStoneCityStable ) { FieldstoneCityStableAddon building = new FieldstoneCityStableAddon(); building.MoveToWorld( new Point3D( p.X - m_Offset.X, p.Y - m_Offset.Y, p.Z - m_Offset.Z ), from.Map ); PlayerMobile pm = (PlayerMobile)from; //Remove List ArrayList toDelete = new ArrayList(); CivicSign sign = new CivicSign(); sign.Stone = pm.City; sign.toDelete = toDelete; pm.City.HasStable = true; CityStableStone sStone = new CityStableStone(); sStone.MoveToWorld( new Point3D( p.X, p.Y - 5, p.Z + 7 ), from.Map ); sStone.Sign = sign; sign.toDelete.Add( sStone ); BaseDoor d1 = new StrongWoodDoor( DoorFacing.WestCW ); BaseDoor d2 = new StrongWoodDoor( DoorFacing.EastCCW ); d1.Link = d2; d2.Link = d1; d1.MoveToWorld( new Point3D( p.X + 2, p.Y - 2, p.Z + 7 ), from.Map ); d2.MoveToWorld( new Point3D( p.X + 3, p.Y - 2, p.Z + 7 ), from.Map ); sign.toDelete.Add( d1 ); sign.toDelete.Add( d2 ); sign.toDelete.Add( building ); sign.Type = CivicSignType.Stable; pm.City.toDelete.Add( sign ); sign.ItemID = 3026; sign.Name = "City Stables"; sign.MoveToWorld( new Point3D( p.X - 5, p.Y - 1, p.Z + 7 ), from.Map ); } else if ( Type == CivicStrutureType.PlasterCityStable ) { PlasterCityStableAddon building = new PlasterCityStableAddon(); building.MoveToWorld( new Point3D( p.X - m_Offset.X, p.Y - m_Offset.Y, p.Z - m_Offset.Z ), from.Map ); PlayerMobile pm = (PlayerMobile)from; //Remove List ArrayList toDelete = new ArrayList(); CivicSign sign = new CivicSign(); sign.Stone = pm.City; sign.toDelete = toDelete; pm.City.HasStable = true; CityStableStone sStone = new CityStableStone(); sStone.MoveToWorld( new Point3D( p.X, p.Y - 5, p.Z + 7 ), from.Map ); sStone.Sign = sign; sign.toDelete.Add( sStone ); BaseDoor d1 = new StrongWoodDoor( DoorFacing.WestCW ); BaseDoor d2 = new StrongWoodDoor( DoorFacing.EastCCW ); d1.Link = d2; d2.Link = d1; d1.MoveToWorld( new Point3D( p.X + 2, p.Y - 2, p.Z + 7 ), from.Map ); d2.MoveToWorld( new Point3D( p.X + 3, p.Y - 2, p.Z + 7 ), from.Map ); sign.toDelete.Add( d1 ); sign.toDelete.Add( d2 ); sign.toDelete.Add( building ); sign.Type = CivicSignType.Stable; pm.City.toDelete.Add( sign ); sign.ItemID = 3026; sign.Name = "City Stables"; sign.MoveToWorld( new Point3D( p.X - 5, p.Y - 1, p.Z + 7 ), from.Map ); } else if ( Type == CivicStrutureType.SandstoneCityStable ) { SandstoneCityStableAddon building = new SandstoneCityStableAddon(); building.MoveToWorld( new Point3D( p.X - m_Offset.X, p.Y - m_Offset.Y, p.Z - m_Offset.Z ), from.Map ); PlayerMobile pm = (PlayerMobile)from; //Remove List ArrayList toDelete = new ArrayList(); CivicSign sign = new CivicSign(); sign.Stone = pm.City; sign.toDelete = toDelete; pm.City.HasStable = true; CityStableStone sStone = new CityStableStone(); sStone.MoveToWorld( new Point3D( p.X, p.Y - 5, p.Z + 7 ), from.Map ); sStone.Sign = sign; sign.toDelete.Add( sStone ); BaseDoor d1 = new StrongWoodDoor( DoorFacing.WestCW ); BaseDoor d2 = new StrongWoodDoor( DoorFacing.EastCCW ); d1.Link = d2; d2.Link = d1; d1.MoveToWorld( new Point3D( p.X + 3, p.Y - 2, p.Z + 7 ), from.Map ); d2.MoveToWorld( new Point3D( p.X + 4, p.Y - 2, p.Z + 7 ), from.Map ); sign.toDelete.Add( d1 ); sign.toDelete.Add( d2 ); sign.toDelete.Add( building ); sign.Type = CivicSignType.Stable; pm.City.toDelete.Add( sign ); sign.ItemID = 3026; sign.Name = "City Stables"; sign.MoveToWorld( new Point3D( p.X - 4, p.Y - 1, p.Z + 7 ), from.Map ); } else if ( Type == CivicStrutureType.MarbleCityStable ) { MarbleCityStableAddon building = new MarbleCityStableAddon(); building.MoveToWorld( new Point3D( p.X - m_Offset.X, p.Y - m_Offset.Y, p.Z - m_Offset.Z ), from.Map ); PlayerMobile pm = (PlayerMobile)from; //Remove List ArrayList toDelete = new ArrayList(); CivicSign sign = new CivicSign(); sign.Stone = pm.City; sign.toDelete = toDelete; pm.City.HasStable = true; CityStableStone sStone = new CityStableStone(); sStone.MoveToWorld( new Point3D( p.X, p.Y - 5, p.Z + 7 ), from.Map ); sStone.Sign = sign; sign.toDelete.Add( sStone ); BaseDoor d1 = new StrongWoodDoor( DoorFacing.WestCW ); BaseDoor d2 = new StrongWoodDoor( DoorFacing.EastCCW ); d1.Link = d2; d2.Link = d1; d1.MoveToWorld( new Point3D( p.X + 3, p.Y - 2, p.Z + 7 ), from.Map ); d2.MoveToWorld( new Point3D( p.X + 4, p.Y - 2, p.Z + 7 ), from.Map ); sign.toDelete.Add( d1 ); sign.toDelete.Add( d2 ); sign.toDelete.Add( building ); sign.Type = CivicSignType.Stable; pm.City.toDelete.Add( sign ); sign.ItemID = 3026; sign.Name = "City Stables"; sign.MoveToWorld( new Point3D( p.X - 4, p.Y - 1, p.Z + 7 ), from.Map ); } else if ( Type == CivicStrutureType.NecroCityStable ) { NecroCityStableAddon building = new NecroCityStableAddon(); building.MoveToWorld( new Point3D( p.X - m_Offset.X, p.Y - m_Offset.Y, p.Z - m_Offset.Z ), from.Map ); PlayerMobile pm = (PlayerMobile)from; //Remove List ArrayList toDelete = new ArrayList(); CivicSign sign = new CivicSign(); sign.Stone = pm.City; sign.toDelete = toDelete; pm.City.HasStable = true; CityStableStone sStone = new CityStableStone(); sStone.MoveToWorld( new Point3D( p.X, p.Y - 5, p.Z + 7 ), from.Map ); sStone.Sign = sign; sign.toDelete.Add( sStone ); BaseDoor d1 = new StrongWoodDoor( DoorFacing.WestCW ); BaseDoor d2 = new StrongWoodDoor( DoorFacing.EastCCW ); d1.Link = d2; d2.Link = d1; d1.MoveToWorld( new Point3D( p.X + 3, p.Y - 2, p.Z + 7 ), from.Map ); d2.MoveToWorld( new Point3D( p.X + 4, p.Y - 2, p.Z + 7 ), from.Map ); sign.toDelete.Add( d1 ); sign.toDelete.Add( d2 ); sign.toDelete.Add( building ); sign.Type = CivicSignType.Stable; pm.City.toDelete.Add( sign ); sign.ItemID = 3026; sign.Name = "City Stables"; sign.MoveToWorld( new Point3D( p.X - 4, p.Y - 1, p.Z + 7 ), from.Map ); } else if ( Type == CivicStrutureType.AsianCityStable ) { AsianCityStableAddon building = new AsianCityStableAddon(); building.MoveToWorld( new Point3D( p.X - m_Offset.X, p.Y - m_Offset.Y, p.Z - m_Offset.Z ), from.Map ); PlayerMobile pm = (PlayerMobile)from; //Remove List ArrayList toDelete = new ArrayList(); CivicSign sign = new CivicSign(); sign.Stone = pm.City; sign.toDelete = toDelete; pm.City.HasStable = true; CityStableStone sStone = new CityStableStone(); sStone.MoveToWorld( new Point3D( p.X, p.Y - 5, p.Z + 7 ), from.Map ); sStone.Sign = sign; sign.toDelete.Add( sStone ); BaseDoor d1 = new StrongWoodDoor( DoorFacing.WestCW ); BaseDoor d2 = new StrongWoodDoor( DoorFacing.EastCCW ); d1.Link = d2; d2.Link = d1; d1.MoveToWorld( new Point3D( p.X + 2, p.Y - 2, p.Z + 7 ), from.Map ); d2.MoveToWorld( new Point3D( p.X + 3, p.Y - 2, p.Z + 7 ), from.Map ); sign.toDelete.Add( d1 ); sign.toDelete.Add( d2 ); sign.toDelete.Add( building ); sign.Type = CivicSignType.Stable; pm.City.toDelete.Add( sign ); sign.ItemID = 3026; sign.Name = "City Stables"; sign.MoveToWorld( new Point3D( p.X - 5, p.Y - 1, p.Z + 7 ), from.Map ); } else if ( Type == CivicStrutureType.WoodCityTavern ) { WoodCityTavernAddon building = new WoodCityTavernAddon(); building.MoveToWorld( new Point3D( p.X - m_Offset.X, p.Y - m_Offset.Y, p.Z - m_Offset.Z ), from.Map ); PlayerMobile pm = (PlayerMobile)from; //Remove List ArrayList toDelete = new ArrayList(); CivicSign sign = new CivicSign(); sign.Stone = pm.City; sign.toDelete = toDelete; pm.City.HasTavern = true; Spawner spwn = new Spawner( "Barkeeper" ); spwn.Count = 1; spwn.Running = true; spwn.HomeRange = 3; spwn.MinDelay = TimeSpan.FromMinutes( 1 ); spwn.MaxDelay = TimeSpan.FromMinutes( 2 ); BaseDoor d1 = new StrongWoodDoor( DoorFacing.WestCW ); BaseDoor d2 = new StrongWoodDoor( DoorFacing.EastCCW ); d1.Link = d2; d2.Link = d1; d1.MoveToWorld( new Point3D( p.X - 5, p.Y - 1, p.Z + 7 ), from.Map ); d2.MoveToWorld( new Point3D( p.X - 4, p.Y - 1, p.Z + 7 ), from.Map ); spwn.MoveToWorld( new Point3D( p.X, p.Y - 7, p.Z + 7 ), from.Map ); sign.toDelete.Add( d1 ); sign.toDelete.Add( d2 ); sign.toDelete.Add( spwn ); sign.toDelete.Add( building ); sign.Type = CivicSignType.Tavern; pm.City.toDelete.Add( sign ); sign.ItemID = 3026; sign.Name = "City Tavern"; sign.MoveToWorld( new Point3D( p.X - 7, p.Y, p.Z + 7 ), from.Map ); } else if ( Type == CivicStrutureType.StoneCityTavern ) { StoneCityTavernAddon building = new StoneCityTavernAddon(); building.MoveToWorld( new Point3D( p.X - m_Offset.X, p.Y - m_Offset.Y, p.Z - m_Offset.Z ), from.Map ); PlayerMobile pm = (PlayerMobile)from; //Remove List ArrayList toDelete = new ArrayList(); CivicSign sign = new CivicSign(); sign.Stone = pm.City; sign.toDelete = toDelete; pm.City.HasTavern = true; Spawner spwn = new Spawner( "Barkeeper" ); spwn.Count = 1; spwn.Running = true; spwn.HomeRange = 3; spwn.MinDelay = TimeSpan.FromMinutes( 1 ); spwn.MaxDelay = TimeSpan.FromMinutes( 2 ); BaseDoor d1 = new StrongWoodDoor( DoorFacing.WestCW ); BaseDoor d2 = new StrongWoodDoor( DoorFacing.EastCCW ); d1.Link = d2; d2.Link = d1; d1.MoveToWorld( new Point3D( p.X - 5, p.Y - 1, p.Z + 7 ), from.Map ); d2.MoveToWorld( new Point3D( p.X - 4, p.Y - 1, p.Z + 7 ), from.Map ); spwn.MoveToWorld( new Point3D( p.X, p.Y - 7, p.Z + 7 ), from.Map ); sign.toDelete.Add( d1 ); sign.toDelete.Add( d2 ); sign.toDelete.Add( spwn ); sign.toDelete.Add( building ); sign.Type = CivicSignType.Tavern; pm.City.toDelete.Add( sign ); sign.ItemID = 3026; sign.Name = "City Tavern"; sign.MoveToWorld( new Point3D( p.X - 6, p.Y, p.Z + 7 ), from.Map ); } else if ( Type == CivicStrutureType.PlasterCityTavern ) { PlasterCityTavernAddon building = new PlasterCityTavernAddon(); building.MoveToWorld( new Point3D( p.X - m_Offset.X, p.Y - m_Offset.Y, p.Z - m_Offset.Z ), from.Map ); PlayerMobile pm = (PlayerMobile)from; //Remove List ArrayList toDelete = new ArrayList(); CivicSign sign = new CivicSign(); sign.Stone = pm.City; sign.toDelete = toDelete; pm.City.HasTavern = true; Spawner spwn = new Spawner( "Barkeeper" ); spwn.Count = 1; spwn.Running = true; spwn.HomeRange = 3; spwn.MinDelay = TimeSpan.FromMinutes( 1 ); spwn.MaxDelay = TimeSpan.FromMinutes( 2 ); BaseDoor d1 = new StrongWoodDoor( DoorFacing.WestCW ); BaseDoor d2 = new StrongWoodDoor( DoorFacing.EastCCW ); d1.Link = d2; d2.Link = d1; d1.MoveToWorld( new Point3D( p.X - 5, p.Y - 1, p.Z + 7 ), from.Map ); d2.MoveToWorld( new Point3D( p.X - 4, p.Y - 1, p.Z + 7 ), from.Map ); spwn.MoveToWorld( new Point3D( p.X, p.Y - 7, p.Z + 7 ), from.Map ); sign.toDelete.Add( d1 ); sign.toDelete.Add( d2 ); sign.toDelete.Add( spwn ); sign.toDelete.Add( building ); sign.Type = CivicSignType.Tavern; pm.City.toDelete.Add( sign ); sign.ItemID = 3026; sign.Name = "City Tavern"; sign.MoveToWorld( new Point3D( p.X - 7, p.Y, p.Z + 7 ), from.Map ); } else if ( Type == CivicStrutureType.FieldStoneCityTavern ) { FieldstoneCityTavernAddon building = new FieldstoneCityTavernAddon(); building.MoveToWorld( new Point3D( p.X - m_Offset.X, p.Y - m_Offset.Y, p.Z - m_Offset.Z ), from.Map ); PlayerMobile pm = (PlayerMobile)from; //Remove List ArrayList toDelete = new ArrayList(); CivicSign sign = new CivicSign(); sign.Stone = pm.City; sign.toDelete = toDelete; pm.City.HasTavern = true; Spawner spwn = new Spawner( "Barkeeper" ); spwn.Count = 1; spwn.Running = true; spwn.HomeRange = 3; spwn.MinDelay = TimeSpan.FromMinutes( 1 ); spwn.MaxDelay = TimeSpan.FromMinutes( 2 ); BaseDoor d1 = new StrongWoodDoor( DoorFacing.WestCW ); BaseDoor d2 = new StrongWoodDoor( DoorFacing.EastCCW ); d1.Link = d2; d2.Link = d1; d1.MoveToWorld( new Point3D( p.X - 5, p.Y - 1, p.Z + 7 ), from.Map ); d2.MoveToWorld( new Point3D( p.X - 4, p.Y - 1, p.Z + 7 ), from.Map ); spwn.MoveToWorld( new Point3D( p.X, p.Y - 7, p.Z + 7 ), from.Map ); sign.toDelete.Add( d1 ); sign.toDelete.Add( d2 ); sign.toDelete.Add( spwn ); sign.toDelete.Add( building ); sign.Type = CivicSignType.Tavern; pm.City.toDelete.Add( sign ); sign.ItemID = 3026; sign.Name = "City Tavern"; sign.MoveToWorld( new Point3D( p.X - 7, p.Y, p.Z + 7 ), from.Map ); } else if ( Type == CivicStrutureType.SandstoneCityTavern ) { SandstoneCityTavernAddon building = new SandstoneCityTavernAddon(); building.MoveToWorld( new Point3D( p.X - m_Offset.X, p.Y - m_Offset.Y, p.Z - m_Offset.Z ), from.Map ); PlayerMobile pm = (PlayerMobile)from; //Remove List ArrayList toDelete = new ArrayList(); CivicSign sign = new CivicSign(); sign.Stone = pm.City; sign.toDelete = toDelete; pm.City.HasTavern = true; Spawner spwn = new Spawner( "Barkeeper" ); spwn.Count = 1; spwn.Running = true; spwn.HomeRange = 3; spwn.MinDelay = TimeSpan.FromMinutes( 1 ); spwn.MaxDelay = TimeSpan.FromMinutes( 2 ); BaseDoor d1 = new StrongWoodDoor( DoorFacing.WestCW ); BaseDoor d2 = new StrongWoodDoor( DoorFacing.EastCCW ); d1.Link = d2; d2.Link = d1; d1.MoveToWorld( new Point3D( p.X - 5, p.Y - 1, p.Z + 7 ), from.Map ); d2.MoveToWorld( new Point3D( p.X - 4, p.Y - 1, p.Z + 7 ), from.Map ); spwn.MoveToWorld( new Point3D( p.X, p.Y - 7, p.Z + 7 ), from.Map ); sign.toDelete.Add( d1 ); sign.toDelete.Add( d2 ); sign.toDelete.Add( spwn ); sign.toDelete.Add( building ); sign.Type = CivicSignType.Tavern; pm.City.toDelete.Add( sign ); sign.ItemID = 3026; sign.Name = "City Tavern"; sign.MoveToWorld( new Point3D( p.X - 7, p.Y, p.Z + 7 ), from.Map ); } else if ( Type == CivicStrutureType.MarbleCityTavern ) { MarbleCityTavernAddon building = new MarbleCityTavernAddon(); building.MoveToWorld( new Point3D( p.X - m_Offset.X, p.Y - m_Offset.Y, p.Z - m_Offset.Z ), from.Map ); PlayerMobile pm = (PlayerMobile)from; //Remove List ArrayList toDelete = new ArrayList(); CivicSign sign = new CivicSign(); sign.Stone = pm.City; sign.toDelete = toDelete; pm.City.HasTavern = true; Spawner spwn = new Spawner( "Barkeeper" ); spwn.Count = 1; spwn.Running = true; spwn.HomeRange = 3; spwn.MinDelay = TimeSpan.FromMinutes( 1 ); spwn.MaxDelay = TimeSpan.FromMinutes( 2 ); BaseDoor d1 = new StrongWoodDoor( DoorFacing.WestCW ); BaseDoor d2 = new StrongWoodDoor( DoorFacing.EastCCW ); d1.Link = d2; d2.Link = d1; d1.MoveToWorld( new Point3D( p.X - 5, p.Y - 1, p.Z + 7 ), from.Map ); d2.MoveToWorld( new Point3D( p.X - 4, p.Y - 1, p.Z + 7 ), from.Map ); spwn.MoveToWorld( new Point3D( p.X, p.Y - 7, p.Z + 7 ), from.Map ); sign.toDelete.Add( d1 ); sign.toDelete.Add( d2 ); sign.toDelete.Add( spwn ); sign.toDelete.Add( building ); sign.Type = CivicSignType.Tavern; pm.City.toDelete.Add( sign ); sign.ItemID = 3026; sign.Name = "City Tavern"; sign.MoveToWorld( new Point3D( p.X - 7, p.Y, p.Z + 7 ), from.Map ); } else if ( Type == CivicStrutureType.NecroCityTavern ) { NecroCityTavernAddon building = new NecroCityTavernAddon(); building.MoveToWorld( new Point3D( p.X - m_Offset.X, p.Y - m_Offset.Y, p.Z - m_Offset.Z ), from.Map ); PlayerMobile pm = (PlayerMobile)from; //Remove List ArrayList toDelete = new ArrayList(); CivicSign sign = new CivicSign(); sign.Stone = pm.City; sign.toDelete = toDelete; pm.City.HasTavern = true; Spawner spwn = new Spawner( "Barkeeper" ); spwn.Count = 1; spwn.Running = true; spwn.HomeRange = 3; spwn.MinDelay = TimeSpan.FromMinutes( 1 ); spwn.MaxDelay = TimeSpan.FromMinutes( 2 ); BaseDoor d1 = new StrongWoodDoor( DoorFacing.WestCW ); BaseDoor d2 = new StrongWoodDoor( DoorFacing.EastCCW ); d1.Link = d2; d2.Link = d1; d1.MoveToWorld( new Point3D( p.X - 5, p.Y - 1, p.Z + 7 ), from.Map ); d2.MoveToWorld( new Point3D( p.X - 4, p.Y - 1, p.Z + 7 ), from.Map ); spwn.MoveToWorld( new Point3D( p.X, p.Y - 7, p.Z + 7 ), from.Map ); sign.toDelete.Add( d1 ); sign.toDelete.Add( d2 ); sign.toDelete.Add( spwn ); sign.toDelete.Add( building ); sign.Type = CivicSignType.Tavern; pm.City.toDelete.Add( sign ); sign.ItemID = 3026; sign.Name = "City Tavern"; sign.MoveToWorld( new Point3D( p.X - 7, p.Y, p.Z + 7 ), from.Map ); } else if ( Type == CivicStrutureType.AsianCityTavern ) { AsianCityTavernAddon building = new AsianCityTavernAddon(); building.MoveToWorld( new Point3D( p.X - m_Offset.X, p.Y - m_Offset.Y, p.Z - m_Offset.Z ), from.Map ); PlayerMobile pm = (PlayerMobile)from; //Remove List ArrayList toDelete = new ArrayList(); CivicSign sign = new CivicSign(); sign.Stone = pm.City; sign.toDelete = toDelete; pm.City.HasTavern = true; Spawner spwn = new Spawner( "Barkeeper" ); spwn.Count = 1; spwn.Running = true; spwn.HomeRange = 3; spwn.MinDelay = TimeSpan.FromMinutes( 1 ); spwn.MaxDelay = TimeSpan.FromMinutes( 2 ); BaseDoor d1 = new StrongWoodDoor( DoorFacing.WestCW ); BaseDoor d2 = new StrongWoodDoor( DoorFacing.EastCCW ); d1.Link = d2; d2.Link = d1; d1.MoveToWorld( new Point3D( p.X - 5, p.Y - 1, p.Z + 7 ), from.Map ); d2.MoveToWorld( new Point3D( p.X - 4, p.Y - 1, p.Z + 7 ), from.Map ); spwn.MoveToWorld( new Point3D( p.X, p.Y - 7, p.Z + 7 ), from.Map ); sign.toDelete.Add( d1 ); sign.toDelete.Add( d2 ); sign.toDelete.Add( spwn ); sign.toDelete.Add( building ); sign.Type = CivicSignType.Tavern; pm.City.toDelete.Add( sign ); sign.ItemID = 3026; sign.Name = "City Tavern"; sign.MoveToWorld( new Point3D( p.X - 7, p.Y, p.Z + 7 ), from.Map ); } else if ( Type == CivicStrutureType.WoodCityMoongate ) { WoodCityMoongateAddon building = new WoodCityMoongateAddon(); building.MoveToWorld( new Point3D( p.X - m_Offset.X, p.Y - m_Offset.Y, p.Z - m_Offset.Z ), from.Map ); PlayerMobile pm = (PlayerMobile)from; //Remove List ArrayList toDelete = new ArrayList(); CivicSign sign = new CivicSign(); sign.Stone = pm.City; sign.toDelete = toDelete; pm.City.HasMoongate = true; Spawner spwn = new Spawner( "PublicMoongate" ); spwn.Count = 1; spwn.Running = true; spwn.HomeRange = 0; spwn.MinDelay = TimeSpan.FromMinutes( 1 ); spwn.MaxDelay = TimeSpan.FromMinutes( 2 ); spwn.MoveToWorld( new Point3D( p.X, p.Y - 5, p.Z + 5 ), from.Map ); sign.toDelete.Add( spwn ); sign.toDelete.Add( building ); sign.Type = CivicSignType.Moongate; pm.City.toDelete.Add( sign ); pm.City.MoongateLocation = spwn.Location; sign.Name = "City Moongate"; sign.MoveToWorld( new Point3D( p.X - 3, p.Y, p.Z -6 ), from.Map ); } else if ( Type == CivicStrutureType.StoneCityMoongate ) { StoneCityMoongateAddon building = new StoneCityMoongateAddon(); building.MoveToWorld( new Point3D( p.X - m_Offset.X, p.Y - m_Offset.Y, p.Z - m_Offset.Z ), from.Map ); PlayerMobile pm = (PlayerMobile)from; //Remove List ArrayList toDelete = new ArrayList(); CivicSign sign = new CivicSign(); sign.Stone = pm.City; sign.toDelete = toDelete; pm.City.HasMoongate = true; Spawner spwn = new Spawner( "PublicMoongate" ); spwn.Count = 1; spwn.Running = true; spwn.HomeRange = 0; spwn.MinDelay = TimeSpan.FromMinutes( 1 ); spwn.MaxDelay = TimeSpan.FromMinutes( 2 ); spwn.MoveToWorld( new Point3D( p.X, p.Y - 5, p.Z + 5 ), from.Map ); sign.toDelete.Add( spwn ); sign.toDelete.Add( building ); sign.Type = CivicSignType.Moongate; pm.City.toDelete.Add( sign ); pm.City.MoongateLocation = spwn.Location; sign.Name = "City Moongate"; sign.MoveToWorld( new Point3D( p.X - 3, p.Y, p.Z -6 ), from.Map ); } else if ( Type == CivicStrutureType.SandstoneCityMoongate ) { SandstoneCityMoongateAddon building = new SandstoneCityMoongateAddon(); building.MoveToWorld( new Point3D( p.X - m_Offset.X, p.Y - m_Offset.Y, p.Z - m_Offset.Z ), from.Map ); PlayerMobile pm = (PlayerMobile)from; //Remove List ArrayList toDelete = new ArrayList(); CivicSign sign = new CivicSign(); sign.Stone = pm.City; sign.toDelete = toDelete; pm.City.HasMoongate = true; Spawner spwn = new Spawner( "PublicMoongate" ); spwn.Count = 1; spwn.Running = true; spwn.HomeRange = 0; spwn.MinDelay = TimeSpan.FromMinutes( 1 ); spwn.MaxDelay = TimeSpan.FromMinutes( 2 ); spwn.MoveToWorld( new Point3D( p.X, p.Y - 5, p.Z + 5 ), from.Map ); sign.toDelete.Add( spwn ); sign.toDelete.Add( building ); sign.Type = CivicSignType.Moongate; pm.City.toDelete.Add( sign ); pm.City.MoongateLocation = spwn.Location; sign.Name = "City Moongate"; sign.MoveToWorld( new Point3D( p.X - 3, p.Y, p.Z -6 ), from.Map ); } else if ( Type == CivicStrutureType.MarbleCityMoongate ) { MarbleCityMoongateAddon building = new MarbleCityMoongateAddon(); building.MoveToWorld( new Point3D( p.X - m_Offset.X, p.Y - m_Offset.Y, p.Z - m_Offset.Z ), from.Map ); PlayerMobile pm = (PlayerMobile)from; //Remove List ArrayList toDelete = new ArrayList(); CivicSign sign = new CivicSign(); sign.Stone = pm.City; sign.toDelete = toDelete; pm.City.HasMoongate = true; Spawner spwn = new Spawner( "PublicMoongate" ); spwn.Count = 1; spwn.Running = true; spwn.HomeRange = 0; spwn.MinDelay = TimeSpan.FromMinutes( 1 ); spwn.MaxDelay = TimeSpan.FromMinutes( 2 ); spwn.MoveToWorld( new Point3D( p.X, p.Y - 5, p.Z + 5 ), from.Map ); sign.toDelete.Add( spwn ); sign.toDelete.Add( building ); sign.Type = CivicSignType.Moongate; pm.City.toDelete.Add( sign ); pm.City.MoongateLocation = spwn.Location; sign.Name = "City Moongate"; sign.MoveToWorld( new Point3D( p.X - 3, p.Y, p.Z -6 ), from.Map ); } else if ( Type == CivicStrutureType.NecroCityMoongate ) { NecroCityMoongateAddon building = new NecroCityMoongateAddon(); building.MoveToWorld( new Point3D( p.X - m_Offset.X, p.Y - m_Offset.Y, p.Z - m_Offset.Z ), from.Map ); PlayerMobile pm = (PlayerMobile)from; //Remove List ArrayList toDelete = new ArrayList(); CivicSign sign = new CivicSign(); sign.Stone = pm.City; sign.toDelete = toDelete; pm.City.HasMoongate = true; Spawner spwn = new Spawner( "PublicMoongate" ); spwn.Count = 1; spwn.Running = true; spwn.HomeRange = 0; spwn.MinDelay = TimeSpan.FromMinutes( 1 ); spwn.MaxDelay = TimeSpan.FromMinutes( 2 ); spwn.MoveToWorld( new Point3D( p.X, p.Y - 5, p.Z + 5 ), from.Map ); sign.toDelete.Add( spwn ); sign.toDelete.Add( building ); sign.Type = CivicSignType.Moongate; pm.City.toDelete.Add( sign ); pm.City.MoongateLocation = spwn.Location; sign.ItemID = 3026; sign.Name = "City Moongate"; sign.MoveToWorld( new Point3D( p.X - 4, p.Y, p.Z + 10 ), from.Map ); } else if ( Type == CivicStrutureType.AsianCityMoongate ) { AsianCityMoongateAddon building = new AsianCityMoongateAddon(); building.MoveToWorld( new Point3D( p.X - m_Offset.X, p.Y - m_Offset.Y, p.Z - m_Offset.Z ), from.Map ); PlayerMobile pm = (PlayerMobile)from; //Remove List ArrayList toDelete = new ArrayList(); CivicSign sign = new CivicSign(); sign.Stone = pm.City; sign.toDelete = toDelete; pm.City.HasMoongate = true; Spawner spwn = new Spawner( "PublicMoongate" ); spwn.Count = 1; spwn.Running = true; spwn.HomeRange = 0; spwn.MinDelay = TimeSpan.FromMinutes( 1 ); spwn.MaxDelay = TimeSpan.FromMinutes( 2 ); spwn.MoveToWorld( new Point3D( p.X, p.Y - 5, p.Z + 5 ), from.Map ); sign.toDelete.Add( spwn ); sign.toDelete.Add( building ); sign.Type = CivicSignType.Moongate; pm.City.toDelete.Add( sign ); pm.City.MoongateLocation = spwn.Location; sign.Name = "City Moongate"; sign.MoveToWorld( new Point3D( p.X - 3, p.Y, p.Z -6 ), from.Map ); } else if ( Type == CivicStrutureType.SmallCityGarden ) { SmallCityGardenAddon building = new SmallCityGardenAddon(); building.MoveToWorld( new Point3D( p.X - m_Offset.X, p.Y - m_Offset.Y, p.Z - m_Offset.Z ), from.Map ); PlayerMobile pm = (PlayerMobile)from; //Remove List ArrayList toDelete = new ArrayList(); RecCivicSign sign = new RecCivicSign(); sign.Stone = pm.City; sign.toDelete = toDelete; sign.CityLevel = 1; sign.toDelete.Add( building ); sign.Type = CivicSignType.Garden; pm.City.toDelete.Add( sign ); pm.City.Gardens.Add( sign ); sign.ItemID = 3026; sign.Name = "City Small Garden"; sign.MoveToWorld( new Point3D( p.X - 3, p.Y, p.Z + 7 ), from.Map ); } else if ( Type == CivicStrutureType.MedCityGarden ) { MedCityGardenAddon building = new MedCityGardenAddon(); building.MoveToWorld( new Point3D( p.X - m_Offset.X, p.Y - m_Offset.Y, p.Z - m_Offset.Z ), from.Map ); PlayerMobile pm = (PlayerMobile)from; //Remove List ArrayList toDelete = new ArrayList(); RecCivicSign sign = new RecCivicSign(); sign.Stone = pm.City; sign.toDelete = toDelete; sign.CityLevel = 2; sign.toDelete.Add( building ); sign.Type = CivicSignType.Garden; pm.City.toDelete.Add( sign ); pm.City.Gardens.Add( sign ); sign.ItemID = 3026; sign.Name = "City Medium Garden"; sign.MoveToWorld( new Point3D( p.X - 4, p.Y - 1, p.Z + 7 ), from.Map ); } else if ( Type == CivicStrutureType.LargeCityGarden ) { LargeCityGardenAddon building = new LargeCityGardenAddon(); building.MoveToWorld( new Point3D( p.X - m_Offset.X, p.Y - m_Offset.Y, p.Z - m_Offset.Z ), from.Map ); PlayerMobile pm = (PlayerMobile)from; //Remove List ArrayList toDelete = new ArrayList(); RecCivicSign sign = new RecCivicSign(); sign.Stone = pm.City; sign.toDelete = toDelete; sign.CityLevel = 3; sign.toDelete.Add( building ); sign.Type = CivicSignType.Garden; pm.City.toDelete.Add( sign ); pm.City.Gardens.Add( sign ); sign.ItemID = 3026; sign.Name = "City Large Garden"; sign.MoveToWorld( new Point3D( p.X - 8, p.Y, p.Z + 7 ), from.Map ); } else if ( Type == CivicStrutureType.SmallCityPark ) { SmallCityParkAddon building = new SmallCityParkAddon(); building.MoveToWorld( new Point3D( p.X - m_Offset.X, p.Y - m_Offset.Y, p.Z - m_Offset.Z ), from.Map ); PlayerMobile pm = (PlayerMobile)from; //Remove List ArrayList toDelete = new ArrayList(); RecCivicSign sign = new RecCivicSign(); sign.Stone = pm.City; sign.toDelete = toDelete; sign.CityLevel = 4; sign.toDelete.Add( building ); sign.Type = CivicSignType.Park; pm.City.toDelete.Add( sign ); pm.City.Gardens.Add( sign ); sign.ItemID = 3026; sign.Name = "City Small Park"; sign.MoveToWorld( new Point3D( p.X - 4, p.Y, p.Z + 7 ), from.Map ); } else if ( Type == CivicStrutureType.MedCityPark ) { MedCityParkAddon building = new MedCityParkAddon(); building.MoveToWorld( new Point3D( p.X - m_Offset.X, p.Y - m_Offset.Y, p.Z - m_Offset.Z ), from.Map ); PlayerMobile pm = (PlayerMobile)from; //Remove List ArrayList toDelete = new ArrayList(); RecCivicSign sign = new RecCivicSign(); sign.Stone = pm.City; sign.toDelete = toDelete; sign.CityLevel = 5; sign.toDelete.Add( building ); sign.Type = CivicSignType.Park; pm.City.toDelete.Add( sign ); pm.City.Gardens.Add( sign ); sign.ItemID = 3026; sign.Name = "City Medium Park"; sign.MoveToWorld( new Point3D( p.X - 7, p.Y, p.Z + 7 ), from.Map ); } else if ( Type == CivicStrutureType.LargeCityPark ) { LargeCityParkAddon building = new LargeCityParkAddon(); building.MoveToWorld( new Point3D( p.X - m_Offset.X, p.Y - m_Offset.Y, p.Z - m_Offset.Z ), from.Map ); PlayerMobile pm = (PlayerMobile)from; //Remove List ArrayList toDelete = new ArrayList(); RecCivicSign sign = new RecCivicSign(); sign.Stone = pm.City; sign.toDelete = toDelete; sign.CityLevel = 6; sign.toDelete.Add( building ); sign.Type = CivicSignType.Park; pm.City.toDelete.Add( sign ); pm.City.Gardens.Add( sign ); sign.ItemID = 3026; sign.Name = "City Large Park"; sign.MoveToWorld( new Point3D( p.X - 8, p.Y - 1, p.Z + 7 ), from.Map ); } else if ( Type == CivicStrutureType.AsianMarket ) { AsianCityMarketAddon building = new AsianCityMarketAddon(); building.MoveToWorld( new Point3D( p.X - m_Offset.X, p.Y - m_Offset.Y, p.Z - m_Offset.Z ), from.Map ); PlayerMobile pm = (PlayerMobile)from; CivicSign sign = new CivicSign(); Point3D center = new Point3D( p.X - m_Offset.X, p.Y - m_Offset.Y, p.Z - m_Offset.Z ); Point3D start = new Point3D( center.X - 4, center.Y - 4, center.Z ); Point3D end = new Point3D( center.X + 6, center.Y + 6, center.Z ); Rectangle2D box = new Rectangle2D( start, end ); Rectangle3D[] area = PlayerGovernmentSystem.FormatRegion( box ); CityLandLord lord = new CityLandLord( pm.City, area, sign, p, from.Map ); //Remove List ArrayList toDelete = new ArrayList(); sign.Stone = pm.City; sign.toDelete = toDelete; sign.Stone.HasMarket = true; sign.toDelete.Add( building ); sign.LandlordRemove = lord; sign.Type = CivicSignType.Market; pm.City.toDelete.Add( sign ); sign.ItemID = 3026; sign.Name = "City Market"; sign.MoveToWorld( new Point3D( p.X - 4, p.Y -1, p.Z + 7 ), from.Map ); } else if ( Type == CivicStrutureType.FieldstoneMarket ) { FieldstoneCityMarketAddon building = new FieldstoneCityMarketAddon(); building.MoveToWorld( new Point3D( p.X - m_Offset.X, p.Y - m_Offset.Y, p.Z - m_Offset.Z ), from.Map ); PlayerMobile pm = (PlayerMobile)from; CivicSign sign = new CivicSign(); Point3D center = new Point3D( p.X - m_Offset.X, p.Y - m_Offset.Y, p.Z - m_Offset.Z ); Point3D start = new Point3D( center.X - 4, center.Y - 4, center.Z ); Point3D end = new Point3D( center.X + 6, center.Y + 6, center.Z ); Rectangle2D box = new Rectangle2D( start, end ); Rectangle3D[] area = PlayerGovernmentSystem.FormatRegion( box ); CityLandLord lord = new CityLandLord( pm.City, area, sign, p, from.Map ); //Remove List ArrayList toDelete = new ArrayList(); sign.Stone = pm.City; sign.toDelete = toDelete; sign.Stone.HasMarket = true; sign.toDelete.Add( building ); sign.LandlordRemove = lord; sign.Type = CivicSignType.Market; pm.City.toDelete.Add( sign ); sign.ItemID = 3026; sign.Name = "City Market"; sign.MoveToWorld( new Point3D( p.X - 4, p.Y -1, p.Z + 7 ), from.Map ); } else if ( Type == CivicStrutureType.SandstoneMarket ) { SandstoneCityMarketAddon building = new SandstoneCityMarketAddon(); building.MoveToWorld( new Point3D( p.X - m_Offset.X, p.Y - m_Offset.Y, p.Z - m_Offset.Z ), from.Map ); PlayerMobile pm = (PlayerMobile)from; CivicSign sign = new CivicSign(); Point3D center = new Point3D( p.X - m_Offset.X, p.Y - m_Offset.Y, p.Z - m_Offset.Z ); Point3D start = new Point3D( center.X - 4, center.Y - 4, center.Z ); Point3D end = new Point3D( center.X + 6, center.Y + 6, center.Z ); Rectangle2D box = new Rectangle2D( start, end ); Rectangle3D[] area = PlayerGovernmentSystem.FormatRegion( box ); CityLandLord lord = new CityLandLord( pm.City, area, sign, p, from.Map ); //Remove List ArrayList toDelete = new ArrayList(); sign.Stone = pm.City; sign.toDelete = toDelete; sign.Stone.HasMarket = true; sign.toDelete.Add( building ); sign.LandlordRemove = lord; sign.Type = CivicSignType.Market; pm.City.toDelete.Add( sign ); sign.ItemID = 3026; sign.Name = "City Market"; sign.MoveToWorld( new Point3D( p.X - 4, p.Y -1, p.Z + 7 ), from.Map ); } else if ( Type == CivicStrutureType.MarbleMarket ) { MarbleCityMarketAddon building = new MarbleCityMarketAddon(); building.MoveToWorld( new Point3D( p.X - m_Offset.X, p.Y - m_Offset.Y, p.Z - m_Offset.Z ), from.Map ); PlayerMobile pm = (PlayerMobile)from; CivicSign sign = new CivicSign(); Point3D center = new Point3D( p.X - m_Offset.X, p.Y - m_Offset.Y, p.Z - m_Offset.Z ); Point3D start = new Point3D( center.X - 4, center.Y - 4, center.Z ); Point3D end = new Point3D( center.X + 6, center.Y + 6, center.Z ); Rectangle2D box = new Rectangle2D( start, end ); Rectangle3D[] area = PlayerGovernmentSystem.FormatRegion( box ); CityLandLord lord = new CityLandLord( pm.City, area, sign, p, from.Map ); //Remove List ArrayList toDelete = new ArrayList(); sign.Stone = pm.City; sign.toDelete = toDelete; sign.Stone.HasMarket = true; sign.toDelete.Add( building ); sign.LandlordRemove = lord; sign.Type = CivicSignType.Market; pm.City.toDelete.Add( sign ); sign.ItemID = 3026; sign.Name = "City Market"; sign.MoveToWorld( new Point3D( p.X - 4, p.Y -1, p.Z + 7 ), from.Map ); } else if ( Type == CivicStrutureType.NecroMarket ) { NecroCityMarketAddon building = new NecroCityMarketAddon(); building.MoveToWorld( new Point3D( p.X - m_Offset.X, p.Y - m_Offset.Y, p.Z - m_Offset.Z ), from.Map ); PlayerMobile pm = (PlayerMobile)from; CivicSign sign = new CivicSign(); Point3D center = new Point3D( p.X - m_Offset.X, p.Y - m_Offset.Y, p.Z - m_Offset.Z ); Point3D start = new Point3D( center.X - 4, center.Y - 4, center.Z ); Point3D end = new Point3D( center.X + 6, center.Y + 6, center.Z ); Rectangle2D box = new Rectangle2D( start, end ); Rectangle3D[] area = PlayerGovernmentSystem.FormatRegion( box ); CityLandLord lord = new CityLandLord( pm.City, area, sign, p, from.Map ); //Remove List ArrayList toDelete = new ArrayList(); sign.Stone = pm.City; sign.toDelete = toDelete; sign.Stone.HasMarket = true; sign.toDelete.Add( building ); sign.LandlordRemove = lord; sign.Type = CivicSignType.Market; pm.City.toDelete.Add( sign ); sign.ItemID = 3026; sign.Name = "City Market"; sign.MoveToWorld( new Point3D( p.X - 4, p.Y -1, p.Z + 7 ), from.Map ); } else if ( Type == CivicStrutureType.WoodMarket ) { WoodCityMarketAddon building = new WoodCityMarketAddon(); building.MoveToWorld( new Point3D( p.X - m_Offset.X, p.Y - m_Offset.Y, p.Z - m_Offset.Z ), from.Map ); PlayerMobile pm = (PlayerMobile)from; CivicSign sign = new CivicSign(); Point3D center = new Point3D( p.X - m_Offset.X, p.Y - m_Offset.Y, p.Z - m_Offset.Z ); Point3D start = new Point3D( center.X - 4, center.Y - 4, center.Z ); Point3D end = new Point3D( center.X + 6, center.Y + 6, center.Z ); Rectangle2D box = new Rectangle2D( start, end ); Rectangle3D[] area = PlayerGovernmentSystem.FormatRegion( box ); CityLandLord lord = new CityLandLord( pm.City, area, sign, p, from.Map ); //Remove List ArrayList toDelete = new ArrayList(); sign.Stone = pm.City; sign.toDelete = toDelete; sign.Stone.HasMarket = true; sign.toDelete.Add( building ); sign.LandlordRemove = lord; sign.Type = CivicSignType.Market; pm.City.toDelete.Add( sign ); sign.ItemID = 3026; sign.Name = "City Market"; sign.MoveToWorld( new Point3D( p.X - 4, p.Y -1, p.Z + 7 ), from.Map ); } else if ( Type == CivicStrutureType.StoneMarket ) { StoneCityMarketAddon building = new StoneCityMarketAddon(); building.MoveToWorld( new Point3D( p.X - m_Offset.X, p.Y - m_Offset.Y, p.Z - m_Offset.Z ), from.Map ); PlayerMobile pm = (PlayerMobile)from; CivicSign sign = new CivicSign(); Point3D center = new Point3D( p.X - m_Offset.X, p.Y - m_Offset.Y, p.Z - m_Offset.Z ); Point3D start = new Point3D( center.X - 4, center.Y - 4, center.Z ); Point3D end = new Point3D( center.X + 6, center.Y + 6, center.Z ); Rectangle2D box = new Rectangle2D( start, end ); Rectangle3D[] area = PlayerGovernmentSystem.FormatRegion( box ); CityLandLord lord = new CityLandLord( pm.City, area, sign, p, from.Map ); //Remove List ArrayList toDelete = new ArrayList(); sign.Stone = pm.City; sign.toDelete = toDelete; sign.Stone.HasMarket = true; sign.toDelete.Add( building ); sign.LandlordRemove = lord; sign.Type = CivicSignType.Market; pm.City.toDelete.Add( sign ); sign.ItemID = 3026; sign.Name = "City Market"; sign.MoveToWorld( new Point3D( p.X - 4, p.Y -1, p.Z + 7 ), from.Map ); } else if ( Type == CivicStrutureType.PlasterMarket ) { PlasterCityMarketAddon building = new PlasterCityMarketAddon(); building.MoveToWorld( new Point3D( p.X - m_Offset.X, p.Y - m_Offset.Y, p.Z - m_Offset.Z ), from.Map ); PlayerMobile pm = (PlayerMobile)from; CivicSign sign = new CivicSign(); Point3D center = new Point3D( p.X - m_Offset.X, p.Y - m_Offset.Y, p.Z - m_Offset.Z ); Point3D start = new Point3D( center.X - 4, center.Y - 4, center.Z ); Point3D end = new Point3D( center.X + 6, center.Y + 6, center.Z ); Rectangle2D box = new Rectangle2D( start, end ); Rectangle3D[] area = PlayerGovernmentSystem.FormatRegion( box ); CityLandLord lord = new CityLandLord( pm.City, area, sign, p, from.Map ); //Remove List ArrayList toDelete = new ArrayList(); sign.Stone = pm.City; sign.toDelete = toDelete; sign.Stone.HasMarket = true; sign.toDelete.Add( building ); sign.LandlordRemove = lord; sign.Type = CivicSignType.Market; pm.City.toDelete.Add( sign ); sign.ItemID = 3026; sign.Name = "City Market"; sign.MoveToWorld( new Point3D( p.X - 4, p.Y -1, p.Z + 7 ), from.Map ); } this.Delete(); }