Creative Communities of the World Forums

The peer to peer support community for media production professionals.

Activity Forums Adobe After Effects Expressions “if statemant” multiple conditions problem

  • “if statemant” multiple conditions problem

    Posted by Vojtěch Palme on January 13, 2013 at 4:09 pm

    Hi,
    I’m trying to make onle layer animate up if some conditions are met and stop at certain point.
    It starts moving but I want it wont stop even if not all conditions aren’t met anymore.

    lines = effect("lines")("Slider");
    maxPos = lines*10; //maximum Y value aka stop point
    s = 3.4; //starting time

    if (time>s && lines>7 && value[1]>maxPos)
    [value[0],value[1]+((time-s)*-130)]
    else
    value

    also, what should I do to make the animation start gradually (ease out)
    Thank you.

    Vojtěch Palme replied 13 years, 4 months ago 2 Members · 2 Replies
  • 2 Replies
  • Dan Ebberts

    January 13, 2013 at 8:35 pm

    Are you assuming that value[1] will change based on previous calculations of the expression? If so, that won’t work because expressions can only access the pre-expression value of the host property. I think you would need to change your test to something based on the same calculation you use to create the new y value.

    Dan

  • Vojtěch Palme

    January 14, 2013 at 11:35 am

    Yep. That was the idea.
    SO how would you do it?
    There is a text field. Only 7 lines of text fit in it, so if variable “lines” is bigger than 7, I want the field to start moving at certain time. And stop when the last line is visible (maxPos variable). And it would be welcomed if the animation could easeOut. I know there is souch statemant easeOut(,,) but dunno, how to use it.

We use anonymous cookies to give you the best experience we can.
Our Privacy policy | GDPR Policy