Forum Replies Created

  • Pierre Guiet

    April 27, 2007 at 5:24 pm in reply to: Movement control for counter

    This works for the first rotation. The number increments in one frame. What I would like to do is reset
    yPosition in the else statement to the value it started with in the script. Is there a way to do this?
    Seems as though every frame the code is executed from the start of the script. Just not sure how to do this?

    //Use the needle to position the numbers
    // to get the .72 I divided 36 degrees the amount it takes to get to 1 by 50 pixels the height of the number box
    //from dan yPosition = thisComp.layer(“NEEDLE”).transform.rotation/0.72%360;
    // from dan [value[0], yPosition-105]
    //I believe 500 is the height of the graphic from the bottom to bottom of zero check scrnum4.ai file
    //mutitply by .1 to slow it down for the thousands had to add a zero to 500 so it wouldn’t flip over
    //% is the JavaScript modulus operator. x%y returns the remainder that results from dividing x by y. Very useful for translating a continuously growing value into a cyclic one FROM DAN creative cow
    // good one yPosition = thisComp.layer(“NEEDLE”).transform.rotation/0.72%5000*.1;
    yPosition=thisComp.layer(“NEEDLE”).transform.rotation/0.72%5000/500;
    yTempPosition=Math.floor((thisComp.layer(“NEEDLE”).transform.rotation/0.72%5000/500));

    if (yPosition < 1){ ( yTempPosition ) }else{ yTempPosition=yTempPosition + 50; // reset yPosition back to its original value here // not sure how to set up this kind of value } // [value[0], yPosition-81]; [value[0], yTempPosition-81];

  • Pierre Guiet

    January 29, 2007 at 11:03 pm in reply to: if then else snafu

    thanks

  • Pierre Guiet

    January 29, 2007 at 9:53 pm in reply to: if then else snafu

    Dan,
    That is wonderful. Turns out when I change number 360 to the height of my graphic minus the adjustment for placing the layer
    500 works perfectly.

    I couldn’t find the % symbol in the help file.
    Can you use this in other contexts?

    thanks again
    bn

  • Pierre Guiet

    November 29, 2006 at 7:31 pm in reply to: One Button Menu

    Great tip! thanks

  • Pierre Guiet

    November 15, 2006 at 4:02 pm in reply to: intro video to main menu problem

    Many Thanks Jeff

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