-
Blink on to desired opacity
Hi,
I think I got this script from this forum and it works really well for me, but I want to be able to set it’s final opacity to what ever I want, right now it goes to 100%. What needs to be added to this to make that happen?
blinks = 5; // The number of times to blink while fading in. you can change this and it will recompute for you
blinkFrames = blinks*2;
inFrame = Math.round(in_point/this_comp.frame_duration);
outFrame = Math.round(out_point/this_comp.frame_duration);
frame = Math.round(time/this_comp.frame_duration);
if (frame < inFrame + blinkFrames){
delta = frame – inFrame;
if (delta % 2 == 0){
0;
} else {
linear(delta,0,blinkFrames,10,110);
}
} else if (frame < outFrame – blinkFrames){
100;
} else {
delta = frame – (outFrame – blinkFrames);
if (delta % 2 != 0){
0;
} else {
linear(delta,0,blinkFrames,100,0);
}
}