-
Link opacity to Null Position.
Hi guys!
I’ve been trying to figure this one out this morning, and I seem to be stuck now..
I have a line of dots, and a Null that is above them.
I want each dot to have its opacity go from 25 -> 100, when the null is above it +- a value I can easily change.
All that have been worked out now, but I want it to fade from 25-100, but I cant figure out how…
I hope you can help me out!
Kind regards,
Adam
//Position//
ConPos = thisComp.layer("Controller").transform.position[0];
CircPos = transform.position[0];//Opacity//
MaxOpa = 100;
MinOpa = 25;//Controllers//
s = thisComp.layer("Controller").effect("Tolerance Slider")("Slider");//EXPRESSION//
if (CircPos>ConPos+s || CircPos<ConPos-s)
{MinOpa}
else
{MaxOpa};