string
#1

how do u get commers to show in client messages .

e.g

Now
$16000

how we want it
$16,000

how do we get the money in the client messages to show up like this.
Reply
#2

https://sampforum.blast.hk/showthread.php?tid=184328
Reply
#3

PHP код:
stock FormatNumber(value) //RyDeR`
{
    new
        
string[24]
    ;
    
format(string, sizeof(string), "%d", value);
    
    for(new 
i = (strlen(string) - 3); i > (value < 0 ? 1 : 0) ; i -= 3)
    {
        
strins(string[i], ",", 0);
    }
    return 
string;
} 
Example:

PHP код:
new string[124];
format(string, sizeof(string),"$%s", FormatNumber(16000));
SendClientMessage(playerid, COLOR_GREY, string); 
Reply


Forum Jump:


Users browsing this thread: