Groups | Blog | Home
all groups > flash actionscript > march 2006 >

flash actionscript : 2movies with one name!


ebad293
3/23/2006 10:56:23 PM
I've faced with a problem;
I have 1 movieClip on my stack its name: "movie1"
And I have this code in first frame
_root.onEnterFrame ...
_root.movie1._alpha -= 5;
}
This works goodly!!
Now i put a copy of "movie1" on stack with the same name.
The action acts only for the first one!!!!
MatthewFord
3/23/2006 11:03:35 PM
I believe that you need to have new instance names for each clip you put on
stage (not stack) or else you will get just that behavior.

By instance name I mean the field you see in the clip's Properties after you
select it on the stage, or the name you give it when you use the method
attachMovie.

Call your copy "movie2", add code which refers to it such as:
_root.movie2._alpha -= 5;
..and see how that works.

If you want to write a loop that changes the alpha for all your movies, movie1
through movie99 or whatever, just ask; that's pretty straightforward.
AddThis Social Bookmark Button