View Full Version : Preloader frustration
DiscoSuperfly
January 29th, 2004, 09:46 AM
I have a slide show that's about 800k and I'm trying to add a preloader. I tried 6 different preloaders today including a smart clip I downloaded from Macromedia. It seems that when I add a stop action after the preloader this hangs the entire movie. I've uploaded a working example of the slideshow without a preloader and a link to the fla of my NON-working attempt to apply the smart clip preloader here (http://www.boundless.net/test.html)
I think I'm just putting the stop action in the wrong place but I can't figure it out..
thanks again for any help..
Troy
claudio
January 29th, 2004, 10:11 AM
Whats your email so I can send you a fla?
If you dont want to display it here, PM me.
DiscoSuperfly
January 29th, 2004, 10:15 AM
tenke1 AT iwon.com
claudio
January 29th, 2004, 10:22 AM
Just sent you the file.
DiscoSuperfly
January 29th, 2004, 10:36 AM
Thanks for the quick response! The preloader works great but the slideshow doesn't appear after the loader completes. This is the same problem I've had with the other preloaders I've tried. I can't figure out whether it's a stop action in the wrong place or if it's a masked layer issue. Would you mind inspecting the code to see if something jumps out at you? Sometimes a fresh pair of eyes does wonders.
I uploaded the swf at the bottom of the page here. (http://www.boundless.net/test.html)
claudio
January 29th, 2004, 10:40 AM
Ops, my bad.
Replace the code on the first frame for this one:
bar.onEnterFrame = function() {
var t = this._parent.getBytesTotal(), l = this._parent.getBytesLoaded(), p = l/t;
if (t) {
if (l == t) {
this._parent.gotoAndStop(2);
delete this.onEnterFrame;
}
this._parent.percent = "Loading "+Math.round(p*100)+" %";
this._width = p*this._parent.border._width;
}
};
this.stop();
DiscoSuperfly
January 29th, 2004, 10:44 AM
same result... preloader works but the slides don't appear and the buttons stop working..
claudio
January 29th, 2004, 10:49 AM
Double click your main movieclip. On the first frame, use this code instead:
POZ = new Array("-550", "-1100", "-1650", "-2200", "-2750", "-3300", "-3850", "-4400");
rot = POZ[0];
DiscoSuperfly
January 29th, 2004, 11:13 AM
I replaced
_root.onLoad = function() {
POZ = new Array("-550", "-1100", "-1650", "-2200", "-2750", "-3300", "-3850", "-4400");
rot = POZ[0];
};
_root.onEnterFrame = function() {
r += (rot-r)/5;
ALL._x = r;
};
with the code you provided and got the same result.. I also tried just replacing the
POZ = new Array("-550", "-1100", "-1650", "-2200", "-2750", "-3300", "-3850", "-4400");
rot = POZ[0];
with your code and the same thing happened.. When you view the movie are you getting the same result?
claudio
January 29th, 2004, 11:16 AM
Sorry, i think i wasnt clear enough, my bad.
You need to use both
bar.onEnterFrame = function() {
var t = this._parent.getBytesTotal(), l = this._parent.getBytesLoaded(), p = l/t;
if (t) {
if (l == t) {
this._parent.gotoAndStop(2);
delete this.onEnterFrame;
}
this._parent.percent = "Loading "+Math.round(p*100)+" %";
this._width = p*this._parent.border._width;
}
};
this.stop();and
POZ = new Array("-550", "-1100", "-1650", "-2200", "-2750", "-3300", "-3850", "-4400");
rot = POZ[0];
_root.onEnterFrame = function() {
r += (rot-r)/5;
ALL._x = r;
};
And it works for me.
DiscoSuperfly
January 29th, 2004, 11:25 AM
Thank you soooo much!! You just ended 3 days of frustration.
claudio
January 29th, 2004, 11:27 AM
Welcome :)
Powered by vBulletin® Version 4.1.10 Copyright © 2012 vBulletin Solutions, Inc. All rights reserved.