Added rScript files to the engine. These have not been implemented and currently don't work with the engine. BaseScript has been modified to support the new XMLData class for saving data.
35 lines
834 B
C#
35 lines
834 B
C#
using System;
|
|
using System.Collections.Generic;
|
|
using System.Linq;
|
|
using System.Text;
|
|
using System.Xml.Linq;
|
|
using System.Reflection;
|
|
|
|
using MudEngine.GameScripts;
|
|
|
|
namespace MudEngine.DAL
|
|
{
|
|
public class XMLData
|
|
{
|
|
public XElement SaveData { get; private set; }
|
|
|
|
/// <summary>
|
|
/// Instances the ObjectSaver and all of its Properties and Fields
|
|
/// </summary>
|
|
public XMLData(String objectType)
|
|
{
|
|
SaveData = new XElement(objectType);
|
|
}
|
|
|
|
public void AddSaveData(String property, String value)
|
|
{
|
|
this.SaveData.Add(new XElement(property, value));
|
|
}
|
|
|
|
public Boolean Save(String filename)
|
|
{
|
|
this.SaveData.Save(filename);
|
|
return true;
|
|
}
|
|
}
|
|
}
|