18.11.2013, 21:53
Just add this below IsPlayerNPC.
Also you don't need to create extra timer to reset the JustReported variable.
Simple create a variable, which saves the time of using this command.
Example
pawn Код:
if(!IsPlayerConnected(giveplayerid)) return SendClientMessage(playerid, COLOR_RED, "Player is not connected.");
if(PlayerInfo[giveplayerid][pLogged] == 0) return SendClientMessage(playerid, COLOR_RED, "Player is not logged in.");
Simple create a variable, which saves the time of using this command.
Example
pawn Код:
JustReported[playerid] = gettime();
pawn Код:
if((gettime() - JustReported[playerid]) < 20) return SendClientMessage(playerid, COLOR_GREY, "Wait 20 seconds after sending a next /report ! ");