|
Re: preloader not working with a sliding menu script
why not just put the preloader on the 1st frame of the 2nd scene?
or perhaps you could try..
w = 0;
stop();
onEnterFrame = function () {
myload = _parent.getBytesLoaded();
mytotal = _parent.getBytesTotal();
mypercent = myload/mytotal*100;
//
w += (mypercent*2-w)/3;
mcStroke._width = Math.round(w);
mcBar._width = mcStroke._width;
mcLine._x = mcStroke._width;
//
if (mypercent>10) {
txt.text = Math.round(mypercent);
txt._x = mcLine._x-20;
}
/*
Here you can add the code to execute when loading is complete
*/
if (myload == mytotal) {
gotoAndStop("main",1);
}
};
|