Creative Communities of the World Forums

The peer to peer support community for media production professionals.

Activity Forums Adobe After Effects How do I stop an animation preset after a certain number of times?

  • How do I stop an animation preset after a certain number of times?

    Posted by Rosaleen Donnan on August 3, 2011 at 7:51 pm

    Hello there

    Firstly, huge apologies because I am extremely new to AE and teaching myself!

    I am using CS3 and have added the AE text animation preset Broadway to some text but I would like it to stop animating after it has rippled through the text a few times, say 10 times.

    I don’t understand the coding in the expression to be able to control it there.

    f=effect(1)(1);
    div = Math.abs(Math.sin(2 * textIndex/textTotal – time*f)*100);
    result = 0;

    if (div) {
    result = 300/div – 3;
    }

    I split the layer at the point where I would like the preset to stop animating but I am not sure how to subsequently then take the preset out of the split layer because if I remove parts of it I break the look of the original text!

    Any wisdom and insight would be gratefully received! Many thanks!

    Darby Edelen replied 14 years, 9 months ago 3 Members · 2 Replies
  • 2 Replies
  • Richard Harrington

    August 3, 2011 at 8:30 pm

    Select layer.

    Press U to see user added keyframes

    Look for what properties are animated. Repeat value on last keyframe and adjust position as needed

    Richard M. Harrington, PMP

    Author: From Still to Motion, Video Made on a Mac, Photoshop for Video, Understanding Adobe Photoshop, Final Cut Studio On the Spot and Motion Graphics with Adobe Creative Suite 5 Studio Techniques

  • Darby Edelen

    August 3, 2011 at 8:58 pm

    Hi Rosaleen,

    I’m not familiar with the text preset you mentioned, and unfortunately they seem to have changed the way that preset works in future versions of AE.

    I think, though, that you can make this change to the expression “result” variable:


    f=effect(1)(1);
    div = Math.abs(Math.sin(2 * textIndex/textTotal - time*f)*100);
    result = 0;

    if (div) {
    result = (value * 3)/div - 3;
    }

    Then keyframe the “Amount” property associated with the Expression Selector from 100% to 0%. At 0% the text will be in its normal (unselected, unflashy) state.

    If, however, you want the animation to just stop, and keep the relative brightness of the letters when it does, then it’s a bit different:


    t = Math.min(time, marker.key(1).time);
    f=effect(1)(1);
    div = Math.abs(Math.sin(2 * textIndex/textTotal - t*f)*100);
    result = 0;

    if (div) {
    result = 300/div - 3;
    }

    The first line I’ve added above, and the ‘t’ variable replacing ‘time’ in the ‘div’ variable, should cause the animation to stop (abruptly) at the first layer marker on the text layer.

    Darby Edelen

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