makePrettyMove method

bool makePrettyMove(
  1. Map<String, String> move
)

Attempt to make a move in the board if successfully made the move, return true and update the respective squares, otherwise return false.

Implementation

bool makePrettyMove(Map<String, String> move) {
  final builtMove = _buildPrettyMove(move);
  if (builtMove != null) {
    _makeMove(builtMove);
    _updateBoardAfterMove(builtMove);
    refreshBoard();
    return true;
  } else {
    return false;
  }
}