Hey all
Using the preloader from Smooth tranisitions tut, which is basically a on clip event loop that checks the Total bytes loaded ect… and indicates when the preloader is _visable (if you want to know exactly what i mean check this link … http://www.tableau.com.au/tutorials/smooth_transitions/ )
this.onEnterFrame = function() {
//this checks to see if the content on this timeline is still loading
if (this.getBytesLoaded()<this.getBytesTotal()) {
//make the preloader visible
_level0.preloaderGraphics._visible=true;
//make a variable to store the total file size of this timeline
Total = this.getBytesTotal()/1000;
//make a variable to store the amount of this timeline that has loaded
Received = this.getBytesLoaded()/1000;
//make a variable to store the percentage loaded
Percentage = (Received/Total)*100;
//target the text box in the preloaderGraphics mc and tell it what to display
_level0.preloaderGraphics.percent = int(Percentage) add "%";
//change the x scale of the progess bar to indicate how much has loaded
_level0.preloaderGraphics.progressBar._xscale = Percentage;
} else {
//play the intro animation
this.gotoAndPlay("intro");
//turn off the enterFrame action
this.onEnterFrame = null;
//hide the preloader
_level0.preloaderGraphics._visible=false;
}
};
//stop this timeline while it loads
stop();
this works all fine, though i would prefer if i could have my preloader show for a few seconds even if the movie has been preloaded. I would usually run some variables with some if statments to do this, but with a preloader like the one im using has got me stumped. I’ve come to the conclusion that maybe a delay could be used to let the preloader stay those few seconds (maybe let the dyamic text box read “loaded”).
Any help will be great, thanks
Soulty::