19.02.2009, 02:02
Use this:
Код:
if(strcmp(cmd, "/cmd", true) == 0) { new tmp[256]; tmp = strtok(cmdtext, idx); if(!strlen(tmp)) { SendClientMessage(playerid,COLOR_WHITE,"USAGE: /cmd [1/0]"); return 1; } if(strcmp(tmp,"0",true) == 0) { print("zero"); return 1; } else if(strcmp(tmp,"1",true) == 0) { print("one"); return 1; } else // Other = Error message { SendClientMessage(playerid, COLOR_WHITE, "ERROR: /cmd [1/0]"); return 1; } }