Creative Communities of the World Forums

The peer to peer support community for media production professionals.

Activity Forums Adobe After Effects Expressions Completion % slider control with Delay

  • Completion % slider control with Delay

    Posted by Ilya Sire on January 21, 2021 at 7:23 pm

    Hi,

    I have 3 layers that have a linear expression on rotation and im create a slider A 0 to 100 as completion percent.

    A = effect("Completion")("Slider");

    index = 0 // layer 1

    totalLayer = 3

    offset = 1.5*index*thisComp.frameDuration;

    linear(A,(100/totalLayer)*index,(100/totalLayer)*(index+1),0,90);


    index = 1 // layer 2

    totalLayer = 3

    offset = 1.5*index*thisComp.frameDuration;

    linear(A,(100/totalLayer)*index,(100/totalLayer)*(index+1),0,90);


    index = 2 // layer 3

    totalLayer = 3

    offset = 1.5*index*thisComp.frameDuration;

    linear(A,(100/totalLayer)*index,(100/totalLayer)*(index+1),0,90);

    I’m not sure this proper way to this but worked, it starts one after another.

    The question is, how can I make it time offset (to faster or delay), that calculated in the slider Completion percent?

    Thank you

    Filip Vandueren replied 5 years, 3 months ago 2 Members · 1 Reply
  • 1 Reply
  • Filip Vandueren

    January 22, 2021 at 1:11 pm

    Be aware that “index” is a reserved keyword in expressions and shouldn’be used as a variable name.

    I’m not entirely sure what your question is, but maybe something like this:

    A = thisComp.layer(1).effect("Completion")("Slider");
    i=index-1;
    totalLayer = 3;
    overlap = 2;
    totalLayer+=overlap;
    linear(A,(100/totalLayer)*i,(100/totalLayer)*(i+overlap),0,90);

    At overlap-values between 0 and 1, there will be a pause between each next turn.

    Overlap==1 will be no overlap.

    Overlap > 1 will give more and more overlap

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