Forum Replies Created

  • Steve Edwards

    July 31, 2022 at 12:58 am in reply to: Auto-detect if there’s a keyframe

    I know I’m literally almost a decade late but I was trying to detect if there were keyframes and I found this thread really helpful and thought I’d add to it for anyone else looking for a solution.

    For my project I wanted a property to only use an expression when there were no keyframes and then basically let the keyframes takeover when they were present.
    I ended up with this:

    d = Math.abs(time – nearestKey(time).time);

    if(d==0){

    //key frame present

    } else {

    //no key frames

    }

    
    

     

    
    
    		

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