04.07.2013, 11:01
On top of script:
new ReportTime[MAX_PLAYERS];
forward ReportTimer(playerid);
Then make a public:
public ReportTimer(playerid)
{
ReportTime[playerid] = 0;
return 1;
}
Then add under /report command:
if(ReportTime[playerid] == 1) return SendClientMessage(playerid, -1, "You can use this command each 30 seconds!");
ReportTime[playerid] = 1;
SetTimerEx("ReportTimer", 30000, false, "i", playerid);
new ReportTime[MAX_PLAYERS];
forward ReportTimer(playerid);
Then make a public:
public ReportTimer(playerid)
{
ReportTime[playerid] = 0;
return 1;
}
Then add under /report command:
if(ReportTime[playerid] == 1) return SendClientMessage(playerid, -1, "You can use this command each 30 seconds!");
ReportTime[playerid] = 1;
SetTimerEx("ReportTimer", 30000, false, "i", playerid);