public static int evaluate(DraughtsState ds) {
         if (ds == null){
            throw new IllegalArgumentException("ds in evaluate");
        }
        int total = 0;

        // White or black has to move.
        boolean isWhite = ds.isWhiteToMove();
        // Possible moves.
//        int moves = ds.getMoves().size();

        for (int c = 0; c != 10; c++) {
            for (int r = 0; r != 10; r++) {
                total += addValue(r, c, ds);
            }
        }
        if (!isWhite) {
            total = -total;
        }
        return total;
    }