public MainViewModel(IBotsManager botsManager) { _botsManager = botsManager; _ai = new BackgroundWorker(); _ai.WorkerSupportsCancellation = true; _ai.DoWork += AiDoWork; Game = new GameModel(); NewGame = new Command(NewGameExecute, NewGameCanExecute); MoveLeft = new Command(MoveLeftExecute); MoveRight = new Command(MoveRightExecute); MoveUp = new Command(MoveUpExecute); MoveDown = new Command(MoveDownExecute); }