: After effects expression parent layer position relative to original position I have a situation where I need to use an expression to link two layers position values to one another but subtract
I have a situation where I need to use an expression to link two layers position values to one another but subtract the difference between the two so that they move together but the child stays in its original relative position.
example:
Parent = 100
Child = 50
Parent+(Child-Parent)=50
The expression I wrote seams to work at first as the layer stays in the right spot and I don't get any errors. But the layer doesn't move with the parents animation.
EXSPRESSION
parent=thisComp.layer("PARENT").transform.position;
child=transform.position;
parent+(parent-child)
More posts by @Yeniel278
Terms of Use Create Support ticket Your support tickets Stock Market News! © vmapp.org2024 All Rights reserved.