ADOBE AFTER EFFECTS: Forum Expressions Tutorials Creative Cloud

Can't reference self position with valueAtTime

COW Forums : Adobe After Effects Expressions

<< PREVIOUS   •   FAQ   •   VIEW ALL   •   PRINT   •   NEXT >>
tom ono
Can't reference self position with valueAtTime
on May 19, 2020 at 4:22:57 pm

I thought position[0] would be 200(time>=2)but wouldn't.
Position[0] is 1234.2
why?
thanks

if(time&lt;2){
x=time*200;
[x,value[1]];
}else {
transform.position.valueAtTime(1);
}


Return to posts index

Dan Ebberts
Re: Can't reference self position with valueAtTime
on May 19, 2020 at 5:55:39 pm

When an expression references the value of the property hosting the expression, it always get the pre-expression value. Expressions have no memory, so an expression can't access its own results from previous frames. There are usually ways to work around that limitation though, depending on what you're trying to do.


Dan



Return to posts index

tom ono
Re: Can't reference self position with valueAtTime
on May 20, 2020 at 11:45:17 am

I was able to work around that limitation by just using the copy layer .
Thank you so much.


Return to posts index

<< PREVIOUS   •   VIEW ALL   •   PRINT   •   NEXT >>
© 2020 CreativeCOW.net All Rights Reserved
[TOP]