PDA

View Full Version : Preloader


asdfblah
12-14-2008, 06:32 AM
I'm loading a movie from a file and want to make a preloader for the external file. What am I missing in this code?

loadMovieNum(gnodes[i].attributes.url, 2);
loaded = Math.round(_level2.getBytesLoaded());
total = Math.round(_level2.getBytesTotal());
getPercent = loaded/total;
loadtxt = getPercent+"%";

atomic
12-14-2008, 02:37 PM
A loop for one thing, like an onEnterFrame so that this is just not a one time check, but a looping check until the movie is fully loaded, after which you can move on and delete the onEnterFrame if that's what you used...

http://www.senocular.com/flash/tutorials/preloading/