SA-MP Forums Archive
How to disable all commands EXCEPT /leave - Using ZCMD - 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)
+--- Thread: How to disable all commands EXCEPT /leave - Using ZCMD (/showthread.php?tid=376475)



How to disable all commands EXCEPT /leave - Using ZCMD - denNorske - 10.09.2012

Hi!

The title explains most of my question.

I know how to disable all commands except one, by using strcmp, but my problem is that the whole gm uses ZCMD, and i have no idea how to disable all commands except from the
CMD:leave(playerid, params[])

Any ideas how i can do that?

Thanks


Re: How to disable all commands EXCEPT /leave - Using ZCMD - HuSs3n - 10.09.2012

pawn Код:
public OnPlayerCommandPerformed(playerid, cmdtext[], success)
{
    if(strcmp(cmdtext,"leave")) return 1;
    return 0;
}
untested