-
if/else/while etc
Hi guys,
I need your help on this.
I have a layer which i intend to duplicate (in excess of 50 times) and using an expression, distribute them on the y axis according to the layers’ index value (i.e value+[0,index*5]). This is the easy part!I also have a slider control on another layer and want to use it to control the duplicated layers’ opacity (0/100 – i.e off/on). It should work like this:
All the duplicated layers are off (in terms of thier opacity) unless the slider value is greater than 1. At which point, only the duplicated layer whose index value is between 2-6 is set to on (i.e. 100). If the slider value is greater than 2, then those whose index value is between 7-10 is ALSO on. Thus with every increment in the slider a further four layers are turned on. Do you see it?I can add a simple expression on each of the duplicated layers to achieve this effect. However, i want to write an expression on just the first layer so that i can then duplicate it without having to write an expression on each of the dupliated layers manually.
Thanks.