Since my
previous preload antics left everybody puzzled, i thought I'd try a different approach and started messing with the xscale principle...
But it won't work... it -snip- won't work...
The preloader (also the one in the previous thread) works as follows:
- onRelease set var containing the to be loaded SWF +
- gotoAndPlay the cover-over animation which contains also the loadMovie action + the loadBar (frame 15)
- Arrives at frame 15, and loadMovie the swf in the var
- Frame 1 of the external SWF contains the preload script and it tells the _root.cover.loadBar part to move accordingly to the amount of bytes loaded / or in this case it tells the _root.cover.loadBar.bar to xscale accordingly to the amount of bytes loaded/100
- when finished loading the external SWF preload script tells _root.cover to play the Open part... and to itself to gotoAndPlay frame 3...
But it doesn't work... sigh
It %$#$@$@$ doesn't work... sob
Why... why not?
It seems to hang on the open part (that's frame 16 of the cover)
Code:
onClipEvent (load) {
// get total bytes
// we put this in a load event because we only need to get total bytes once
tkb = _root.content.getBytesTotal();
}
onClipEvent (enterFrame) {
// calculating bar lenght
scale = ((_root.content.getBytesLoaded()/tkb)*100);
// setting the progress bar lenght
_root.cover.loadBar.bar._xscale = scale;
// Check if it's loaded and do whatever after
if (scale == 100) {
_root.content.gotoAndPlay(3);
_root.cover.gotoAndPlay("open");
}
}
The source...
http://www.e-llumination.net/actions...loadxscale.zip
Your help (with this or the other thread) would be much appreciated (some encouraging words as well)...