AudreyLucy
Technical User
Hi,
I'm using an attached movie clip, as a host clip for dynamically loaded jpgs. I would like to add an effect to this attached movie clip.
I want the host clip to "fade in"...but I'm having some trouble figuring out the proper syntax. I've had success getting the jpg to load into the host, but I can't get the host to fade in...
Here's the AS I have used...I'll add comments so it will be a little more clear as to what I'm trying to do on each line of script, please ask me if you need elaboration:
//tell host clip..."Be invisible."
image1_mc._alpha = 0;
//attach the host movie clip to the root level.
"image_mc" is the linkage identifier and
"image1_mc" is the new name of the host clip[/color]
_root.attachMovie("image_mc", "image1_mc", 1);
//load the jpg into the movie clip
image1_mc.onEnterFrame = function() {
_root.loadMovie("blur.jpg","image1_mc"
;
};
//"image1_mc", fade in. This AS works when I am NOT using attachMovie.
image1_mc.onLoad = function() {
image1_mc.steps = 10;
image1_mc._alpha += 100/this.steps;
};
stop();
Does anyone know what I can do to make this work?
I'm using an attached movie clip, as a host clip for dynamically loaded jpgs. I would like to add an effect to this attached movie clip.
I want the host clip to "fade in"...but I'm having some trouble figuring out the proper syntax. I've had success getting the jpg to load into the host, but I can't get the host to fade in...
Here's the AS I have used...I'll add comments so it will be a little more clear as to what I'm trying to do on each line of script, please ask me if you need elaboration:
//tell host clip..."Be invisible."
image1_mc._alpha = 0;
//attach the host movie clip to the root level.
"image_mc" is the linkage identifier and
"image1_mc" is the new name of the host clip[/color]
_root.attachMovie("image_mc", "image1_mc", 1);
//load the jpg into the movie clip
image1_mc.onEnterFrame = function() {
_root.loadMovie("blur.jpg","image1_mc"
};
//"image1_mc", fade in. This AS works when I am NOT using attachMovie.
image1_mc.onLoad = function() {
image1_mc.steps = 10;
image1_mc._alpha += 100/this.steps;
};
stop();
Does anyone know what I can do to make this work?