public ArrayList<Move> whiteUrgentMoves(ArrayList<Move> allWhiteMoves) {
        ArrayList<Move> rez = new ArrayList<Move>();

        // if black king isn't near any pieces, it can't eat them
        if (this.piecesNearPosition(this.piecePosition[28]).size() == 0) { return rez; }

        for (Move currMove : allWhiteMoves) {
            int from = Utils.getStartingPositionFromMoveNumber(currMove.moveNumber);
            int to = Utils.getTargetPositionFromMoveNumber(currMove.moveNumber);
            int movedPiece = Utils.getMovedPieceFromMoveNumber(currMove.moveNumber);

            if (movedPiece == 4) {
                for (int piecesAroundBlackKing : this.piecesNearPosition(this.piecePosition[28])) {
                    if (!ChessboardUtils.arePositionsAdjacent(from, this.piecePosition[piecesAroundBlackKing])
                            && ChessboardUtils.arePositionsAdjacent(to, this.piecePosition[piecesAroundBlackKing])) {
                        rez.add(currMove);
                    }
                }
            }
            else if (!ChessboardUtils.arePositionsAdjacent(from, this.piecePosition[4]) && ChessboardUtils.arePositionsAdjacent(from, this.piecePosition[28])
                    && !ChessboardUtils.arePositionsAdjacent(to, this.piecePosition[28])) {
                rez.add(currMove);
            }
        }

        return rez;
    }