Ultrashock Forums > Flash > Flash Newbie
Loading .swf into nested movie clips? (.fla attached)

You are currently viewing our website as a guest which gives you limited access to forums, files and other resources.

Click here to join now for free, and start interacting with our members, download files and much more!

Click here if you are looking for our Flash files and other professional assets.
 
Post Reply | View first unread | Rate Thread Search this Thread | Thread Tools | Display Modes

#1
Bookmark and Share!
Loading .swf into nested movie clips? (.fla attached)
Old 2009-08-21

Ok, adter much bunbling around, I`ve finally figured out how to load external .SWF files into my main movie. Works like a charm!

Now I`m having trouble loading them into nested movie clips... What I`m trying to do is get an .swf / 3D animated movie to load into a specific movie clip "mainMovieloader" that is 2 levels down from the root movie (it`s located inside another movie on the main time line called "MaincontentsMovie". I guess the structure would look like this:

_root
MaincontentsMovie_mc
mainMovieloader_mc



I can get the .swf to load into MaincontentsMovie_mc using the following code on my mainMovieloader_mc:

onClipEvent(enterFrame) {
_root["MaincontentsMovie"].loadMovie("http://www.cre8tivemv.com/LingoLand/Eigo/FlashStuff/StressFactor.swf","0");
}


but the location is all jacked up (it`s waaaay off center), and what I really want it to do is load into the mainMovieloader_mc INSIDE of MaincontentsMovie_mc (and be centered). I`ve spent 7 hours trying to work through this on my own and my brain smells like roasted pork & beans...

Would anyone please be kind enough to let me know what I`m doing wrong? I`ll be using a lot of these nested movie clips in the site I want to make once I learn how to do this...

I`ve attached a link to the .swf file I`m working on (my new business site)... Feel free to take a look. Some stuff there is just place holders and area markers for visual reference (like the orange boarder where my external .swf is supposed to load) - I tried to upload the actual .fla but my internet connection wasn`t having it tonight... Sorry!

Here`s the link, thanks!

http://cre8tivemv.com/LingoLand/Eigo...orHomepage.swf
postbit arrow 1 comment | 1742 views postbit arrow Reply: with Quote   
Registered User
Wfire3 is offline
seperator
Posts: 23
2002-07-01
seperator

Ultrashock Member Comments:
Ruprechto's Avatar Ruprechto Ruprechto is offline Ruprechto lives in United States 2009-11-02 #2 Old  
Try this
Do you know how to load using the X and Y properties? Try adding the following after your "loadMovie" line;

setProperty("MaincontentsMovie_mc", _x, 100);
setProperty("MaincontentsMovie_mc", _y, 220);

the 100 and 220 are just test pixel depths for the vertical and horizontal placement. Change to what you need once you see where the above places it. Usually setting each to "0" means the upper left corner of your container but movies loaded, by default, retain the original properties of what was there
Reply With Quote  
Thread Tools
Display Modes Rate This Thread
Rate This Thread: