Changes properties to use automatic property initializers

This commit is contained in:
Kamron Batman 2018-09-14 15:23:29 -07:00
parent f0a48ad431
commit 06fa31a7bf
623 changed files with 13072 additions and 19304 deletions

View file

@ -9,14 +9,8 @@ namespace Server.Items
{
public abstract class BaseBoard : Container, ISecurable
{
private SecureLevel m_Level;
[CommandProperty( AccessLevel.GameMaster )]
public SecureLevel Level
{
get => m_Level;
set => m_Level = value;
}
public SecureLevel Level { get; set; }
public BaseBoard( int itemID ) : base( itemID )
{
@ -57,7 +51,7 @@ namespace Server.Items
base.Serialize( writer );
writer.Write( (int) 1 ); // version
writer.Write( (int)m_Level );
writer.Write( (int)Level );
}
public override void Deserialize( GenericReader reader )
@ -66,7 +60,7 @@ namespace Server.Items
int version = reader.ReadInt();
if ( version == 1 )
m_Level = (SecureLevel)reader.ReadInt();
Level = (SecureLevel)reader.ReadInt();
if ( Weight == 1.0 )
Weight = 5.0;