All of the classes that currently perform Save/Load operations now log when a Property failed to be loaded correctly.

This commit is contained in:
Scionwest_cp 2012-03-10 19:48:41 -08:00
parent 32210124e0
commit a6d346da3d
5 changed files with 28 additions and 49 deletions

View file

@ -74,11 +74,16 @@ namespace MudEngine.Game.Environment
try { this.Filename = this.SaveData.GetData("Filename"); }
catch { LoadFailedMessage("Filename"); }
this.Enabled = Convert.ToBoolean(this.SaveData.GetData("Enabled"));
try { this.Enabled = Convert.ToBoolean(this.SaveData.GetData("Enabled")); }
catch { this.LoadFailedMessage("Enabled");}
String role = this.SaveData.GetData("RequiredRole");
try
{
String role = this.SaveData.GetData("RequiredRole");
this.RequiredRole = CharacterRole.GetRole(role);
this.RequiredRole = CharacterRole.GetRole(role);
}
catch { this.LoadFailedMessage("RequiredRole"); }
}
public void Update()