Thank you very much, Dan.
Yesterday I was really in a hurry so I had to manage the solution by myself. I found a lot of help in your site and succeeded to type two expressions that worked. I’m really new in expressions and I’m sure there’s a more simple way to achieve the same, but they worked anyway.
For position (3D):
freq = 5;
decay = 5;
mult = .002;
if (numKeys > 1 && time > key(2).time){
t = time – key(2).time;
a = velocityAtTime(key(2).time-.01)[0];
b= velocityAtTime(key(2).time-.01)[1];
c= velocityAtTime(key(2).time-.01)[2];
x= a*mult*Math.cos(t*freq*Math.PI*2)/Math.exp(t*decay);
y = b*mult*Math.cos(t*freq*Math.PI*2)/Math.exp(t*decay);
z = c*mult*Math.cos(t*freq*Math.PI*2)/Math.exp(t*decay);
value + [x,y,z]
}else{
value + [0,1,2]
}
for rotation:
freq = 4;
decay = 1.5;
mult = .08;
if (numKeys > 1 && time > key(2).time){
t = time – key(2).time;
a = velocityAtTime(key(2).time-.01);
d = a*mult*Math.sin(t*freq*Math.PI*2)/Math.exp(t*decay);
value + [d]
}else{
value
}
Thanks again.