That’s what I thought as well, but somehow that gives this error (which refers to the line of idx1=Math.floor(random(colors.length))):
property or method named “length” in Class “Number” is missing or does not exist. It may have been renamed, moved, deleted, or the name may have been mistyped.
The weird thing is that I don’t get this error when putting the numbers directly in the expression.
ctrl = thisComp.layer("colours");
colors=eval(ctrl.text.sourceText.value);
minDur = ctrl.effect("minDuration")("Slider")
maxDur = ctrl.effect("maxDuration")("Slider");
seedRandom(index,true)
segDur = random(minDur,maxDur);
easeTime = ctrl.effect("easeDuration")("Slider");
curSeg = Math.floor(time/segDur);
t = time%segDur;
seedRandom(curSeg,true);
idx1 = Math.floor(random(colors.length));
seedRandom(curSeg-1,true);
idx0 = Math.floor(random(colors.length));
ease(t,0,easeTime,colors[idx0],colors[idx1])