SA-MP Forums Archive
question regarding points numbers - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: question regarding points numbers (/showthread.php?tid=650395)



question regarding points numbers - wallen - 26.02.2018

Look at that picture how do i make these numbers look like the moneys, that they start from 000000 and eventually when you earn a point you start to 0000034, etc.?? Already tried with something like float, but it fucks up and i get errors lol.

PHP код:
             format(InfoStringsizeof(InfoString), "%i"pInfo[playerid][Points]);
            
TextDrawSetString(CASH4[playerid], InfoString); 
That's actually how the code is made for showing points on TD.


Re: question regarding points numbers - DobbysGamertag - 27.02.2018

Код HTML:
    new number = 600;
    printf("%06d", number);
You're looking for the 06 part of the code above. It tells the function to pad zero's on up to the (n)th digit.

pawn Код:
%0(n)<specifier>



Re: question regarding points numbers - wallen - 27.02.2018

Thanks solved