Adds style cop (#109)

This commit is contained in:
Kamron Batman 2020-04-26 00:16:02 -07:00 • committed by GitHub
parent 3e715bcb60
commit 556a17aba8
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
1725 changed files with 33831 additions and 38046 deletions

View file

@ -38,7 +38,7 @@ namespace Server.Engines.BulkOrders
}
[CommandProperty(AccessLevel.GameMaster)]
public Type Type{ get; set; }
public Type Type { get; set; }
[CommandProperty(AccessLevel.GameMaster)]
public int Number
@ -52,7 +52,7 @@ namespace Server.Engines.BulkOrders
}
[CommandProperty(AccessLevel.GameMaster)]
public int Graphic{ get; set; }
public int Graphic { get; set; }
[CommandProperty(AccessLevel.GameMaster)]
public override bool Complete => m_AmountCur == AmountMax;
@ -121,8 +121,8 @@ namespace Server.Engines.BulkOrders
from.SendLocalizedMessage(
1045166); // The maximum amount of requested items have already been combined to this deed.
}
else if (Type == null || objectType != Type && !objectType.IsSubclassOf(Type) ||
!(item is BaseWeapon) && !(item is BaseArmor) && !(item is BaseClothing))
else if (Type == null || (objectType != Type && !objectType.IsSubclassOf(Type)) ||
(!(item is BaseWeapon) && !(item is BaseArmor) && !(item is BaseClothing)))
{
from.SendLocalizedMessage(1045169); // The item is not in the request.
}
@ -194,18 +194,18 @@ namespace Server.Engines.BulkOrders
switch (version)
{
case 0:
{
m_AmountCur = reader.ReadInt();
{
m_AmountCur = reader.ReadInt();
string type = reader.ReadString();
string type = reader.ReadString();
if (type != null)
Type = AssemblyHandler.FindFirstTypeForName(type);
if (type != null)
Type = AssemblyHandler.FindFirstTypeForName(type);
m_Number = reader.ReadInt();
Graphic = reader.ReadInt();
break;
}
m_Number = reader.ReadInt();
Graphic = reader.ReadInt();
break;
}
}
}
}