-
Using Expressions – how to check if a layer is selected
I have these psd icons for an animated rig. I want the users to click these icons for different portions of the body (make it user friendly), but when they click on these icons, I want to make them 30% opaque so that the animators can see what is below (the rig).
I noticed there is no ‘isSelected’ boolean statement in Expressions so there’s no way to see if the layer is selected, only ‘active’ but that doesn’t help.
Is there a possibility to change the opacity on movement? such as this…
temp = thisLayer.position;
if(temp – this.position == [0,0])
{
transform.opacity = 30;}
else
{
transform.opacity = 90;
}I have this expression in the opacity transformation of the icon layer, but it doesn’t work.