Exemplo n.º 1
0
        public HexBoardViewModel(SelectGameViewModel gameData)
        {
            this.CanPlay   = true;
            this.BoardSize = gameData.SelectedBoardSize;

            this.hexGame = new HexGame(this.BoardSize);
            this.Populate();

            this.gameSummary = new GameSummary(this.hexGame, gameData.GameType);

            this.computerSkillLevel    = SkillLevelToDepth(gameData.SkillLevel);
            this.doComputerMoveCommand = new DoComputerMoveCommand(this.computerSkillLevel);
            this.CheckComputerMove();
        }
Exemplo n.º 2
0
        public HexBoardViewModel(SelectGameViewModel gameData)
        {
            this.CanPlay = true;
            this.BoardSize = gameData.SelectedBoardSize;

            this.hexGame = new HexGame(this.BoardSize);
            this.Populate();

            this.gameSummary = new GameSummary(this.hexGame, gameData.GameType);

            this.computerSkillLevel = SkillLevelToDepth(gameData.SkillLevel);
            this.doComputerMoveCommand = new DoComputerMoveCommand(this.computerSkillLevel);
            this.CheckComputerMove();
        }
Exemplo n.º 3
0
        public HexBoardViewModel(HexBoardViewModel original)
        {
            this.CanPlay   = true;
            this.BoardSize = original.BoardSize;

            this.hexGame = new HexGame(this.BoardSize);
            this.hexGame.Board.CopyStateFrom(original.hexGame.Board);

            this.Populate();
            this.CopyCellStates(original.Cells);

            this.gameSummary           = new GameSummary(this.hexGame, original.gameSummary.GameType);
            this.computerSkillLevel    = original.computerSkillLevel;
            this.doComputerMoveCommand = new DoComputerMoveCommand(this.computerSkillLevel);
        }
Exemplo n.º 4
0
        public HexBoardViewModel(HexBoardViewModel original)
        {
            this.CanPlay = true;
            this.BoardSize = original.BoardSize;

            this.hexGame = new HexGame(this.BoardSize);
            this.hexGame.Board.CopyStateFrom(original.hexGame.Board);

            this.Populate();
            this.CopyCellStates(original.Cells);

            this.gameSummary = new GameSummary(this.hexGame, original.gameSummary.GameType);
            this.computerSkillLevel = original.computerSkillLevel;
            this.doComputerMoveCommand = new DoComputerMoveCommand(this.computerSkillLevel);
        }