Levels within external .swf's

[COLOR=blue]New** Please scroll to the last question on this page, I’ve sort of given up on this method and hope this next method will work better (lol…or at all…)**[/COLOR]

First off, am I wrong to say that when you load an external .swf into a main .swf all of the level information applies in the same level order as in the main .swf. For example, something loaded into level2 in the external swf should stay level2 when loaded into a different swf or is it 2 levels above the swf it was loaded from?

  • My problem is that I am calling a swf to open on level3, however, in THAT swf I have another clip that is to open on level2, thus appearing underneath of the originally loaded swf…but my level2 swf always opens above the level3 clip.

To call the level3 clip the code is as follows:


on (press) {
	this.createEmptyMovieClip("door", 3);
	door._x = 24;
	door._y = 10.5;
	loadMovie("dhome.swf", "door");
}

The code in level3 (dhome.swf) is simply:


loadMovie("phome.swf", 2);

So I dont understand why phome.swf would assume to load OVER my level3 info…

Note: I’ve also tried to get the level2 swf to load into an empty movie clip already on my main .swf but it doesn’t recognize the empty clip.

:love: as always
~ Seretha

:frowning: Does no one know how to help me or am I not explaining myself? Please help a girl out. :slight_smile:

(Please please please please please please please please…)

well… that’s a bit confusing. to load a swf into a level you use loadMovieNum not loadMovie. :-\

so loadMovie is only for loading movies into the same level? hmmmmmm… none the less i’ve already tried subsituting the equivalent code with loadmovienum instead and it doesn’t change the layering.

:love:

it also seems that IT DOES keep movies loaded on level2, 2 levels above where ever that original movie is loaded. Is there any way to reset the values or something so that in that external swf when I say to bring a new movie in and load it on 2 that it is always level2 of the base movie?

It’s all in a mess right now…here are my files so you can see exactly what I am trying to do, maybe even let me know of a different way to do this.

Main file
http://www.cyberwebs.org/test/wbhome.html
Download main file
http://www.cyberwebs.org/test/wbhome.fla

Download Second File
http://www.cyberwebs.org/test/dhome.fla
Download Picture File
http://www.cyberwebs.org/test/phome.fla

I have been fighting with this problem for quite some time and I cant seem to work it out. Please take a minute and help me out if you think you’ll be able to, I would appriciate it VERY MUCH. Thanks.

yup… i think it’s gonna be much easier for me with the fla’s. i’m downloading them now. :wink:

ok… so wbhome loads dhome into _level3 and dhome loads phome into _level2? :-\

…sorry for the late reply Kax.

Yea. That’s how I currently get them to load.

if i got what your asking… then this should solve it:

add this lines in the first frame of dhome and phome

this._x = 24;
this._y = 10.5;

to load dhome from wbhome use

loadMovieNum("dhome.swf", 2);

to load phome from dhome use

loadMovieNum("phome.swf", 3);

i’ll keep the fla’s just in case i’m wrong. :stuck_out_tongue:

i’ve never thought about using ‘this’ like that before… interesting…

let me try that code and let you know.

:love: ~ Seretha

hmm…

well it’s not that it doesn’t work per say, but it erases both movies for some reason when I re-click the button to get the movie to load again… but
I’ve been thinking of a way to get around the whole loading movies over each other problem and have started playing with a ‘gotoAndPlay’ code so that it will just go to the particular frame and run that specific movie section when the button is pressed.

I think this method would be best because it would be a longer initial loading period but not as many afterwards. Thanks for your help Kax, I didn’t realize that ‘num’ was used for that purpose, I always have just switched it around until it works, and I’ve actually found that often it tends to load a new window depending on when you use it too…but these messed up things always happen in my code, my own little twilight flash zone or something.


Can I tell it to gotoAndPlay a certain frame in the main .swf from an external .swf?

                        ****

I want the new movie to load and halfway through the play of the movie it tells my main movie to gotoAndPlay a certain frame. That is what I meant in my last question.

(When they click on a new button I want the old picture to stay while the doors close and the new pic to be there when it open and so on.)

Any help?

(Bumped the post hoping someone recently signed on to Kirupa for the night could answer my last question seeing as no one before has been able to…please?)