Beispiel #1
0
        public void Load(SavedGameInfo savedGameData, IEnumerable <NamedStream> staticDataSources)
        {
            if (savedGameData == null)
            {
                throw new ArgumentNullException(nameof(savedGameData));
            }

            IkonComposite saveRawData;

            using (var parser = new IkonParser(savedGameData.FileInfo.OpenText()))
                saveRawData = parser.ParseAll().Dequeue(MainGame.SaveGameTag).To <IkonComposite>();

            this.gameController.LoadGame(GameBuilder.LoadGame(saveRawData, staticDataSources, GameController.GetStateManager()));
        }
Beispiel #2
0
        public void Load(SavedGameInfo savedGameData, IEnumerable <TracableStream> staticDataSources)
        {
            IkonComposite saveRawData;

            using (var parser = new IkonParser(savedGameData.FileInfo.OpenText()))
                saveRawData = parser.ParseAll().Dequeue(MainGame.SaveGameTag).To <IkonComposite>();

            this.gameController.LoadGame(GameBuilder.LoadGame(saveRawData, staticDataSources, GameController.GetStateManager()));
        }