GetWorldTime (something like this Please)
#1

I am writing script from beginning, and now it's time to make payday system, I know how to make that, with timer, but I don't know how to get Server time, when it is xx:00 payday should show for each player who have enough payday points, If i use timers, it should be 09:25| 10:25| 11:25, you know.... depending when I start gamemode.. ?
sry 4 bad english
Reply
#2

https://sampwiki.blast.hk/wiki/Gettime

Use the gettime() function, store what it returns into variables and run a check like this:

pawn Код:
if(mins == 0)
{
   // do your stuff
}
Where "mins" is the variable you assigned minutes to be put in to.
Reply
#3

Thank you, but I have 2 questions..
Will that get Player's time or Server time, and i should set timer with repeating every 1 minute, to check that time, and show player payday?
Reply
#4

It will get the server time, not the player's time.

It would be a good idea to put it in a repeating one minute timer, yes.
Reply
#5

I succesfully made it, thank you master
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)