How about...

if ( percentage % 10 == 0 ) {
        trace("Another 10% loaded");
}

Ade

-----Original Message-----
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] Behalf Of Matt Ganz
Sent: 16 November 2005 21:31
To: Flashcoders mailing list
Subject: [Flashcoders] tracing every 10% of loading files


hi.

hopefully this question isn't too newbie.

i'm loading a bunch of external swfs and i am trying to determine what
percentage of 'totalWeight' is 'currentWeight'. here's my equation:

var percentage = (currentWeight/totalWeight) * 100;

i believe that's fine. but my question is how can i express the following:

"for every increase of 10%, up to 100%...." // trace( "another 10% loaded" )

thanks. -- matt.

_______________________________________________
Flashcoders mailing list
[email protected]
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Reply via email to