-
Random number from array to target layer
Hi Everyone,
Ok hopefully this is simple enough. Here’s my expression…
posx = thisComp.layer(“Emitter.2”).transform.position[0];
posy = thisComp.layer(“Emitter.2”).transform.position.wiggle(thisComp.layer(“WiggleEmitter”).effect(“Freq”)(“Slider”),thisComp.layer(“WiggleEmitter”).effect(“Amp”)(“Slider”))[1];
[posx,posy];
All I want to do is where it references “Emitter.2” I want to have an expression that says randomly select an number from an array of x amount and apply to this reference. So when I duplicate the layer up it will pick a different number each time.
Eg. Emitter.1 / Emitter.2 / Emitter.3 / Emitter.2/ Emitter.1 / Emitter.3 and so on…
Hope that makes sense!