Anonymous
public text v1 · immutablepublic OnPlayerText(playerid, text[])
{
new pname[256], string[256];
if(antispam == 1) {
Lines[playerid]++;
SetTimer("LineReset()", 20000, 0);
if(Lines[playerid] == max_lines ) {
GetPlayerName(playerid, pname, 256);
format(string, sizeof(string), "*** NoobBuster kicked %s from the server (spamming)", pname);
SendClientMessageToAll(COLOR_RED, string);
Kick(playerid);
printf("Kicked %s from the server for spamming", pname);
}
}
return 1;
}