Clean up: Bugs, LINQ, constructors, default values, and null checks (#18)

This commit is contained in:
Kamron Batman 2019-03-11 14:29:59 -07:00 committed by GitHub
parent e748af4430
commit 513e54f70e
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
1094 changed files with 15913 additions and 21892 deletions

View file

@ -10,12 +10,7 @@ namespace Server.Items
private int m_UsesRemaining;
[Constructible]
public FukiyaDarts() : this(1)
{
}
[Constructible]
public FukiyaDarts(int amount) : base(0x2806)
public FukiyaDarts(int amount = 1) : base(0x2806)
{
Weight = 1.0;
@ -116,4 +111,4 @@ namespace Server.Items
}
}
}
}
}

View file

@ -270,8 +270,7 @@ namespace Server.Items
{
Item item = weapon as Item;
if (!item.Deleted && item.RootParent == from) return true;
return false;
return !item.Deleted && item.RootParent == from;
}
public class LoadEntry : ContextMenuEntry

View file

@ -11,12 +11,7 @@ namespace Server.Items
private int m_UsesRemaining;
[Constructible]
public Shuriken() : this(1)
{
}
[Constructible]
public Shuriken(int amount) : base(0x27AC)
public Shuriken(int amount = 1) : base(0x27AC)
{
Weight = 1.0;
@ -117,4 +112,4 @@ namespace Server.Items
}
}
}
}
}