Forum Topic: Teach Me How To Make A Preloader!

(143 views • 9 replies)

This topic is 1 page long.

<< < > >>
None

Stagnant

Reply To Post Reply & Quote

Posted at: 6/5/06 12:29 PM

Stagnant FAB LEVEL 09

Sign-Up: 06/02/06

Posts: 1,232

Please can someone write down a tutorial of how to make a preloader.

Thanks.

Pestiside can't kill me!

BBS Signature

None

IngramJ

Reply To Post Reply & Quote

Posted at: 6/5/06 12:35 PM

IngramJ EVIL LEVEL 27

Sign-Up: 02/15/06

Posts: 391

You don't have to make your own, you can just download the default NG one. If that's not enough, I think there was also a tutorial on preloaders with the NG preloader download.

DROPPING YOUR PANTS ON STAGE DOES NOT DEPLOY STAR POWER.

BBS Signature

None

Jovatov

Reply To Post Reply & Quote

Posted at: 6/5/06 12:35 PM

Jovatov LIGHT LEVEL 16

Sign-Up: 04/26/04

Posts: 1,879

I used this one.


None

Stagnant

Reply To Post Reply & Quote

Posted at: 6/5/06 12:37 PM

Stagnant FAB LEVEL 09

Sign-Up: 06/02/06

Posts: 1,232

If i wanted to use the NG one i wouldn't be asking for this.

Pestiside can't kill me!

BBS Signature

None

zuperxtreme

Reply To Post Reply & Quote

Posted at: 6/5/06 12:45 PM

zuperxtreme NEUTRAL LEVEL 07

Sign-Up: 01/02/05

Posts: 987

its not so hard
let me explain :)

first of all youll need to figur out how long the movie is (in bytes)
and how much has loaded so far (also in bytes)
fot that youll use getBytesTotal(); and getBytesLoaded(); respectavely
then youll need to find out the percentage of how much is loaded of the total
total/loaded*100;
then there u can let ur imagination run wild..
u can scale a bar
use percent text etc..
heres an example for a bar preloader

place this in the first frame(preferably in a movie clip)

_root.stop();//stops main timeline
_root.onEnterFrame=function(){//every frame..
if(Dled!=100){//if not dled yet..
Total=_root.getBytesTotal();//get total
Loaded=_root.getBytesTotal();//get loaded
Dled=Total/Loaded*100;//get your percentage
bar._xscale=Dled;//scale the "bar" mc's x
}else{
_root.play();//if done play
}
}

you have to make an mc and give it an instance name of "bar"
this should work.. :P
havent tested it but yea.. that the main idea behind all of this..
if u didnt understand something , post here so we can clear things up for you :D

good luck


None

IngramJ

Reply To Post Reply & Quote

Posted at: 6/5/06 12:46 PM

IngramJ EVIL LEVEL 27

Sign-Up: 02/15/06

Posts: 391

Oh. Never mind then.

DROPPING YOUR PANTS ON STAGE DOES NOT DEPLOY STAR POWER.

BBS Signature

None

Stagnant

Reply To Post Reply & Quote

Posted at: 6/5/06 01:07 PM

Stagnant FAB LEVEL 09

Sign-Up: 06/02/06

Posts: 1,232

Can you explain that again for me please?

Pestiside can't kill me!

BBS Signature

None

zuperxtreme

Reply To Post Reply & Quote

Posted at: 6/5/06 01:13 PM

zuperxtreme NEUTRAL LEVEL 07

Sign-Up: 01/02/05

Posts: 987

sure :)

what you need to do is 4 things

1)How big your movie is
2)How much you loaded
3)Find the percentage loaded
4)act accordingly..

soo
here it goes

_root.stop();
//stops main timeline
_root.onEnterFrame=function(){
if(Dled!=100){
//if Dled != 100..("!=" means NOT EQUAL)
Total=_root.getBytesTotal();
//total bytes
Loaded=_root.getBytesLoaded();
//loaded so far bytes
Dled=Total/Loaded*100;
//percentage loaded so far..
bar._xscale=Dled;
//scale the bar according to the Dled variable
}else{
_root.play()
//if loaded then play main timeline
}

you have to make an mc and give it an instance name of "bar" for the bar to scale else it wont..

that should work..
if you want to see the loading put : trace(Loaded);
inside the onEnterFrame

hope You understand me better this time :)


None

Bezman

Reply To Post Reply & Quote

Posted at: 6/5/06 03:44 PM

Bezman FAB LEVEL 29

Sign-Up: 08/16/01

Posts: 2,644

At 6/5/06 01:13 PM, zuperxtreme wrote: <>

I'd add that I think it's good practise to explicitly declare all variables.


None

Dragon909

Reply To Post Reply & Quote

Posted at: 6/5/06 03:54 PM

Dragon909 NEUTRAL LEVEL 08

Sign-Up: 12/16/05

Posts: 77

Its actually very easy to do. I've got one on the school Network, which I'll make a tutorial from. I've also got one on this PC, but I'm not in a flash mood at the mo.


All times are Eastern Standard Time (GMT -5) | Current Time: 07:54 AM

<< Back

This topic is 1 page long.

<< < > >>
You need a Grounds Gold Account to post on the NG BBS! If you don't have one, click here to sign up now! It's fast, free, and easy — and opens up tons of great NG features!