public WumpusGameLogic(WumpusSetting setting, IWumpusDataAccess dataAccess) { _dataAccess = dataAccess; Setting = setting; IsStarted = false; _isSaving = false; ShowFieldEnd = true; ShowFieldDebug = false; }
public WumpusViewModel(WumpusGameLogic gameLogic, IWumpusDataAccess dataAccess) { _dataAccess = dataAccess; _gameLogic = gameLogic; SetGameEventHandlers(); DiffIndex = 0; Info = "Játék indításához válassz nehézséget, és kattints a Játék kezdése gombra!"; OnPropertyChanged("Info"); IsShowEndChecked = true; IsShowFieldChecked = false; StartGameCommand = new DelegateCommand(o => StartGame()); //SaveGameCommand = new DelegateCommand(SavingGame); //LoadGameCommand = new DelegateCommand(LoadingGame); ExitGameCommand = new DelegateCommand(o => OnQuitEvent()); StepCommand = new DelegateCommand(o => Step((Direction)Convert.ToInt32(o))); ShootCommand = new DelegateCommand(o => ShootArrow()); GrabCommand = new DelegateCommand(o => GrabGold()); ShowEndCommand = new DelegateCommand(o => { IsShowEndChecked = !IsShowEndChecked; SetExtraSettings(); UpdateField(); }); ShowFieldCommand = new DelegateCommand(o => { IsShowFieldChecked = !IsShowFieldChecked; SetExtraSettings(); UpdateField(); }); }
public WumpusGameLogic(IWumpusDataAccess dataAccess) : this(Levels.GetSetting(0), dataAccess) { }