Hey guys,

I've got a preloader which has thh following code over three frames (it is inside a movie clip, located on the first frame):

Frame 1:

_parent.stop();

Frame 2:

kBytesLoaded = _parent.getBytesLoaded()/1024;
kBytesTotal = _parent.getBytesTotal()/1024;

kBytesRemaining = kBytesTotal - kBytesLoaded;
percentageLoaded = 100 * kBytesLoaded / kBytesTotal;
percentRemaining = 100 - percentageLoaded;
ProgressText = Math.floor(percentageLoaded) + "%";
ProgressText2 = Math.floor(kBytesLoaded) + " OF " + Math.floor(kBytesTotal) + " KBYTES LOADED";
loadBar._xScale = percentageLoaded;

Frame 3:

if (percentageLoaded < 99){
_parent.gotoAndPlay("Content");

} else {
   trace("error in label");
_parent.play();
stop();
}

The problem is it doesnt seem to load sound that is contained inside a mc on frame 2 of the timeline... how would I preload this?

Also, It always fails to go to the Content label - is my syntax correct? Should the label be an acnhor?

Thanks in advance -
NChhabra
_______________________________________________
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Reply via email to