Preloading external movie hell

  • weeble
  • Born
  • Born
  • weeble
  • Posts: 1

Post 3+ Months Ago

I'm really inexperienced with Flash, but working my way through tutorials and stuff to build a portfolio for my design company.

I've been trying to find a tutorial that suits my requirements exactly, but to no avail. :( And trying to adapt something similar is, well, a nightmare - its just too confusing about what scripts go in what movies etc. Wondered if anyone might be able to help here....

Basicaly, so far, I have a main movie (I'll call it Movie A). It contains three buttons - one is a link to a 'Portfolio'. Its stopped on frame 1 waiting for the user to make a click on a one ofthe buttons.

When you click 'Portfolio', it goes to frame 5 and stops, and plays a movie from the library (Movie B) which basically contains a load of buttons to different portfolios.

When you click say, 'Portfolio 1' button, it loads an external .swf movie into the same 'Movie B', on Level 1. Likewise, click 'Portfolio 2' and it loads a different swf movie into 'Movie B', also on level 1, thus replacing the previous movie.

Now, what I'm after is a way to preload each Portfolio movie, with a small percentage progress bar, everytime the relevant movie's button is pressed.

Am I going about this in the right way and is it possible? Anyone know of a tutorial that suits this kind of thing?

This tutorial has the kind of preloader I want, but it doesn't say anything about loading external movies... ... loader.htm

I'm using Flash 5, not MX, but I can always switch if needs be...

Any pointers much appreciated!

  • darkthroniar
  • Beginner
  • Beginner
  • User avatar
  • Posts: 42
  • Loc: Los Angeles, CA

Post 3+ Months Ago

hi weeble

just put the loader bar at the beggining of your external movie and that's it, when flash load your external movie it calls first the progress bar.
  • bdog01
  • Newbie
  • Newbie
  • bdog01
  • Posts: 10

Post 3+ Months Ago

1st of get flash mx 2004

then u cane create a movie clip object like this

Code: [ Select ]
var mcl = new MovieClipLoader();
var mclListener = new Object();

mclListener.onLoadStart = function(mclname)
//what to do when the movie clip starts

mclListener.onLoadError= function(mclname, errorCode)
//what to do if there is an error


mclListener.onLoadProgress = function(mclname, bl, bt)

//bl is the current bytes loaded
//bt is the total bytes
//use these to get your percentage

mclListener.onLoadInit = function(mclname)
//what to do when finished

//in each button do this
createEmptyMovieClip("navi", 1);
mcl.loadClip("navigation.swf", navi);
  1. var mcl = new MovieClipLoader();
  2. var mclListener = new Object();
  3. mcl.addListener(mclListener);
  4. mclListener.onLoadStart = function(mclname)
  5. {
  6. //what to do when the movie clip starts
  7. }
  8. mclListener.onLoadError= function(mclname, errorCode)
  9. {
  10. //what to do if there is an error
  11. }
  12. mclListener.onLoadProgress = function(mclname, bl, bt)
  13. {
  14. //bl is the current bytes loaded
  15. //bt is the total bytes
  16. //use these to get your percentage
  18. }
  19. mclListener.onLoadInit = function(mclname)
  20. {
  21. //what to do when finished
  22. }
  23. //in each button do this
  24. createEmptyMovieClip("navi", 1);
  25. mcl.loadClip("navigation.swf", navi);
  • spowart
  • Newbie
  • Newbie
  • User avatar
  • Posts: 12
  • Loc: London United Kingdom

Post 3+ Months Ago

Hi weeble,
I had the same problem but I have found a book which really helped me understand what was going on. However you would have to upgrade to Flash MX 2004 though. The book is: Macromedia Flash MX 2004 Beyond the Basics - Hands-On Training by Shane Rebenschied
ISBN: 0-321-22853-7

This book shows you how to build a complete wesite from start to finish and explains how to create a preloader for dynamicly loading content in when it is required, which I think is what you want as opposed to loading all the content at the beginning of the movie.

Hope this helps...

Post Information

  • Total Posts in this topic: 4 posts
  • Users browsing this forum: No registered users and 4 guests
  • You cannot post new topics in this forum
  • You cannot reply to topics in this forum
  • You cannot edit your posts in this forum
  • You cannot delete your posts in this forum
  • You cannot post attachments in this forum

© 1998-2017. Ozzu® is a registered trademark of Unmelted, LLC.