SA-MP Forums Archive
how? - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+---- Forum: Help Archive (https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: how? (/showthread.php?tid=191846)



how? - dark_clown - 20.11.2010

how can i detect if a play'a does OnPlayerText ex:
/q or best tele ever /q
if he does so kick player and sendclientmessage you sir are a moron


Re: how? - Calgon - 20.11.2010

https://sampwiki.blast.hk/wiki/Strfind

pawn Код:
public OnPlayerText(playerid, text[]) {
if(strfind(text, "/q", true) != -1)
{
    SendClientMessage(playerid, 0xFFFFFFFF, "you sir are a moron");
}
}