SA-MP Forums Archive
Variables - 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: Variables (/showthread.php?tid=487896)



Variables - Lidor124 - 15.01.2014

Hi all
i want to make some little things that i not sure how to make them, could you help?

for example: i have dealership system in my script, there are 3dTextlabel on the vehicles of the price of the dealership vehicle:
Huntley for sale | Price: $200000

I want to make it count the thousands or hundreds or whatever with ,

Result:
Huntley for sale | Price: $200,000
or 10000 = $10,000

second question:
how to make time of counting 60 seconds for each minute during 15 minutes, i mean the coundown is 15 minutes to zero, what means GameTextForPlayer will show up each 60 seconds or 1 minute past... example:

min/sec
14:59
14:58
14:57
etc.... (timer for countdown of 15 minutes)

Thanks in advance


Re: Variables - Konstantinos - 15.01.2014

1) https://sampwiki.blast.hk/wiki/AddCommas
2) Search, there are many threads about time convertions.


Re: Variables - Lidor124 - 15.01.2014

How do i put a variable on this function AddCommas?

my variable is BizInfo[idx][bMoney] so:

AddCommas(BizInfo[idx][bMoney]; ?


Re: Variables - Zjiht - 15.01.2014

I haven't scripted Pawn in a long time but this is how I would try it;

AddCommas(BizInfo[dix][bMoney]);