-
I've got a main movie with 5 buttons, and 5 small swf files. Everytime the user hits a button, this is what I do:
on (release) {
loadMovieNum ("movie1.swf", 0);
}
This will load the little sub movies into level 0. It works fine, however, I have noticed that there is a slight delay when clicking on these buttons to load these sub movies. Also, I was displaying a big blank screen for a split second, which I didn't like...
Is there a better way to do this? I tried loading all the sub movies into level1, which worked also, but then for a split second, I was displaying the main movie when I clicked on the nav buttons, and thats no good either!!
Are you just supposed to design your screens with this in mind??
-
Make sure!
I presume u mean during testing stage u get these blank screen flashing and not uploaded to the webspace.
Make sure that u have no blank frames anywhere in the movie timelines that shouldnt be there. It should be instant if u are testing through flash.
-
Actually, I'm getting a black screen. Let me explain.
My movie has a black background, and so does my HTML page.
The very first thing I do in my preloader is display a white rectangle. The white rectangle is my stage, and I build on top of that...
But when I click my nav buttons and do a loadMovieNum and load my submovies into level0, I get nothing but a black screen for just a split second. It's like it takes awhile to load the submovie. Its not instantaneous. But once the submovies get loaded, this doesn't happen.
I guess it's no big deal. You don't really notice it on a broadband connection, but on a modem connection, it's a little annoying...
Is that just the way it works??
Here is the URL I'm talking about:
http://www.dynamicpage.com
-
There something wrong with it
Theres something wrong with that. It looks to me that you have all the movies in the same _level. Doing this will close the open movie straight away. If you put each movie on a seperate level ie. _level0, _level1, _level2, etc. It will put the new movie ontop of the old so you shouldnt see that black.
Also are you preloading your external movies.
-
Yes, I've got 6 sections of my site (including the home section), and everytime you click on a button, I load a different submovie into level 0.
Would this work better...
Level 0 = main movie
Level 1 = movie1
Level 2 = movie2
Level 3 = movie3
Level 4 = movie4
Level 5 = movie5
-
Oh yes, and I also have preloaders in the main movie and all the submovies as well...
-
Cured i should think
As long as you put each movie in a seperate level it should get rid of that black.
They dont have to correspond.
-
Ok, I did that, I put all the movies on their own individual layers, and this is what happens...
The main movie goes in at level 0. When I click on EXTRANET, that loads movie4 into level 4. Then when I click on COMPANY, that loads movie1 into level 1, but since movie 5 is still playing on level 5, I can't see it.
Should I be unloading them or something??
-
Ok
I see what u mean. There is a way to tell it to appear but i'm not sure what it is. I'll look into it. Only other options are to unload as u said, or change the preloaders on the movies. If you used the main preloader to tell the other movies to load up at start then you could put all movies on level 0 and it would work instantly. However you would have to tell the main movie to load and at the same time tell the others to start loading while your viewing the main movie.
I think it would be better to find out the simple way to make it appear over the top of the other. I ashall look into it.
[Edited by dannyflounders on 06-02-2002 at 02:12 PM]
-
Yes, exactly! In all of my movies I have a nav bar on the left. Buttons 1-5 go to movies 1-5 loading on levels 1 - 5. Button 6 is the home button loading the main movie in level 0.
If I go into the main movie click on button 5, it loads movie5 into level5. Thats okay. But them if I'm in movie5 and click on button1, it loads movie1 into level1, and you can't see it because movie5 on level5 is covering it up. It just looks like you don't go anywhere...
Hmmmm.....
-
Its just a variable or something
It's just a variable or something, that u have to add to the button. I still think thts the best way to do it. If u hold a little while i'll find the answer somewhere.
-
Thanks Danny! I appreciate you helping me.
Are you talking about visible and invisible properties for movieclips maybe...
-
Try this
A guys just replied and suggested this, yes the visible thing, i dont think it will work but try.
try using setVisible=true with the buitton
action
or _alpha = 5
-
I kind of see what you are talking about, but I'm getting a little confused... I guess when the user clicks a button, I would use the setProperty function to set all the other movies _visible = false. Right?
-
Do this
I take your buttons look like this or similar.
on (release) {
loadMovieNum ("2.swf", 2);
Now all you add underneath is this line:
setProperty ("_level1", _visible, "true");
}
So to what u already have, add 'set property' add the level which the button refers to, add the visiblity property and type 'true' into the value, u will see what i mean when u click set property. Do this with every button, and it should work. I tried it with a test i just made and it worked. So after all that crap u probably didnt follow, your 1st button should look like this.
on (release) {
loadMovieNum ("company.swf", 0);
setProperty ("_level0", _visible, "true");
}
-
Another way
If u cant get that working, i found it a bit funny sometimes it would and then not.
If you leave all your movies in the levels, but put in the actions 'if frame (whatever) is loaded, move level to 0.
In other words u can let your movie as it is, but tell it to change to level 0 when its loaded. That way it would stay the same as it is now.
There is script in the flash help file to tell u how to change levels.
-
Danny,
I got it to work!!!!!
This is what I did...
I've got the main movie on level 0, and movies 1 - 5 on levels 1 - 5. When the user clicks on a button, it loads the appropriate movie AND sets the current level visibility to false.
Here's my code:
on (release) {
loadMovieNum ("DynamicPage_services.swf", 2);
setProperty ("_level3", _visible, false);
}
It looks good so far. When it first goes into each new level, you will get a blank black screen, but after each movie gets loaded the first time, it doesn't do that anymore. I'm not really worried about that, that's fine!!
Thanks for you help! I feel like I'm understanding this a little better now!!
-
Good, but!
Thats grea but your still back to square one, oh well at leas we give it ago. What i dont get is why if u set the visibility no 'false' it shows the movie? Puzzled!
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
|