So basically, I'm working on a console based game in C#. I'm to the point where I'm ready to save the data. I want all the data saved into one file, if possible. I don't wan't something like XML Serialization, where the player can just go in and give himself a million gold.
What should I use? Here's the things I need to serialize:
GameWorld
Inventory
Player
List<Item>
Point
List<String>
Here's the variables that are in the classes:
public class GameWorld
{
Dictionary<Point, Room>
}
public class Item
{
String Creator
String Verb
String RequiredItem
Action OnActivate
int Difficulty
Action OnDefeatEnemy
Action OnDefeatedByEnemy
}
public class Room
{
String Title
String Description
List<Item> Items
List<String> ItemNames
String Creator
}
public class Inventory
{
List<Items>
}
public enum ActionType
{
ACQUIRE_GOLD, DECREASE_HEALTH, INCREASE_HEALTH, DECREASE_STRENGTH, INCREASE_STRENGTH, GET_ITEM, PRINT_MESSAGE
}
public class Action
{
ActionType actionType
int Amount
String GiveItem
String Message
String Creator
bool SingleActivation
bool HasActivated
}