multiple preloader question

  • zombiecrows
  • Newbie
  • Newbie
  • User avatar
  • Joined: Jun 02, 2004
  • Posts: 7
  • Status: Offline

Post June 2nd, 2004, 8:02 pm

Ahoy hoy everyone. I'm new here and I'm also making my first full fledged Flash website. You guys seem like you know what you're talking about and I could could use a little help. I was wondering how I might go about making multiple preloaders for a flash movie. I have each section broken down into different scenes and I wanna know what the proper scripting is to make a seperate preloader for each individual scene. Or would it just be better to make seperate SWF files rather then scenes?
  • Anonymous
  • Bot
  • No Avatar
  • Joined: 25 Feb 2008
  • Posts: ?
  • Loc: Ozzuland
  • Status: Online

Post June 2nd, 2004, 8:02 pm

  • UNFLUX
  • Genius
  • Genius
  • User avatar
  • Joined: Dec 20, 2002
  • Posts: 6396
  • Loc: unflux.net
  • Status: Offline

Post June 2nd, 2004, 8:55 pm

the best method for this is to use seperate swfs, and have a preloader at the beginning of each individual section. As for how to do this, preloader questions are among the most popular here, so you may want to try searching the board for tutorial links or even some direct help and code.

enjoy ozzu. :)
UNFLUX.net Hosting | Foto
Quality Web Hosting
  • zombiecrows
  • Newbie
  • Newbie
  • User avatar
  • Joined: Jun 02, 2004
  • Posts: 7
  • Status: Offline

Post June 3rd, 2004, 6:48 am

I'll be sure to take a look around for it. Thanks :)
  • toove_thing
  • Born
  • Born
  • No Avatar
  • Joined: May 10, 2006
  • Posts: 1
  • Status: Offline

Post May 10th, 2006, 8:27 pm

if you dont want to separate your pages into sections and individual swf files you should use the getBytesTotal(movie) and getBytesLoaded(movie) function. heres an example ive done:

onClipEvent (load) {
total = _root.getBytesTotal(your_movie);
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded(your_movie);
percent = int(loaded/total*100);
text = percent+"%";
gotoAndStop(percent);
if (loaded == total) {
_root.gotoAndPlay(2);
}
}

this script was placed on the preloader movie, so that when it loads, it shows how much has been loaded graphically.

the initial handler returns the total bytes from your movie that is placed in frame 2 at the _root of your scene, the second says "how much of the movie has been loaded already?" it then works out the percentage of the total loaded/total bytes and then says "well, if it is less than 100% keep loading and stay on this frame, but when it reaches 100%, gotoAndPlay frame 2 of the _root." (like every other preloader you have probably written...) Meanwhile it plays a little animation of the movie that the above string was written on.

Post Information

  • Total Posts in this topic: 4 posts
  • Users browsing this forum: No registered users and 54 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
 
cron
 

© Unmelted Enterprises 1998-2009. Driven by phpBB © 2001-2009 phpBB Group.