11.09.2012, 07:09
If you're using a Gamemode, use OnGameModeInit(), otherwise use OnFilterScriptInit()
This is your first code:
Place this at the bottom of your script. (Preferably)
I'm assuming this is what you're looking for, but I can't be too sure, because you haven't explained very well.
This is your first code:
pawn Код:
public OnGameModeInit() //Or OnFilterScriptInit() if you're using a filterscript.
{
SetTimer("RenewTime", 1000, true);
return 1;
}
pawn Код:
forward RenewTime();
public RenewTime()
{
new hour, minute, second;
gettime(hour, minute, second);
for(new i = 0; i < MAX_PLAYERS; i++)
{
if(IsPlayerConnected(i))
{
SetPlayerTime(i, hour, minute);
}
}
return 1;
}

