private void addAttackers(int color, int target, int excludedSquare) {

        // This function pushes the attackers found on top of the stack in MV (Move-value) order:
        // e.g. king -> queens -> rooks and so on so we do NOT have to worry about AttackerStacks
        // pushIntoPlace() until we begin to add hidden attackers. 

        int[] squares = board.getPiecesInMVOrder(color);
        int square;

        for (int index = 0; (square = squares[index]) != Square.NONE; index++) {

            if (square == excludedSquare) {
                continue;
            }

            int inc, next;
            int piece = Square.getPiece(board.squares[square]);

            if ((inc = Increment.getPieceIncrement(piece, square - target)) != 0) {
                for (next = square + inc; Square.isEmpty(board.squares[next]); next += inc) ;
                if (next == target) {
                    //System.out.printf("[added] piece: %s | square: %s (%d) | color: %s | inc: %d\n",
                    //        Piece.getPieceName(piece), Square.getSquareName(square), square, (color == WHITE ? "W" : "B"), inc);
                    stacks[color].push(square);
                }
            }

        }

        // Pawns

        int[] incs = (color == BLACK ? new int[]{NW, NE} : new int[]{SE, SW});
        for (int inc : incs) {
            square = target + inc;

            if (square == excludedSquare) {
                continue;
            }

            if (Square.isPieceAndColor(board.squares[square], PAWN, color)) {
                assert !Square.isBorder(board.squares[square]);
                //System.out.printf("[pawn ] piece: p | square: %s (%d) | color: %s\n", Square.getSquareName(square), square, (color == WHITE ? "W" : "B"));
                stacks[color].push(square);
            }
        }
    }