Creative Communities of the World Forums

The peer to peer support community for media production professionals.

Activity Forums Adobe After Effects Expressions Trigger a keyframe animation with a conditional

  • Trigger a keyframe animation with a conditional

    Posted by Riccardo Sinti on December 2, 2015 at 10:13 pm

    I have a stroked path animating on with trim paths keyframed on the “End” parameter from 0% – 100%.
    I have other paths that branch off the main path which animate on in the same way.
    So branch one starts when main path hits 25%.
    I’m looking for an expression on branch 1’s “End” parameter, which is keyframed between 0% – 100%,
    that will say if “end” main path = 25% start the keyframed animation.

    this way I can adjust the timing of the main path without having to slide branch 1’s keyframes to adjust and I can do this for other branches as well.

    Thanks in advance!

    Riccardo Sinti replied 10 years, 5 months ago 2 Members · 2 Replies
  • 2 Replies
  • Kalleheikki Kannisto

    December 3, 2015 at 12:31 pm

    How about linear(Pick End parameter here, 25, 100, 0, 100)

  • Riccardo Sinti

    December 3, 2015 at 4:22 pm

    Needs more than that but thanks!
    After some searching I started playing around with this this but it doesn’t work

    start = thisComp.layer(“MAIN_PATH”).content(“Group1”).content(“Trim Paths 1”).end;

    t1 = key(1).time;
    t2 = key(2).time;
    if (start = 27) t = linear(time,t1,t2) else t = 0;
    valueAtTime(t)

    there are some elements here that I’m sure are necessary like the variables but not sure where to take it.

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