public void Refresh() { foreach (var item in Game.EventLog.GetNewEvents(Auth)) { EventsDict.Add(new EventVM(item, _gameVM.CurrentFaction, _gameVM)); } }
public LogViewerVM(GameVM gameVM) { _gameVM = gameVM; if (Game != null && Auth != null) { foreach (var item in Game.EventLog.GetAllEvents(Auth)) { EventsDict.Add(new EventVM(item, _gameVM.CurrentFaction, _gameVM)); } } foreach (var kvp in gameVM.CurrentPlayer.HaltsOnEvent) { EventTypes.Add(new EventTypeBoolPair(gameVM.CurrentPlayer, kvp.Key)); } _gameVM.Game.GameLoop.GameGlobalDateChangedEvent += GameLoop_GameGlobalDateChangedEvent; }