Creative Communities of the World Forums

The peer to peer support community for media production professionals.

Activity Forums Adobe After Effects Expressions After Effects Position Expression

  • Dan Ebberts

    April 26, 2022 at 12:09 am

    I think we need more info. Please be more descriptive about what you’re trying to do.

  • Mirco Lanz

    April 26, 2022 at 7:18 am

    I want to build a Lightning Effect with “advanced lighting” The idea is that i have a fixed point for the beginning of the Lightning and the End is jumping to different tracked positions in the room.

  • Dan Ebberts

    April 26, 2022 at 2:58 pm

    This should randomly select the position of any layer except the one with the expression:

    minDur = .5;

    maxDur = 1.5;

    t = tPrevT = inPoint;

    seedRandom(index,true);

    while (t <= time){

    tPrev = t;

    t += random(minDur,maxDur);

    }

    seedRandom(tPrev,true);

    L = [];

    for (i = 1; i <= thisComp.numLayers; i++){

    if (i == index) continue;

    L.push(i);

    }

    fromComp(thisComp.layer(L[Math.floor(random(L.length))]).transform.position)

  • Mirco Lanz

    April 26, 2022 at 8:42 pm

    Thanks! I will try this tomorrow at work 🙂

  • Mirco Lanz

    April 27, 2022 at 5:06 pm

    I tested your expression today and it works wonderfully! Thank you very much! You have helped me a lot ❤

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