mIRC Homepage
Posted By: NightChillz making 10000000 = 10,000,000 ? - 26/12/02 11:22 PM
Hey , i am workin on this game still, all is going good, but some ppl seem to have "trouble" or just "dont like" having to try to figure out what they won or have by counting the zero's(0) in their points when its shown like: 10000000

I have been asked to make it show the points in this format: 10,000,000 etc, so i am looking for something to help me in the right direction for adding a ,($chr(44)) after every 3rd(third) 0(zero) in a users score starting at the right going to the left, few examples:

100 = 100
1000 = 1,000
10000 = 10,000
100000 = 100,000
1000000 = 1,000,000

and so on and so forth....Thanks in advance for any help or pointers to come.....i have a "idea" that it might be done with $mid, and/or $pos possibly, not totaly sure, thats why i'm asking wink
Posted By: Nimue Re: making 10000000 = 10,000,000 ? - 26/12/02 11:34 PM
//echo -a $bytes(1000000,b)
Posted By: NightChillz Re: making 10000000 = 10,000,000 ? - 26/12/02 11:41 PM
Damn, i should have know that, lol, not too long ago made a "file info" dialog, lmao....just wasnt thinking about that...was thinking something in the $calc area....but thanks alot grin
© mIRC Discussion Forums