Time script? - 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: Time script? (
/showthread.php?tid=553065)
Time script? -
JohnBlade - 27.12.2014
How do i make a roleplay time script?
Like /time and then the roleplay comes and then the time?
Anybody know?
Re: Time script? -
JohnBlade - 27.12.2014
Anyone
Respuesta: Time script? -
Zume - 28.12.2014
https://sampforum.blast.hk/showthread.php?tid=533391
Example:
pawn Код:
CMD:time(playerid, params[])
{
new date[6], string[45];
gettime(date[0], date[1], date[2]);
getdate(date[3], date[4], date[5]);
format(string, sizeof(string), "%s %i de %s del %i - %i:%i:%i", GetDayOfWeek(date[3], date[4], date[5]), date[5], GetMonthName(date[4]), date[3], date[0], date[1], date[2]);
SendClientMessage(playerid, -1, string);
return 1;
}
or
pawn Код:
CMD:time(playerid, params[])
{
new time[3], string[45];
gettime( time[0], time[1], time[2] );
format(string, sizeof(string), "%i:%i:%i", time[0], time[1], time[2]);
SendClientMessage(playerid, -1, string);
return 1;
}
this ?