List<ChessMove> get moves { if (_moves == null) { _moves = getValidMoves(lastMove, currentPlayer, board, availableCastling); } return [..._moves!]; }