private NoteLengthEnum[] generateIrregularTimes(TimeSignatureEnum timeSignature, int maxTime, int speedPercent, Random r) {
        int beats = timeSignature.getBeats();
        NoteLengthEnum lastBeat = timeSignature.getOneBeat();
        NoteLengthEnum currBeat = null;
        double remaining = 1.0;
        ArrayList<NoteLengthEnum> times = new ArrayList<NoteLengthEnum>();

        int fasterChance = generateSpeedChangeChance(speedPercent, ACCELERATION);
        int slowerChance = generateSpeedChangeChance(speedPercent, DECELERATION);

        System.out.println("Speed chances: +" + fasterChance + "   -" + slowerChance);

        try{
            while (remaining > 0.0){
                int roll;
                if((roll = r.nextInt(Constants.PERCENT)) < fasterChance){
                    //TODO: Remove debug text
                    System.out.println("Attempt to accelerate with a roll of " + roll + " under " + fasterChance);
                    //attempt to speed up by a non-dotted type (ergo the 2)
                    currBeat = shiftNoteLength(lastBeat, remaining, 2);
                    if(currBeat != lastBeat){
                        System.out.println("      ...success");
                    }
                } else if((roll = r.nextInt(Constants.PERCENT)) < slowerChance) {
                    System.out.println("Attempt to decelerate with a roll of " + roll + " under " + slowerChance);
                    //attempt to slow down by a non-dotted type (ergo the 2)
                    currBeat = shiftNoteLength(lastBeat, remaining, -2);
                    if(currBeat != lastBeat){
                        System.out.println("      ...success");
                    }
                } else {
                    currBeat = lastBeat;
                }
                times.add(currBeat);
                System.out.println(currBeat);
                remaining -= currBeat.getRatio();
                lastBeat = currBeat;
            }
        } catch (NullPointerException e){
            System.err.println("currBeat was null with " + remaining + " remaining and the last beat as " + lastBeat);
            return generateRegularTimes(timeSignature);
        }

        NoteLengthEnum[] timesArray = new NoteLengthEnum[times.size()];
        times.toArray(timesArray);
        return timesArray;
    }