Is there anyway to bypass a preloader if the entire file is already loaded, e.g. missing the intro? I have tried using the ShardObject code quite unsucsessfully, the code I used was:
[AS]
//stop before running into the next scene
stop();
//check if there is already the SharedObject
gn = SharedObject.getLocal(“GamesNetwork”);
if (gn.data.visited == 1) {
nextScene;
} else {
//create a variable in the SO
gn.data.visited = 1;
//write the SO
gn.flush();
//set the function “preloader” to run every 10ms
myInterval = setInterval(preloader, 10);
//define the function preloader
function preloader() {
//check to see if it is fully loaded
if (getBytesLoaded()>=getBytesTotal()) {
clearInterval(myInterval);
play();
}
// define the variable percentile as the percent loaded for future use
percentile = (getBytesLoaded()/getBytesTotal()*100);
//set the alpha of the logo
this.earthLogo._alpha = percentile;
//set the length of the percent bar
this.bar._xscale = percentile;
}
}
[/AS]