01.07.2009, 08:18
Код:
public OnPlayerCommandText(playerid, cmdtext[]) { if (!IsPlayerConnected(playerid)) return 0; new string[MAX_STRING]; new cmd[MAX_STRING]; new giveplayerid, moneys, idx, weaponid; new tmp[MAX_STRING], tmp2[MAX_STRING], tmp3[MAX_STRING]; new Float:x, Float:y, Float:z; cmd = strtok(cmdtext, idx); strmid(tmp, cmd, 1, strlen(cmd)); for (new k=0;tmp[k];k++) { if ('a' <= tmp[k] <= 'z' || 'A' <= tmp[k] <= 'Z' || 0 <= tmp[k] <= 9) { } } }
And I feel obligated to add: https://sampwiki.blast.hk/wiki/Fast_Commands