dcell
April 22, 2003, 1:57pm
1
I have 2 movieClips that I want to fade.
mc 1 fades out while mc2 fades in. I want to do it in AS to keep my file size down, 'cause I will be having quite a few of this happing.
I know how to have one mc fade in using:
(I know this is a fade in and I can fadein/out individually)
speed = 10;
bigCalendar_mc.onEnterFrame = function() {
if (this._alpha<100) {
this._alpha += speed;
} else {
delete this.onEnterFrame;
}
};
But my brain is hurting trying to figure out how to get the two crossfading.
Many thanks!!
Dcell
system
April 22, 2003, 2:20pm
2
speed = 10;
bigCalendar_mc.onEnterFrame = function() {
if (this._alpha<100) {
this._alpha += speed;
myOtherMC._alpha = (100 - this._alpha);
}
else {
delete this.onEnterFrame;
}
};
system
April 22, 2003, 2:21pm
3
Hi,
Just insert this line of code :
[AS]instancename._alpha -=speed;[/AS]
after this :[AS]this._alpha += speed;[/AS]
That should do the trick
Cheers
SteveD
quick edit, just seen razz’s post, that code is far more effective - now why didn’t I think of that (lol)
system
April 22, 2003, 2:56pm
4
Many thanks!!!
I was going a little nutz…ok…a lot nutz.
Much appreciate your help!!
Dcell(-: