public static AIProject.SaveData.SaveData LoadFile(string fileName) { AIProject.SaveData.SaveData saveData = new AIProject.SaveData.SaveData(); if (!saveData.Load(fileName)) { return((AIProject.SaveData.SaveData)null); } saveData.ComplementDiff(); return(saveData); }
public void Copy(AIProject.SaveData.SaveData source) { if (source.AutoData != null) { this.AutoData = new WorldData(); this.AutoData.Copy(source.AutoData); } foreach (KeyValuePair <int, WorldData> world in source.WorldList) { WorldData worldData = new WorldData(); worldData.Copy(world.Value); this.WorldList[world.Key] = worldData; } }