-
if / else expression: Color Picker Changes the Opacity of a Pre Comp
I am trying to write an if / else statement for a project so if a color control is a certain color, it changes the opacity of a pre comp.
SO
if the color is #61CFC8 then the opacity of the pre comp is 100, but if it’s any other color the opacity is 0.
This is the expression I have on the opacity of the layer I am trying to hide / show:
colorControl = comp("RHS_02_DaysOfTheWeek_16x9").layer("*PICK COLOR IN THIS LAYER*”);
if (colorControl.effect("COLOR 1")("COLOR") == #61CFC8) 100 else 0;