Hey I love how clients make you change things left and right but ohhh well.
I was wondering if any of you can help me out a little.
I have a preloader that loads a external SWF in a movie clip on the main timeline. right now it automaticly starts the external SWF. My client wants me to make a button that will start the preloaded swf instead of it automaticly starting.
the code that I have at the moment:
siteLoader.loadMovie("http://www.quroscuro.com/bd/index2.swf");
loadingBar._xscale = 1;
loadingBar.onEnterFrame = function() {
kBytesLoaded = this._parent.siteLoader.getBytesLoaded() / 1024;
kBytesTotal = this._parent.siteLoader.getBytesTotal() / 1024;
percentage = Math.round(kBytesLoaded / kBytesTotal * 100);
this._xscale = percentage;
if (percentage == 99) {
this._parent.frameBar._alpha = false;
this._alpha = 0;
delete this.onEnterFrame;
}
}
I will make a button that is enter_btn and tagged that way for usage.
so I am guessing some where in the actionscript I will have to put something like.
enter_btn.onPress = function () {start(index2.swf);}
but I am sure I am quite wrong with this. But I need to know what to change to the first code and how to call the action to start the clip for the onPress = function.
I still need the progress bar to show till it is fully loaded and the switch to say frame 2 of the movie where the enter button is and it doesn’t show the progress bar anymore. and then when you click the enter button it starts the preloaded external swf.
I appreciate any help that anyone can give me on this. I am still learning actionscript and still getting the basic understanding of how it works.
Thanks again.