-
How to add two expressions to a single property?
I have a camera that is set to orbit around a null object so I just move the null, not the camera. I then wanted to add a wiggle and a bouncing expression to it so as to add a little life to the movements. My solution was adding the expression (as you see below) to the property “Position” in the null. It will only apply the second expression ignoring the first one, be it the wiggle or the inertial bounce (I tried it backwards). It did work in a previous file the first time a tried it. What am I doing wrong?
// Inertial Bounce (moves settle into place after bouncing around a little)
n = 0;
if (numKeys > 0){
n = nearestKey(time).index;
if (key(n).time > time){
n--;
}
}
if (n == 0){
t = 0;
}else{
t = time - key(n).time;
}if (n > 0){
v = velocityAtTime(key(n).time - thisComp.frameDuration/10);
amp = .05;
freq = 4.0;
decay = 2.0;
value + v*amp*Math.sin(freq*t*2*Math.PI)/Math.exp(decay*t);
}else{
value;
}wiggle(0.25,50)