PDA

View Full Version : WTF how do u... control the load movie



Devil
August 3rd, 2002, 06:43 PM
new baby needs help...
i am have a main .swf i want to load other .swf into the main .swf
now i know how that works.... and i know how to unload it too... what i dont know is how do i driect its position. look this is what i mean . when i click on the button to load another .swf its loads fine..... however i want to load another .swf into the main .swf AT ANOTHER POSITION! how do u do that... i just cant find a way around that ... please help
:-\

iceman
August 4th, 2002, 10:51 AM
First off you have to make sure that both your main movie and your external movie have the same dimension, otherwise this won't work properly. You have two options. First is to load your external swf into a positioned movieclip on the stage, and second is to position your level using actionscript.

First Code:

on(release){
loadMovieNum("loadmovie.swf", target_mc)
}

Second Code:

on(release){
loadMovieNum("loadmovie.swf", 1)
_level1._x = 300;
_level2._y = 250;
}
This same positioning can be used with your movie clip but you just have to change the _level1 to the instance name of your movieclip.

Hope this helps

Kyle

RageW0lf
August 4th, 2002, 01:09 PM
you could load the movie into a movie clip, then the top left corner of your loaded move starts at the registration point, it gives you much more control that way. It will then act the same as a normal movie clip. To do that

URL : mymovie.swf

location : Select "Target" from the drop down.

for the target select the movie clip you want to import it into.

you have to label the instance of the movie yr importing into, and the timeline of that movie will be replaced with the movie yr loading in.

Devil
August 9th, 2002, 12:36 PM
yah it dint work........
:*(

i copied paste it and made the necessary changes yet dint work.


Someone please help out

Devil
August 9th, 2002, 12:39 PM
this one for Kyle

thanks dude ur codes makes sense yet they dint work...

iceman
August 9th, 2002, 01:16 PM
Try this instead, sorry I have to copy things from the actionscript window just sometimes I'm lazy:

Try this:
loadMovie("load1.swf", target_mc);
target_mc._x = 323;
target_mc._y = 188;


Hope this helps


Kyle:)

upuaut
August 10th, 2002, 01:17 AM
yeah.. the "Num" is the trick

loadMovie(); for loading swfs into targets
loadMovieNum(); for loading swfs into levels.

same thing with variables.

loadVariables();
loadVariablesNum();