Copy link to clipboard
Copied
So, I created a window design inside a different composition, and I want to create a size control inside the main composition. But I found a problem, when I add a keyframe in the control, the shape of the window inside the composition doesn't change, it just sticks to the value in the first keyframe.
I still don't understand the expression system, so I just rely on the parent system.
Based on what I can see in your video, if you replace your scale expression with this, you should be good to go:
C = comp("MainComp");
ctrl = C.layer("Control").scale;
L = C.layer(thisComp.name);
ctrl.valueAtTime(time + L.startTime)
Copy link to clipboard
Copied
Are you using an expression to link the scale inside the precomp to the control in the main comp? If so, please post the expression you're using.
Copy link to clipboard
Copied
Based on what I can see in your video, if you replace your scale expression with this, you should be good to go:
C = comp("MainComp");
ctrl = C.layer("Control").scale;
L = C.layer(thisComp.name);
ctrl.valueAtTime(time + L.startTime)
Copy link to clipboard
Copied
ahhh, yeah... it make sense now, i forgot bout valueAtTime... it works now!
Copy link to clipboard
Copied
It's only an issue if you keyframe a control in the main comp and the start time of the precomp layer in the main comp is not zero.