MudEngine:

- FileManager.GetData() method now checks to ensure that the supplied filename exists prior to attempting to reading data.
 - Adjusted Game.AutoSaveInterval to 60 minutes instead of 1 minute.
 - Placed all of the File reading code within Game.Load() into a Try/Catch to prevent exceptions if there was an error restoring the game from saved state.
 - GameWorld.Load() now places saved Realms that were created at runtime into the Games Realm Collection. This allows for hard-coded and dynamically created Realms to co-exist.
 - BaseObject.Filename now appends a file extension to the filename if a filename is set but the user forgets to add the file extension. This affects all classes inheriting from BaseObject
 - BaseCharacter updated to invoke commands by instancing a copy of the command and executing it, instead of injecting commands from the player.
 - Added EditRealm command. Allows for editing existing Realms properties. Currently has editing of Simple Descriptions, Detailed Descriptions, name and filename fully implemented.
     Example: EditRealm MyRealmName

MudGame:
 - Removed Cali.Create() call. The MudGame no longer creates a hard-coded world. I want to get away from hard-coded environments all together. They should be built dynamically by admins.
This commit is contained in:
Scionwest_cp 2010-09-05 00:49:37 -07:00
parent abe11a5fd5
commit 9313611784
8 changed files with 610 additions and 32 deletions

View file

@ -53,9 +53,33 @@ namespace MudEngine.GameObjects
{
//Returns the name of the object + the objects Type as it's extension.
//Filenames are generated by the class itself, users can not assign it.
get;
set;
get
{
return _Filename;
}
set
{
if (this.GetType().Name.StartsWith("Base"))
{
if (value.EndsWith("." + this.GetType().Name.Substring("Base".Length)))
{
_Filename = value;
}
else
_Filename = value + "." + this.GetType().Name.Substring("Base".Length);
}
else
{
if (value.EndsWith("." + this.GetType().Name))
{
_Filename = value;
}
else
_Filename =value + "." + this.GetType().Name;
}
}
}
String _Filename;
[Category("Environment Information")]
[Description("If a user asks to use his/her senses to investigate an area, this is one of the results that will be displayed. Senses can be used to assist blind characters.")]