ActiveDen

Disable an effect with expressions?

516 posts
  • Sold between 5 000 and 10 000 dollars
  • Exclusive Author
  • Microlancer Beta Tester
  • Has been a member for 1-2 years
  • Referred between 1 and 9 users
  • Bought between 1 and 9 items
  • United States
GrizzleFX says

Hey i’m an expressions noob and I was wondering; is there a way to completely shut off an effect through expressions? (specifically check-box) And also be able to re-enable the given effect.

-Graham

516 posts
  • Sold between 5 000 and 10 000 dollars
  • Exclusive Author
  • Microlancer Beta Tester
  • Has been a member for 1-2 years
  • Referred between 1 and 9 users
  • Bought between 1 and 9 items
  • United States
GrizzleFX says

Nevermind…stupid question; figured out how.

Mods can delete

168 posts
  • Author had a Free File of the Month
  • Microlancer Beta Tester
  • Repeatedly Helped protect Envato Marketplaces against copyright violations
  • Exclusive Author
  • Sold between 10 000 and 50 000 dollars
  • Contributed a Blog Post
  • France
  • Has been a member for 1-2 years
+2 more
Darkpulse says

Wich type of efftect, per example, “fill effect” : alt clic on opacity timewatch and type :

C = thisComp.layer(yourlayer).effect(yourcheckbox)”checkbox”;

If (c=true){ value=100 }else{ value=0 }

//// “c” is your condition, your chekbox here If your checkbox is enabled the effect parameter value will be 100, if checkbox is disabled, your effect parameter value will be 0. Replace these value by your effect value… I hope I’m clear… ;)

516 posts
  • Sold between 5 000 and 10 000 dollars
  • Exclusive Author
  • Microlancer Beta Tester
  • Has been a member for 1-2 years
  • Referred between 1 and 9 users
  • Bought between 1 and 9 items
  • United States
GrizzleFX says

Thanks DarkPulse that was helpful. What i’m trying to do is have the ability to enable or disable a “Turbulent Displace” effect that is animated so that the displace amount starts at 100 and ends at 0 after 5 seconds, right now I have one of the two expressions to use each of them has problems:

(comp(“Comp 1”).layer(“Main Controls”).effect(“Turbulent Displace”)(“Checkbox”) * 150)-(time * 20);

(comp(“Comp 1”).layer(“Main Controls”).effect(“Turbulent Displace”)(“Checkbox”)*150)/(time+10);

The first one does not work because it continues to subtract thus going into negative numbers. The second expression does not work because it can never get to zero. How would I fix this so the expression would give a value of 0 at 5 seconds while also animating down from 100?

168 posts
  • Author had a Free File of the Month
  • Microlancer Beta Tester
  • Repeatedly Helped protect Envato Marketplaces against copyright violations
  • Exclusive Author
  • Sold between 10 000 and 50 000 dollars
  • Contributed a Blog Post
  • France
  • Has been a member for 1-2 years
+2 more
Darkpulse says

I’m not at home right now ( I’m on my iphone), so it’s not easy to understand your probleme. Simply try to duplicate your layer/comp and disable FX on one of them : put the layer with the displacement effect on top of the original. Apply my expression on the opacity layer value to get somerhing like that :

A : layer/comp with displacement FX B : original layer/comp (without displacement)

Apply expression with inverted consequence, when checkbox = ON > opacity layer A = 100% & opacity layer B = 0% when checkbox = OFF > opacity layer A = 0% & opacity layer B = 100%

4445 posts
  • Elite Author
  • Community Moderator
  • Sold between 50 000 and 100 000 dollars
  • Author had a File in an Envato Bundle
  • Beta Tester
  • Has been a member for 4-5 years
  • United Kingdom
+5 more
felt_tips moderator says

Thanks DarkPulse that was helpful. What i’m trying to do is have the ability to enable or disable a “Turbulent Displace” effect that is animated so that the displace amount starts at 100 and ends at 0 after 5 seconds, right now I have one of the two expressions to use each of them has problems:

(comp(“Comp 1”).layer(“Main Controls”).effect(“Turbulent Displace”)(“Checkbox”) * 150)-(time * 20);

(comp(“Comp 1”).layer(“Main Controls”).effect(“Turbulent Displace”)(“Checkbox”)*150)/(time+10);

The first one does not work because it continues to subtract thus going into negative numbers. The second expression does not work because it can never get to zero. How would I fix this so the expression would give a value of 0 at 5 seconds while also animating down from 100?

a = comp(“Comp 1”).layer(“Main Controls”).effect(“Turbulent Displace”)(“Checkbox”) * 150 – (time * 20);

clamp(a, 0, 100000000000);

516 posts
  • Sold between 5 000 and 10 000 dollars
  • Exclusive Author
  • Microlancer Beta Tester
  • Has been a member for 1-2 years
  • Referred between 1 and 9 users
  • Bought between 1 and 9 items
  • United States
GrizzleFX says

clamp(a, 0, 100000000000);

Thanks both of you! This is what I was looking for :)

547 posts
  • Sold between 100 000 and 250 000 dollars
  • Most Wanted Bounty Winner
  • Author had a File in an Envato Bundle
  • Has been a member for 5-6 years
  • Referred between 100 and 199 users
  • Bought between 100 and 499 items
  • Italy
+4 more
flashato says
a = comp(“Comp 1”).layer(“Main Controls”).effect(“Turbulent Displace”)(“Checkbox”) * 150 – (time * 20); clamp(a, 0, 100000000000);

Please guys, follow the rules..use english :D

516 posts
  • Sold between 5 000 and 10 000 dollars
  • Exclusive Author
  • Microlancer Beta Tester
  • Has been a member for 1-2 years
  • Referred between 1 and 9 users
  • Bought between 1 and 9 items
  • United States
GrizzleFX says

Please guys, follow the rules..use english :D

Tell me about it! ;)

4445 posts
  • Elite Author
  • Community Moderator
  • Sold between 50 000 and 100 000 dollars
  • Author had a File in an Envato Bundle
  • Beta Tester
  • Has been a member for 4-5 years
  • United Kingdom
+5 more
felt_tips moderator says

a = comp(“Comp 1”).layer(“Main Controls”).effect(“Turbulent Displace”)(“Checkbox”) * 150 – (time * 20); clamp(a, 0, 100000000000);
Please guys, follow the rules..use english :D

:D

by
by
by
by
by