Help me
#9

I gave to all +Rep .. Thx all for the help and i have a new question , how can i check if a player enter in te inputtext a message like that : [DD/MM/YYYY] ? I need it to save player birthday xD [Am thx for replay so fast]

Quote:
Originally Posted by !damo!spiderman
Посмотреть сообщение
I made this up for you... haven't really optimized it at all but it works with any value

PHP код:

stock formatMoney
amount,output[64],delimiter[2]=","){
    
format(outputsizeof(output), "%i"amount );
    if(
strlen(output) > 3){
        for(new 
0= (strlen(output)/3); j;  i++){
            
strins(outputdelimiterstrlen(output)-(((i+1)*3)+i) );
        }
    }
}
// usage
new money 59329192;
new 
str[64];
formatMoney(moneystr"." );
printf(str); // Prints 59.329.192
formatMoney(moneystr );
print(
str); // Prints 59,329,192 
Or i can simple modify

Код HTML:
stock formatMoney( amount,output[64],delimiter[2]=","){
in
Код HTML:
stock formatMoney( amount,output[64],delimiter[2]="."){
and use like this

Код HTML:
new String[64];
formatMoney(GetPlayerMoney(playerid), String)
And i don't need to put "."
Reply


Messages In This Thread
Help me - by Mariciuc223 - 15.07.2015, 09:47
Re: Help me ++REP - by notime - 15.07.2015, 10:37
Re: Help me ++REP - by !damo!spiderman - 15.07.2015, 10:39
Re: Help me ++REP - by notime - 15.07.2015, 10:42
Re: Help me - by liquor - 15.07.2015, 10:47
Re: Help me - by !damo!spiderman - 15.07.2015, 10:52
Re: Help me - by liquor - 15.07.2015, 10:55
Re: Help me - by Virtual1ty - 15.07.2015, 12:27
Re: Help me - by Mariciuc223 - 15.07.2015, 12:45

Forum Jump:


Users browsing this thread: 6 Guest(s)