Creative Communities of the World Forums

The peer to peer support community for media production professionals.

Activity Forums Adobe After Effects Expressions swing based on movement

  • swing based on movement

    Posted by Rob Schof on July 6, 2009 at 4:32 pm

    hello,

    i need to swing an angle back and forth. i am going to be animating the position of the object and for every 100px i move it on the z axis, i want it to do a full loop on the swing (10>100>10) i have tried a few expressions but cant seem to get it to work.
    thanks in advance for any suggestions!

    rob

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

    July 6, 2009 at 5:43 pm

    Probably something like this:

    z = transform.position[2]%100;
    if (z < 50){ ease(z,0,50,10,100) }else{ ease(z,50,100,100,10) } Dan

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