-
switching a background without reseting anything on the stage
I'm making a drag and drop game and I want to be able to switch backgrounds without resetting the position of anything that has been dragged around, how would i do this?
Note: This is in Flash 5 and it will be used on a button of course
-
Banned
Hi,
Create a movieclip on the lowest layer of your movie and load other swf files in as the background........
on (release) {
_root.holderMC.loadMovie("someFile.swf");
}
-
wait a minute...its only one movie, so theres only 1 .swf file. But the backgrounds will be graphics.
What if I made the backgrounds movie clips and used there instance names would that work?
-
NTD's solution is way better. That way, you can have a huge number of backgrounds without your movie becoming huge itself.
Put each background graphic into a new .fla, publish and load into the lower layer container of your main swf, as NTD suggested.
gparis
-
so i import all of the individual .swf files into the same bottom layer of the movie? Or do I make a new layer under each one?
-
You load each swf in the same container (_root.holderMC) , they will replace each other.
_root.holderMC.loadMovie("bkg1.swf");
will load the first background .swf into_root.holderMC, which is your container movieClip residing on your lowest layer.
_root.holderMC.loadMovie("bkg2.swf");
will load another background .swf into_root.holderMC.
etc.. as many as you want.
gparis
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|