public Border findBorder(int locx, int locy, boolean opt) {
        int top = 0, left = 0, bottom = 0, right = 0;
        int val;

        if (opt) {
            val = newRun.getMazeVal(locx, locy);
        } else {
            val = newRun.getTravVal(locx, locy);
        }

        if ((val & 0x01) == 0x01) top = 5;
        if ((val & 0x02) == 0x02) right = 5;
        if ((val & 0x04) == 0x04) bottom = 5;
        if ((val & 0x08) == 0x08) left = 5;

        return BorderFactory.createMatteBorder(top, left, bottom, right, Color.black);
    }