Server Time - 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)
+---- Forum: Help Archive (
https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: Server Time (
/showthread.php?tid=122251)
Server Time -
Oi! - 20.01.2010
How can I make it so that players can only enter a building at certain hours on the server, EG: 6am - 6pm, can anyone help me?
Re: Server Time -
Oi! - 21.01.2010
Lets put it this way. Okay, say I go up to an Enter Icon, and type /enter, but it's before 6:00 or past 18:00 it will say "Business Hours between 6:00 AM to 6:00 PM. Hope that helps.
Re: Server Time -
sanandreas - 21.01.2010
check this out man
https://sampwiki.blast.hk/wiki/GetPlayerTime
Re: Server Time -
Calgon - 21.01.2010
Add under your /enter command:
pawn Код:
SetPlayerTime(playerid, 0, 0);
@sanandreas -
https://sampwiki.blast.hk/wiki/SetPlayerTime, not GetPlayerTime.
Re: Server Time -
woot - 21.01.2010
CalgonX, re-read his post.
OP: use the gettime() function. Then just do a check, very simple.
https://sampwiki.blast.hk/wiki/Gettime