Formatting FIxes (#58)
This commit is contained in:
parent
57fb9fb525
commit
096d39609e
1318 changed files with 11633 additions and 22129 deletions
|
|
@ -526,10 +526,7 @@ namespace Server.Multis
|
|||
Delete();
|
||||
}
|
||||
|
||||
public virtual HousePlacementEntry GetAosEntry()
|
||||
{
|
||||
return HousePlacementEntry.Find(this);
|
||||
}
|
||||
public virtual HousePlacementEntry GetAosEntry() => HousePlacementEntry.Find(this);
|
||||
|
||||
public virtual int GetAosMaxSecures()
|
||||
{
|
||||
|
|
@ -626,10 +623,7 @@ namespace Server.Multis
|
|||
return PlayerVendors.Count + VendorRentalContracts.Count < GetNewVendorSystemMaxVendors();
|
||||
}
|
||||
|
||||
public virtual bool CanPlaceNewBarkeep()
|
||||
{
|
||||
return PlayerBarkeepers.Count < MaximumBarkeepCount;
|
||||
}
|
||||
public virtual bool CanPlaceNewBarkeep() => PlayerBarkeepers.Count < MaximumBarkeepCount;
|
||||
|
||||
public static void IsThereVendor(Point3D location, Map map, out bool vendor, out bool rentalContract)
|
||||
{
|
||||
|
|
@ -1038,16 +1032,11 @@ namespace Server.Multis
|
|||
return list;
|
||||
}
|
||||
|
||||
public virtual bool CheckAosLockdowns(int need)
|
||||
{
|
||||
return GetAosCurLockdowns() + need <= GetAosMaxLockdowns();
|
||||
}
|
||||
public virtual bool CheckAosLockdowns(int need) => GetAosCurLockdowns() + need <= GetAosMaxLockdowns();
|
||||
|
||||
public virtual bool CheckAosStorage(int need)
|
||||
{
|
||||
return GetAosCurSecures(out int fromSecures, out int fromVendors, out int fromLockdowns, out int fromMovingCrate) + need <=
|
||||
GetAosMaxSecures();
|
||||
}
|
||||
public virtual bool CheckAosStorage(int need) =>
|
||||
GetAosCurSecures(out int fromSecures, out int fromVendors, out int fromLockdowns, out int fromMovingCrate) + need <=
|
||||
GetAosMaxSecures();
|
||||
|
||||
public static void Configure()
|
||||
{
|
||||
|
|
@ -1072,15 +1061,9 @@ namespace Server.Multis
|
|||
return v;
|
||||
}
|
||||
|
||||
public static bool CheckLockedDown(Item item)
|
||||
{
|
||||
return FindHouseAt(item)?.HasLockedDownItem(item) == true;
|
||||
}
|
||||
public static bool CheckLockedDown(Item item) => FindHouseAt(item)?.HasLockedDownItem(item) == true;
|
||||
|
||||
public static bool CheckSecured(Item item)
|
||||
{
|
||||
return FindHouseAt(item)?.HasSecureItem(item) == true;
|
||||
}
|
||||
public static bool CheckSecured(Item item) => FindHouseAt(item)?.HasSecureItem(item) == true;
|
||||
|
||||
public static bool CheckLockedDownOrSecured(Item item)
|
||||
{
|
||||
|
|
@ -1159,11 +1142,9 @@ namespace Server.Multis
|
|||
return FindHouseAt(m.Location, m.Map, 16);
|
||||
}
|
||||
|
||||
public static BaseHouse FindHouseAt(Item item)
|
||||
{
|
||||
return item?.Deleted != false ? null :
|
||||
public static BaseHouse FindHouseAt(Item item) =>
|
||||
item?.Deleted != false ? null :
|
||||
FindHouseAt(item.GetWorldLocation(), item.Map, item.ItemData.Height);
|
||||
}
|
||||
|
||||
public static BaseHouse FindHouseAt(Point3D loc, Map map, int height)
|
||||
{
|
||||
|
|
@ -1181,15 +1162,9 @@ namespace Server.Multis
|
|||
return null;
|
||||
}
|
||||
|
||||
public bool IsInside(Mobile m)
|
||||
{
|
||||
return m?.Deleted == false && m.Map == Map && IsInside(m.Location, 16);
|
||||
}
|
||||
public bool IsInside(Mobile m) => m?.Deleted == false && m.Map == Map && IsInside(m.Location, 16);
|
||||
|
||||
public bool IsInside(Item item)
|
||||
{
|
||||
return item?.Deleted == false && item.Map == Map && IsInside(item.Location, item.ItemData.Height);
|
||||
}
|
||||
public bool IsInside(Item item) => item?.Deleted == false && item.Map == Map && IsInside(item.Location, item.ItemData.Height);
|
||||
|
||||
public bool CheckAccessibility(Item item, Mobile from)
|
||||
{
|
||||
|
|
@ -1367,10 +1342,7 @@ namespace Server.Multis
|
|||
}
|
||||
}
|
||||
|
||||
public BaseDoor AddEastDoor(int x, int y, int z)
|
||||
{
|
||||
return AddEastDoor(true, x, y, z);
|
||||
}
|
||||
public BaseDoor AddEastDoor(int x, int y, int z) => AddEastDoor(true, x, y, z);
|
||||
|
||||
public BaseDoor AddEastDoor(bool wood, int x, int y, int z)
|
||||
{
|
||||
|
|
@ -1381,10 +1353,7 @@ namespace Server.Multis
|
|||
return door;
|
||||
}
|
||||
|
||||
public BaseDoor AddSouthDoor(int x, int y, int z)
|
||||
{
|
||||
return AddSouthDoor(true, x, y, z);
|
||||
}
|
||||
public BaseDoor AddSouthDoor(int x, int y, int z) => AddSouthDoor(true, x, y, z);
|
||||
|
||||
public BaseDoor AddSouthDoor(bool wood, int x, int y, int z)
|
||||
{
|
||||
|
|
@ -1395,10 +1364,7 @@ namespace Server.Multis
|
|||
return door;
|
||||
}
|
||||
|
||||
public BaseDoor AddEastDoor(int x, int y, int z, uint k)
|
||||
{
|
||||
return AddEastDoor(true, x, y, z, k);
|
||||
}
|
||||
public BaseDoor AddEastDoor(int x, int y, int z, uint k) => AddEastDoor(true, x, y, z, k);
|
||||
|
||||
public BaseDoor AddEastDoor(bool wood, int x, int y, int z, uint k)
|
||||
{
|
||||
|
|
@ -1412,10 +1378,7 @@ namespace Server.Multis
|
|||
return door;
|
||||
}
|
||||
|
||||
public BaseDoor AddSouthDoor(int x, int y, int z, uint k)
|
||||
{
|
||||
return AddSouthDoor(true, x, y, z, k);
|
||||
}
|
||||
public BaseDoor AddSouthDoor(int x, int y, int z, uint k) => AddSouthDoor(true, x, y, z, k);
|
||||
|
||||
public BaseDoor AddSouthDoor(bool wood, int x, int y, int z, uint k)
|
||||
{
|
||||
|
|
@ -1429,10 +1392,7 @@ namespace Server.Multis
|
|||
return door;
|
||||
}
|
||||
|
||||
public BaseDoor[] AddSouthDoors(int x, int y, int z, uint k)
|
||||
{
|
||||
return AddSouthDoors(true, x, y, z, k);
|
||||
}
|
||||
public BaseDoor[] AddSouthDoors(int x, int y, int z, uint k) => AddSouthDoors(true, x, y, z, k);
|
||||
|
||||
public BaseDoor[] AddSouthDoors(bool wood, int x, int y, int z, uint k)
|
||||
{
|
||||
|
|
@ -1480,10 +1440,7 @@ namespace Server.Multis
|
|||
return value;
|
||||
}
|
||||
|
||||
public BaseDoor[] AddSouthDoors(int x, int y, int z)
|
||||
{
|
||||
return AddSouthDoors(true, x, y, z, false);
|
||||
}
|
||||
public BaseDoor[] AddSouthDoors(int x, int y, int z) => AddSouthDoors(true, x, y, z, false);
|
||||
|
||||
public BaseDoor[] AddSouthDoors(bool wood, int x, int y, int z, bool inv)
|
||||
{
|
||||
|
|
@ -1594,10 +1551,7 @@ namespace Server.Multis
|
|||
SetLockdown(c, locked, checkContains);
|
||||
}
|
||||
|
||||
public bool LockDown(Mobile m, Item item)
|
||||
{
|
||||
return LockDown(m, item, true);
|
||||
}
|
||||
public bool LockDown(Mobile m, Item item) => LockDown(m, item, true);
|
||||
|
||||
public bool LockDown(Mobile m, Item item, bool checkIsInside)
|
||||
{
|
||||
|
|
@ -2954,10 +2908,7 @@ namespace Server.Multis
|
|||
}
|
||||
}
|
||||
|
||||
public virtual HouseDeed GetDeed()
|
||||
{
|
||||
return null;
|
||||
}
|
||||
public virtual HouseDeed GetDeed() => null;
|
||||
|
||||
public bool IsFriend(Mobile m)
|
||||
{
|
||||
|
|
@ -3010,11 +2961,9 @@ namespace Server.Multis
|
|||
return m != null && (m.AccessLevel > AccessLevel.Player || IsFriend(m) || Access?.Contains(m) == true);
|
||||
}
|
||||
|
||||
public bool HasLockedDownItem(Item check)
|
||||
{
|
||||
return LockDowns?.Contains(check) == true ||
|
||||
check is VendorRentalContract contract && VendorRentalContracts.Contains(contract);
|
||||
}
|
||||
public bool HasLockedDownItem(Item check) =>
|
||||
LockDowns?.Contains(check) == true ||
|
||||
check is VendorRentalContract contract && VendorRentalContracts.Contains(contract);
|
||||
|
||||
public bool HasSecureItem(Item item)
|
||||
{
|
||||
|
|
@ -3667,9 +3616,6 @@ namespace Server.Multis
|
|||
Timer.DelayCall(house.RestrictedPlacingTime, Unregister);
|
||||
}
|
||||
|
||||
public override bool AllowHousing(Mobile from, Point3D p)
|
||||
{
|
||||
return from == m_RegionOwner || AccountHandler.CheckAccount(from, m_RegionOwner);
|
||||
}
|
||||
public override bool AllowHousing(Mobile from, Point3D p) => from == m_RegionOwner || AccountHandler.CheckAccount(from, m_RegionOwner);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -453,10 +453,7 @@ namespace Server.Multis
|
|||
SPlank.Map = Map;
|
||||
}
|
||||
|
||||
public bool CanCommand(Mobile m)
|
||||
{
|
||||
return true;
|
||||
}
|
||||
public bool CanCommand(Mobile m) => true;
|
||||
|
||||
public Point3D GetMarkedLocation()
|
||||
{
|
||||
|
|
@ -465,10 +462,7 @@ namespace Server.Multis
|
|||
return Rotate(p, (int)m_Facing / 2);
|
||||
}
|
||||
|
||||
public bool CheckKey(uint keyValue)
|
||||
{
|
||||
return SPlank?.KeyValue == keyValue || PPlank?.KeyValue == keyValue;
|
||||
}
|
||||
public bool CheckKey(uint keyValue) => SPlank?.KeyValue == keyValue || PPlank?.KeyValue == keyValue;
|
||||
|
||||
public void Refresh()
|
||||
{
|
||||
|
|
@ -1265,14 +1259,12 @@ namespace Server.Multis
|
|||
return new Point3D(Location.X + rx, Location.Y + ry, p.Z);
|
||||
}
|
||||
|
||||
public override bool Contains(int x, int y)
|
||||
{
|
||||
return base.Contains(x, y) ||
|
||||
TillerMan?.X == x && y == TillerMan.Y ||
|
||||
Hold?.X == x && Hold.Y == y ||
|
||||
PPlank?.X == x && PPlank.Y == y ||
|
||||
SPlank?.X == x && SPlank.Y == y;
|
||||
}
|
||||
public override bool Contains(int x, int y) =>
|
||||
base.Contains(x, y) ||
|
||||
TillerMan?.X == x && y == TillerMan.Y ||
|
||||
Hold?.X == x && Hold.Y == y ||
|
||||
PPlank?.X == x && PPlank.Y == y ||
|
||||
SPlank?.X == x && SPlank.Y == y;
|
||||
|
||||
public static bool IsValidLocation(Point3D p, Map map)
|
||||
{
|
||||
|
|
@ -1285,10 +1277,7 @@ namespace Server.Multis
|
|||
return false;
|
||||
}
|
||||
|
||||
public static Rectangle2D[] GetWrapFor(Map m)
|
||||
{
|
||||
return m == Map.Ilshenar ? m_IlshWrap : m == Map.Tokuno ? m_TokunoWrap : m_BritWrap;
|
||||
}
|
||||
public static Rectangle2D[] GetWrapFor(Map m) => m == Map.Ilshenar ? m_IlshWrap : m == Map.Tokuno ? m_TokunoWrap : m_BritWrap;
|
||||
|
||||
public Direction GetMovementFor(int x, int y, out int maxSpeed)
|
||||
{
|
||||
|
|
|
|||
|
|
@ -146,10 +146,7 @@ namespace Server.Multis
|
|||
{
|
||||
private BaseBoatDeed m_Deed;
|
||||
|
||||
public InternalTarget(BaseBoatDeed deed) : base(deed.MultiID, deed.Offset)
|
||||
{
|
||||
m_Deed = deed;
|
||||
}
|
||||
public InternalTarget(BaseBoatDeed deed) : base(deed.MultiID, deed.Offset) => m_Deed = deed;
|
||||
|
||||
protected override void OnTarget(Mobile from, object o)
|
||||
{
|
||||
|
|
|
|||
|
|
@ -165,10 +165,7 @@ namespace Server.Multis
|
|||
{
|
||||
private BaseDockedBoat m_Model;
|
||||
|
||||
public InternalTarget(BaseDockedBoat model) : base(model.MultiID, model.Offset)
|
||||
{
|
||||
m_Model = model;
|
||||
}
|
||||
public InternalTarget(BaseDockedBoat model) : base(model.MultiID, model.Offset) => m_Model = model;
|
||||
|
||||
protected override void OnTarget(Mobile from, object o)
|
||||
{
|
||||
|
|
|
|||
|
|
@ -6,10 +6,7 @@ namespace Server.Multis
|
|||
{
|
||||
private BaseBoat m_Boat;
|
||||
|
||||
public RenameBoatPrompt(BaseBoat boat)
|
||||
{
|
||||
m_Boat = boat;
|
||||
}
|
||||
public RenameBoatPrompt(BaseBoat boat) => m_Boat = boat;
|
||||
|
||||
public override void OnResponse(Mobile from, string text)
|
||||
{
|
||||
|
|
|
|||
|
|
@ -171,10 +171,7 @@ namespace Server.Multis
|
|||
public class LockableBarrel : LockableContainer
|
||||
{
|
||||
[Constructible]
|
||||
public LockableBarrel() : base(0xE77)
|
||||
{
|
||||
Weight = 1.0;
|
||||
}
|
||||
public LockableBarrel() : base(0xE77) => Weight = 1.0;
|
||||
|
||||
public LockableBarrel(Serial serial) : base(serial)
|
||||
{
|
||||
|
|
|
|||
|
|
@ -32,20 +32,11 @@ namespace Server.Multis
|
|||
LoadMultis("Data/Components/stairs.txt", "MultiNorth", "MultiEast", "MultiSouth", "MultiWest");
|
||||
}
|
||||
|
||||
public bool IsItemValid(int itemID)
|
||||
{
|
||||
return itemID > 0 && itemID < m_ItemTable.Length && CheckValidity(m_ItemTable[itemID]);
|
||||
}
|
||||
public bool IsItemValid(int itemID) => itemID > 0 && itemID < m_ItemTable.Length && CheckValidity(m_ItemTable[itemID]);
|
||||
|
||||
public bool IsMultiValid(int multiID)
|
||||
{
|
||||
return multiID > 0 && multiID < m_MultiTable.Length && CheckValidity(m_MultiTable[multiID]);
|
||||
}
|
||||
public bool IsMultiValid(int multiID) => multiID > 0 && multiID < m_MultiTable.Length && CheckValidity(m_MultiTable[multiID]);
|
||||
|
||||
public bool CheckValidity(int val)
|
||||
{
|
||||
return val != -1 && (val == 0 || ((int)ExpansionInfo.CoreExpansion.CustomHousingFlag & val) != 0);
|
||||
}
|
||||
public bool CheckValidity(int val) => val != -1 && (val == 0 || ((int)ExpansionInfo.CoreExpansion.CustomHousingFlag & val) != 0);
|
||||
|
||||
private int[] CreateTable(int length)
|
||||
{
|
||||
|
|
@ -103,48 +94,46 @@ namespace Server.Multis
|
|||
|
||||
public Spreadsheet(string path)
|
||||
{
|
||||
using (StreamReader ip = new StreamReader(path))
|
||||
{
|
||||
string[] types = ReadLine(ip);
|
||||
string[] names = ReadLine(ip);
|
||||
using StreamReader ip = new StreamReader(path);
|
||||
string[] types = ReadLine(ip);
|
||||
string[] names = ReadLine(ip);
|
||||
|
||||
m_Columns = new ColumnInfo[types.Length];
|
||||
m_Columns = new ColumnInfo[types.Length];
|
||||
|
||||
for (int i = 0; i < m_Columns.Length; ++i)
|
||||
m_Columns[i] = new ColumnInfo(i, types[i], names[i]);
|
||||
|
||||
List<DataRecord> records = new List<DataRecord>();
|
||||
|
||||
string[] values;
|
||||
|
||||
while ((values = ReadLine(ip)) != null)
|
||||
{
|
||||
object[] data = new object[m_Columns.Length];
|
||||
|
||||
for (int i = 0; i < m_Columns.Length; ++i)
|
||||
m_Columns[i] = new ColumnInfo(i, types[i], names[i]);
|
||||
|
||||
List<DataRecord> records = new List<DataRecord>();
|
||||
|
||||
string[] values;
|
||||
|
||||
while ((values = ReadLine(ip)) != null)
|
||||
{
|
||||
object[] data = new object[m_Columns.Length];
|
||||
ColumnInfo ci = m_Columns[i];
|
||||
|
||||
for (int i = 0; i < m_Columns.Length; ++i)
|
||||
switch (ci.m_Type)
|
||||
{
|
||||
ColumnInfo ci = m_Columns[i];
|
||||
|
||||
switch (ci.m_Type)
|
||||
case "int":
|
||||
{
|
||||
case "int":
|
||||
{
|
||||
data[i] = Utility.ToInt32(values[ci.m_DataIndex]);
|
||||
break;
|
||||
}
|
||||
case "string":
|
||||
{
|
||||
data[i] = values[ci.m_DataIndex];
|
||||
break;
|
||||
}
|
||||
data[i] = Utility.ToInt32(values[ci.m_DataIndex]);
|
||||
break;
|
||||
}
|
||||
case "string":
|
||||
{
|
||||
data[i] = values[ci.m_DataIndex];
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
records.Add(new DataRecord(this, data));
|
||||
}
|
||||
|
||||
Records = records.ToArray();
|
||||
records.Add(new DataRecord(this, data));
|
||||
}
|
||||
|
||||
Records = records.ToArray();
|
||||
}
|
||||
|
||||
public DataRecord[] Records{ get; }
|
||||
|
|
@ -204,24 +193,12 @@ namespace Server.Multis
|
|||
|
||||
public object this[int id] => id < 0 ? null : Data[id];
|
||||
|
||||
public int GetInt32(string name)
|
||||
{
|
||||
return GetInt32(this[name]);
|
||||
}
|
||||
public int GetInt32(string name) => GetInt32(this[name]);
|
||||
|
||||
public int GetInt32(int id)
|
||||
{
|
||||
return GetInt32(this[id]);
|
||||
}
|
||||
public int GetInt32(int id) => GetInt32(this[id]);
|
||||
|
||||
public int GetInt32(object obj)
|
||||
{
|
||||
return Convert.ToInt32(obj);
|
||||
}
|
||||
public int GetInt32(object obj) => Convert.ToInt32(obj);
|
||||
|
||||
public string GetString(string name)
|
||||
{
|
||||
return this[name] as string;
|
||||
}
|
||||
public string GetString(string name) => this[name] as string;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -8,10 +8,7 @@ namespace Server.Multis.Deeds
|
|||
{
|
||||
private HouseDeed m_Deed;
|
||||
|
||||
public HousePlacementTarget(HouseDeed deed) : base(deed.MultiID, deed.Offset)
|
||||
{
|
||||
m_Deed = deed;
|
||||
}
|
||||
public HousePlacementTarget(HouseDeed deed) : base(deed.MultiID, deed.Offset) => m_Deed = deed;
|
||||
|
||||
protected override void OnTarget(Mobile from, object o)
|
||||
{
|
||||
|
|
@ -211,10 +208,7 @@ namespace Server.Multis.Deeds
|
|||
public override int LabelNumber => 1041211;
|
||||
public override Rectangle2D[] Area => SmallOldHouse.AreaArray;
|
||||
|
||||
public override BaseHouse GetHouse(Mobile owner)
|
||||
{
|
||||
return new SmallOldHouse(owner, 0x64);
|
||||
}
|
||||
public override BaseHouse GetHouse(Mobile owner) => new SmallOldHouse(owner, 0x64);
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
|
|
@ -245,10 +239,7 @@ namespace Server.Multis.Deeds
|
|||
public override int LabelNumber => 1041212;
|
||||
public override Rectangle2D[] Area => SmallOldHouse.AreaArray;
|
||||
|
||||
public override BaseHouse GetHouse(Mobile owner)
|
||||
{
|
||||
return new SmallOldHouse(owner, 0x66);
|
||||
}
|
||||
public override BaseHouse GetHouse(Mobile owner) => new SmallOldHouse(owner, 0x66);
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
|
|
@ -279,10 +270,7 @@ namespace Server.Multis.Deeds
|
|||
public override int LabelNumber => 1041213;
|
||||
public override Rectangle2D[] Area => SmallOldHouse.AreaArray;
|
||||
|
||||
public override BaseHouse GetHouse(Mobile owner)
|
||||
{
|
||||
return new SmallOldHouse(owner, 0x68);
|
||||
}
|
||||
public override BaseHouse GetHouse(Mobile owner) => new SmallOldHouse(owner, 0x68);
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
|
|
@ -313,10 +301,7 @@ namespace Server.Multis.Deeds
|
|||
public override int LabelNumber => 1041214;
|
||||
public override Rectangle2D[] Area => SmallOldHouse.AreaArray;
|
||||
|
||||
public override BaseHouse GetHouse(Mobile owner)
|
||||
{
|
||||
return new SmallOldHouse(owner, 0x6A);
|
||||
}
|
||||
public override BaseHouse GetHouse(Mobile owner) => new SmallOldHouse(owner, 0x6A);
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
|
|
@ -347,10 +332,7 @@ namespace Server.Multis.Deeds
|
|||
public override int LabelNumber => 1041215;
|
||||
public override Rectangle2D[] Area => SmallOldHouse.AreaArray;
|
||||
|
||||
public override BaseHouse GetHouse(Mobile owner)
|
||||
{
|
||||
return new SmallOldHouse(owner, 0x6C);
|
||||
}
|
||||
public override BaseHouse GetHouse(Mobile owner) => new SmallOldHouse(owner, 0x6C);
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
|
|
@ -381,10 +363,7 @@ namespace Server.Multis.Deeds
|
|||
public override int LabelNumber => 1041216;
|
||||
public override Rectangle2D[] Area => SmallOldHouse.AreaArray;
|
||||
|
||||
public override BaseHouse GetHouse(Mobile owner)
|
||||
{
|
||||
return new SmallOldHouse(owner, 0x6E);
|
||||
}
|
||||
public override BaseHouse GetHouse(Mobile owner) => new SmallOldHouse(owner, 0x6E);
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
|
|
@ -415,10 +394,7 @@ namespace Server.Multis.Deeds
|
|||
public override int LabelNumber => 1041219;
|
||||
public override Rectangle2D[] Area => GuildHouse.AreaArray;
|
||||
|
||||
public override BaseHouse GetHouse(Mobile owner)
|
||||
{
|
||||
return new GuildHouse(owner);
|
||||
}
|
||||
public override BaseHouse GetHouse(Mobile owner) => new GuildHouse(owner);
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
|
|
@ -449,10 +425,7 @@ namespace Server.Multis.Deeds
|
|||
public override int LabelNumber => 1041220;
|
||||
public override Rectangle2D[] Area => TwoStoryHouse.AreaArray;
|
||||
|
||||
public override BaseHouse GetHouse(Mobile owner)
|
||||
{
|
||||
return new TwoStoryHouse(owner, 0x76);
|
||||
}
|
||||
public override BaseHouse GetHouse(Mobile owner) => new TwoStoryHouse(owner, 0x76);
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
|
|
@ -483,10 +456,7 @@ namespace Server.Multis.Deeds
|
|||
public override int LabelNumber => 1041221;
|
||||
public override Rectangle2D[] Area => TwoStoryHouse.AreaArray;
|
||||
|
||||
public override BaseHouse GetHouse(Mobile owner)
|
||||
{
|
||||
return new TwoStoryHouse(owner, 0x78);
|
||||
}
|
||||
public override BaseHouse GetHouse(Mobile owner) => new TwoStoryHouse(owner, 0x78);
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
|
|
@ -517,10 +487,7 @@ namespace Server.Multis.Deeds
|
|||
public override int LabelNumber => 1041222;
|
||||
public override Rectangle2D[] Area => Tower.AreaArray;
|
||||
|
||||
public override BaseHouse GetHouse(Mobile owner)
|
||||
{
|
||||
return new Tower(owner);
|
||||
}
|
||||
public override BaseHouse GetHouse(Mobile owner) => new Tower(owner);
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
|
|
@ -551,10 +518,7 @@ namespace Server.Multis.Deeds
|
|||
public override int LabelNumber => 1041223;
|
||||
public override Rectangle2D[] Area => Keep.AreaArray;
|
||||
|
||||
public override BaseHouse GetHouse(Mobile owner)
|
||||
{
|
||||
return new Keep(owner);
|
||||
}
|
||||
public override BaseHouse GetHouse(Mobile owner) => new Keep(owner);
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
|
|
@ -585,10 +549,7 @@ namespace Server.Multis.Deeds
|
|||
public override int LabelNumber => 1041224;
|
||||
public override Rectangle2D[] Area => Castle.AreaArray;
|
||||
|
||||
public override BaseHouse GetHouse(Mobile owner)
|
||||
{
|
||||
return new Castle(owner);
|
||||
}
|
||||
public override BaseHouse GetHouse(Mobile owner) => new Castle(owner);
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
|
|
@ -619,10 +580,7 @@ namespace Server.Multis.Deeds
|
|||
public override int LabelNumber => 1041231;
|
||||
public override Rectangle2D[] Area => LargePatioHouse.AreaArray;
|
||||
|
||||
public override BaseHouse GetHouse(Mobile owner)
|
||||
{
|
||||
return new LargePatioHouse(owner);
|
||||
}
|
||||
public override BaseHouse GetHouse(Mobile owner) => new LargePatioHouse(owner);
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
|
|
@ -653,10 +611,7 @@ namespace Server.Multis.Deeds
|
|||
public override int LabelNumber => 1041236;
|
||||
public override Rectangle2D[] Area => LargeMarbleHouse.AreaArray;
|
||||
|
||||
public override BaseHouse GetHouse(Mobile owner)
|
||||
{
|
||||
return new LargeMarbleHouse(owner);
|
||||
}
|
||||
public override BaseHouse GetHouse(Mobile owner) => new LargeMarbleHouse(owner);
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
|
|
@ -687,10 +642,7 @@ namespace Server.Multis.Deeds
|
|||
public override int LabelNumber => 1041237;
|
||||
public override Rectangle2D[] Area => SmallTower.AreaArray;
|
||||
|
||||
public override BaseHouse GetHouse(Mobile owner)
|
||||
{
|
||||
return new SmallTower(owner);
|
||||
}
|
||||
public override BaseHouse GetHouse(Mobile owner) => new SmallTower(owner);
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
|
|
@ -721,10 +673,7 @@ namespace Server.Multis.Deeds
|
|||
public override int LabelNumber => 1041238;
|
||||
public override Rectangle2D[] Area => LogCabin.AreaArray;
|
||||
|
||||
public override BaseHouse GetHouse(Mobile owner)
|
||||
{
|
||||
return new LogCabin(owner);
|
||||
}
|
||||
public override BaseHouse GetHouse(Mobile owner) => new LogCabin(owner);
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
|
|
@ -755,10 +704,7 @@ namespace Server.Multis.Deeds
|
|||
public override int LabelNumber => 1041239;
|
||||
public override Rectangle2D[] Area => SandStonePatio.AreaArray;
|
||||
|
||||
public override BaseHouse GetHouse(Mobile owner)
|
||||
{
|
||||
return new SandStonePatio(owner);
|
||||
}
|
||||
public override BaseHouse GetHouse(Mobile owner) => new SandStonePatio(owner);
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
|
|
@ -789,10 +735,7 @@ namespace Server.Multis.Deeds
|
|||
public override int LabelNumber => 1041240;
|
||||
public override Rectangle2D[] Area => TwoStoryVilla.AreaArray;
|
||||
|
||||
public override BaseHouse GetHouse(Mobile owner)
|
||||
{
|
||||
return new TwoStoryVilla(owner);
|
||||
}
|
||||
public override BaseHouse GetHouse(Mobile owner) => new TwoStoryVilla(owner);
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
|
|
@ -823,10 +766,7 @@ namespace Server.Multis.Deeds
|
|||
public override int LabelNumber => 1041241;
|
||||
public override Rectangle2D[] Area => SmallShop.AreaArray2;
|
||||
|
||||
public override BaseHouse GetHouse(Mobile owner)
|
||||
{
|
||||
return new SmallShop(owner, 0xA0);
|
||||
}
|
||||
public override BaseHouse GetHouse(Mobile owner) => new SmallShop(owner, 0xA0);
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
|
|
@ -857,10 +797,7 @@ namespace Server.Multis.Deeds
|
|||
public override int LabelNumber => 1041242;
|
||||
public override Rectangle2D[] Area => SmallShop.AreaArray1;
|
||||
|
||||
public override BaseHouse GetHouse(Mobile owner)
|
||||
{
|
||||
return new SmallShop(owner, 0xA2);
|
||||
}
|
||||
public override BaseHouse GetHouse(Mobile owner) => new SmallShop(owner, 0xA2);
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
|
|
|
|||
|
|
@ -26,10 +26,7 @@ namespace Server.Multis
|
|||
m_Stages[level] = new DecayStageInfo(min, max);
|
||||
}
|
||||
|
||||
public static bool Decays(DecayLevel level)
|
||||
{
|
||||
return m_Stages.ContainsKey(level);
|
||||
}
|
||||
public static bool Decays(DecayLevel level) => m_Stages.ContainsKey(level);
|
||||
|
||||
public static TimeSpan GetRandomDuration(DecayLevel level)
|
||||
{
|
||||
|
|
|
|||
|
|
@ -190,15 +190,9 @@ namespace Server.Multis
|
|||
|
||||
public static ComponentVerification Verification => m_Verification ?? (m_Verification = new ComponentVerification());
|
||||
|
||||
public bool IsFixture(Item item)
|
||||
{
|
||||
return Fixtures.Contains(item);
|
||||
}
|
||||
public bool IsFixture(Item item) => Fixtures.Contains(item);
|
||||
|
||||
public override int GetMaxUpdateRange()
|
||||
{
|
||||
return 24;
|
||||
}
|
||||
public override int GetMaxUpdateRange() => 24;
|
||||
|
||||
public override int GetUpdateRange(Mobile m)
|
||||
{
|
||||
|
|
@ -633,13 +627,7 @@ namespace Server.Multis
|
|||
}
|
||||
}
|
||||
|
||||
private static DoorFacing GetSADoorFacing(int offset)
|
||||
{
|
||||
/* Offset 0 2 4 6
|
||||
* DoorFacing 2 3 6 7
|
||||
*/
|
||||
return (DoorFacing)((offset / 2 + 2 * (1 + offset / 4)) % 8);
|
||||
}
|
||||
private static DoorFacing GetSADoorFacing(int offset) => (DoorFacing)((offset / 2 + 2 * (1 + offset / 4)) % 8);
|
||||
|
||||
public void AddFixture(Item item, MultiTileEntry mte)
|
||||
{
|
||||
|
|
@ -932,10 +920,7 @@ namespace Server.Multis
|
|||
base.Deserialize(reader);
|
||||
}
|
||||
|
||||
public bool IsHiddenToCustomizer(Item item)
|
||||
{
|
||||
return item == Signpost || item == SignHanger || item == Sign || IsFixture(item);
|
||||
}
|
||||
public bool IsHiddenToCustomizer(Item item) => item == Signpost || item == SignHanger || item == Sign || IsFixture(item);
|
||||
|
||||
public static void Initialize()
|
||||
{
|
||||
|
|
@ -1525,10 +1510,8 @@ namespace Server.Multis
|
|||
{
|
||||
try
|
||||
{
|
||||
using (StreamWriter op = new StreamWriter("comp_val.log", true))
|
||||
{
|
||||
op.WriteLine("{0}\t{1}\tInvalid ItemID 0x{2:X4}", state, state.Mobile, itemID);
|
||||
}
|
||||
using StreamWriter op = new StreamWriter("comp_val.log", true);
|
||||
op.WriteLine("{0}\t{1}\tInvalid ItemID 0x{2:X4}", state, state.Mobile, itemID);
|
||||
}
|
||||
catch
|
||||
{
|
||||
|
|
@ -2519,10 +2502,8 @@ namespace Server.Multis
|
|||
|
||||
try
|
||||
{
|
||||
using (StreamWriter op = new StreamWriter("dsd_exceptions.txt", true))
|
||||
{
|
||||
op.WriteLine(e);
|
||||
}
|
||||
using StreamWriter op = new StreamWriter("dsd_exceptions.txt", true);
|
||||
op.WriteLine(e);
|
||||
}
|
||||
catch
|
||||
{
|
||||
|
|
|
|||
|
|
@ -38,10 +38,7 @@ namespace Server.Multis
|
|||
|
||||
public bool GettingProperties{ get; private set; }
|
||||
|
||||
public string GetName()
|
||||
{
|
||||
return Name ?? "An Unnamed House";
|
||||
}
|
||||
public string GetName() => Name ?? "An Unnamed House";
|
||||
|
||||
public override void OnAfterDelete()
|
||||
{
|
||||
|
|
@ -228,10 +225,7 @@ namespace Server.Multis
|
|||
{
|
||||
private HouseSign m_Sign;
|
||||
|
||||
public VendorsEntry(HouseSign sign) : base(6211)
|
||||
{
|
||||
m_Sign = sign;
|
||||
}
|
||||
public VendorsEntry(HouseSign sign) : base(6211) => m_Sign = sign;
|
||||
|
||||
public override void OnClick()
|
||||
{
|
||||
|
|
@ -253,10 +247,7 @@ namespace Server.Multis
|
|||
{
|
||||
private HouseSign m_Sign;
|
||||
|
||||
public ReclaimVendorInventoryEntry(HouseSign sign) : base(6213)
|
||||
{
|
||||
m_Sign = sign;
|
||||
}
|
||||
public ReclaimVendorInventoryEntry(HouseSign sign) : base(6213) => m_Sign = sign;
|
||||
|
||||
public override void OnClick()
|
||||
{
|
||||
|
|
|
|||
|
|
@ -83,10 +83,7 @@ namespace Server.Multis
|
|||
public override Rectangle2D[] Area => AreaArray;
|
||||
public override Point3D BaseBanLocation => new Point3D(4, 8, 0);
|
||||
|
||||
public override HouseDeed GetDeed()
|
||||
{
|
||||
return new BrickHouseDeed();
|
||||
}
|
||||
public override HouseDeed GetDeed() => new BrickHouseDeed();
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
|
|
@ -183,10 +180,7 @@ namespace Server.Multis
|
|||
public override Rectangle2D[] Area => AreaArray;
|
||||
public override Point3D BaseBanLocation => new Point3D(5, 8, 0);
|
||||
|
||||
public override HouseDeed GetDeed()
|
||||
{
|
||||
return new TowerDeed();
|
||||
}
|
||||
public override HouseDeed GetDeed() => new TowerDeed();
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
|
|
@ -228,10 +222,7 @@ namespace Server.Multis
|
|||
public override Rectangle2D[] Area => AreaArray;
|
||||
public override Point3D BaseBanLocation => new Point3D(5, 13, 0);
|
||||
|
||||
public override HouseDeed GetDeed()
|
||||
{
|
||||
return new KeepDeed();
|
||||
}
|
||||
public override HouseDeed GetDeed() => new KeepDeed();
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
|
|
@ -272,10 +263,7 @@ namespace Server.Multis
|
|||
public override Rectangle2D[] Area => AreaArray;
|
||||
public override Point3D BaseBanLocation => new Point3D(5, 17, 0);
|
||||
|
||||
public override HouseDeed GetDeed()
|
||||
{
|
||||
return new CastleDeed();
|
||||
}
|
||||
public override HouseDeed GetDeed() => new CastleDeed();
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
|
|
@ -319,10 +307,7 @@ namespace Server.Multis
|
|||
public override Rectangle2D[] Area => AreaArray;
|
||||
public override Point3D BaseBanLocation => new Point3D(1, 8, 0);
|
||||
|
||||
public override HouseDeed GetDeed()
|
||||
{
|
||||
return new LargePatioDeed();
|
||||
}
|
||||
public override HouseDeed GetDeed() => new LargePatioDeed();
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
|
|
@ -362,10 +347,7 @@ namespace Server.Multis
|
|||
public override Rectangle2D[] Area => AreaArray;
|
||||
public override Point3D BaseBanLocation => new Point3D(1, 8, 0);
|
||||
|
||||
public override HouseDeed GetDeed()
|
||||
{
|
||||
return new LargeMarbleDeed();
|
||||
}
|
||||
public override HouseDeed GetDeed() => new LargeMarbleDeed();
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
|
|
@ -404,10 +386,7 @@ namespace Server.Multis
|
|||
public override Rectangle2D[] Area => AreaArray;
|
||||
public override Point3D BaseBanLocation => new Point3D(1, 4, 0);
|
||||
|
||||
public override HouseDeed GetDeed()
|
||||
{
|
||||
return new SmallTowerDeed();
|
||||
}
|
||||
public override HouseDeed GetDeed() => new SmallTowerDeed();
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
|
|
@ -448,10 +427,7 @@ namespace Server.Multis
|
|||
public override Rectangle2D[] Area => AreaArray;
|
||||
public override Point3D BaseBanLocation => new Point3D(5, 8, 0);
|
||||
|
||||
public override HouseDeed GetDeed()
|
||||
{
|
||||
return new LogCabinDeed();
|
||||
}
|
||||
public override HouseDeed GetDeed() => new LogCabinDeed();
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
|
|
@ -491,10 +467,7 @@ namespace Server.Multis
|
|||
public override Rectangle2D[] Area => AreaArray;
|
||||
public override Point3D BaseBanLocation => new Point3D(4, 6, 0);
|
||||
|
||||
public override HouseDeed GetDeed()
|
||||
{
|
||||
return new SandstonePatioDeed();
|
||||
}
|
||||
public override HouseDeed GetDeed() => new SandstonePatioDeed();
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
|
|
@ -536,10 +509,7 @@ namespace Server.Multis
|
|||
public override Rectangle2D[] Area => AreaArray;
|
||||
public override Point3D BaseBanLocation => new Point3D(3, 8, 0);
|
||||
|
||||
public override HouseDeed GetDeed()
|
||||
{
|
||||
return new VillaDeed();
|
||||
}
|
||||
public override HouseDeed GetDeed() => new VillaDeed();
|
||||
|
||||
public override void Serialize(GenericWriter writer)
|
||||
{
|
||||
|
|
|
|||
|
|
@ -139,15 +139,9 @@ namespace Server.Multis
|
|||
return base.CheckHold(m, item, message, checkItems, plusItems, plusWeight);
|
||||
}
|
||||
|
||||
public override bool CheckLift(Mobile from, Item item, ref LRReason reject)
|
||||
{
|
||||
return House?.Deleted == false && base.CheckLift(from, item, ref reject) && House.IsOwner(from);
|
||||
}
|
||||
public override bool CheckLift(Mobile from, Item item, ref LRReason reject) => House?.Deleted == false && base.CheckLift(from, item, ref reject) && House.IsOwner(from);
|
||||
|
||||
public override bool CheckItemUse(Mobile from, Item item)
|
||||
{
|
||||
return House?.Deleted == false && base.CheckItemUse(from, item) && House.IsOwner(from);
|
||||
}
|
||||
public override bool CheckItemUse(Mobile from, Item item) => House?.Deleted == false && base.CheckItemUse(from, item) && House.IsOwner(from);
|
||||
|
||||
public override void OnItemRemoved(Item item)
|
||||
{
|
||||
|
|
@ -254,10 +248,7 @@ namespace Server.Multis
|
|||
|
||||
public class PackingBox : BaseContainer
|
||||
{
|
||||
public PackingBox() : base(0x9A8)
|
||||
{
|
||||
Movable = false;
|
||||
}
|
||||
public PackingBox() : base(0x9A8) => Movable = false;
|
||||
|
||||
public PackingBox(Serial serial) : base(serial)
|
||||
{
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue