Problem using two expressions for controlling text.
I found two great expressions on the web, one for random words (based on words in the layer name), and another for random fonts (from a font list in the expression.) They both work great on their own, but when I stack them together only the lower one works. I know this is a common problem but I can't figure it out. I see other posts with solutions to similar non-text scripts, but I can't figure how to apply those solutions to this. Thank you for any assistance you can give. I would love to be able to apply both of these to on text layer!
Here're the scripts (there's a frame rate slider associated with the random word script, but I'm not sure how to include that:
//random words
words=thisLayer.name.split(" ");
wordCount=words.length;
frameRate=effect("Frame Rate")("Slider");
seedRandom(Math.floor(time*frameRate), timeless = true)
randomNumber=random(0,wordCount);
roundedNumber=Math.floor(randomNumber);
words[roundedNumber]
// random fonts
var array = [ "Courier-Bold", "Copperplate-Bold", "Compacta-Normal", "Citore", "Cochin", "Izzard", ];
hold=0.2;
seed=Math.round(random(time/hold));
seedRandom(seed,true);
r=Math.round(random(53));
style.setFont(array[r])
words=thisLayer.name.split(" ");
wordCount=words.length; frameRate=effect("Frame Rate")("Slider");
seedRandom(Math.floor(time*frameRate), timeless = true)
randomNumber=random(0,wordCount);
roundedNumber=Math.floor(randomNumber);
words[roundedNumber]
