Creative Communities of the World Forums

The peer to peer support community for media production professionals.

Activity Forums Adobe After Effects what is the trick to get around the fact that expressions don’t have memory?

  • what is the trick to get around the fact that expressions don’t have memory?

    Posted by Thor64 on August 13, 2006 at 9:50 pm

    I think the subject is the issue in my problem…

    I want a value to add another value to itself
    like

    myVar = myVar + 1;

    Dan Ebberts replied 19 years, 9 months ago 2 Members · 1 Reply
  • 1 Reply
  • Dan Ebberts

    August 13, 2006 at 11:37 pm

    Depends on what you’re doing. A lot of times you can convert the expression to a equation based on time. Sometimes you have to have your expression “recreate” the past by walking through the comp frame by frame. The are other, more obscure techniques that can be helpful in rare situations.

    If all you want to do is increment a value on each frame you could do it like this:

    myVar = 10; //starting value
    f = Math.round(time/thisComp.frameDuration); //frame number
    myVar += f;

    Dan

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