#define MaxSlots 200
new pTimerTemp[MaxSlots];
new pNameTimer[MaxSlots];
new bool:zOnly[MaxSlots];
new bool:zRept[MaxSlots];
new zTimerSave[MaxSlots];
public
OnPlayerUpdate(playerid)
{
if(zOnly[playerid] == true)
{
if(GetTickCount() - zTimerSave[playerid] >= pTimerTemp[playerid])
{
zTimerSave[playerid] = GetTickCount();
if(zRept[playerid] == false) zOnly[playerid] = false;
CallRemoteFunction(pNameTimer[playerid],"i",playerid);
}
}
return true;
}
stock
SetPlayerTiming(zName[24],zTimer,bool:zRepeat,iPlayer)
{
pTimerTemp[iPlayer] = zTimer;
strins(pNameTimer[iPlayer],zName,0,24);
zRept[iPlayer] = zRepeat;
zTimerSave[iPlayer] = GetTickCount();
return zOnly[iPlayer] = true;
}
Ele chama qualquer CallBack de qualquer Script do Servidor
~DraKiNs
Nenhum comentário:
Postar um comentário