public boolean searchForUpdate(int startIndex, int currentIndex, int offset, int player) {
        int nextIndex = currentIndex + offset;
        if (indexIsOutOfBounds(nextIndex) || boardArray[nextIndex] == OPEN) return false;
        else if (boardArray[nextIndex] == opponent(player)) {
            boolean update = searchForUpdate(startIndex, nextIndex, offset, player);
            if (update) {
                boardArray[nextIndex] = player;
                return true;
            }
        } else if (boardArray[nextIndex] == player && !adjacentMove(startIndex, offset, nextIndex))
            return true;
        return false;
    }