Delay Keyframes With Slider ValueAtTime()
How to Delay Keyframes with ValueAtTime() and a Slider
The valueAtTime() expression get the property's current value at the provided time. If you use valueAtTime(1), the expression will return the value at second 1 of your composition.
But here's the magic. You can add a delay to the "time" and offset your current animation by and adjustable amount.
valueAtTime(time-delay)
Then, just link the delay variable to a Slider Control and you have an easy, animatable controlled delay to your animation.
(extremely useful for templates)
How to Create a Delay between Layers
You can also use this type expression to have one layer follow another layer with a delay. Just add this expression to the position property of Layer B (the following layer).
var delay = 0.5
var layerAPosition = // pickwhip to the leading layer
layerAPosition.valueAtTime(time-delay)
Now Layer B will follow Layer A with a 0.5 second delay!
More expressions you might like...
Credit
Get Β After Effects tips & tricks
delivered to your inbox