ADOBE AFTER EFFECTS: Forum Expressions Tutorials Creative Cloud

Switching between words randomly expression?

COW Forums : Adobe After Effects Expressions

<< PREVIOUS   •   FAQ   •   VIEW ALL   •   PRINT   •   NEXT >>
Göran Thorén
Switching between words randomly expression?
on May 25, 2018 at 7:20:55 am

Hi there all you expression gurus!

I'm trying to work out how to randomly switching words that recides on separate layers or possibly in the same layer.
In the end, what I'm actually trying to achieve is to somehow have a comp that randomly switches between all the month of the year, preferably with som level of control of how long each word stays visible.

Does this make sense at all?

Thanks in advance!
/Göran



Return to posts index

Dan Ebberts
Re: Switching between words randomly expression?
on May 25, 2018 at 10:11:12 am

Maybe a Source Text expression like this:

months = ["JAN","FEB","MAR","APR","MAY","JUN","JUL","AUG","SEP","OCT","NOV","DEC"];
dur = .5; // change every .5 seconds
seed = Math.floor((time-inPoint)/dur);
seedRandom(seed,true);
idx = Math.floor(random(months.length));
months[idx]


Dan



Return to posts index

Göran Thorén
Re: Switching between words randomly expression?
on May 27, 2018 at 4:20:20 pm

Well, what can I say... That is exactly what I meant, works like a total charm! Thank's a million Dan!



Return to posts index

<< PREVIOUS   •   VIEW ALL   •   PRINT   •   NEXT >>
© 2018 CreativeCOW.net All Rights Reserved
[TOP]