Esempio n. 1
0
        public Move getNextMove(ChessBitBoard board, Team team)
        {
            var chessMove = ai.GetNextMove(board.ToChessBoard(), team.ToChessColor());

            var srcy  = 7 - chessMove.From.Y;
            var desty = 7 - chessMove.To.Y;

            board.move(chessMove.From.X, srcy, chessMove.To.X, desty);
            var move = board.lastMove();

            board.rollBackMove();

            return(move);
        }
Esempio n. 2
0
 public bool isValidMove(ChessBitBoard board, Move move, Team team)
 {
     return(ai.IsValidMove(board.ToChessBoard(), move.ToChessMove(board, team), team.ToChessColor()));
 }