02.06.2009, 19:26
Hello again!
I got a problem, after typing in a cmd like /afk or /back, it procceds the cmd and does like it should, but under every cmd in the game it says Server Unknown Command...
The cmds is:
Thanks for the help!
I got a problem, after typing in a cmd like /afk or /back, it procceds the cmd and does like it should, but under every cmd in the game it says Server Unknown Command...
The cmds is:
Код:
if (strcmp("/afk", cmdtext, true, 4) == 0) { new str[256], pname[256]; GetPlayerName(playerid, pname, 256); format(str, 256, "%s is now away from keyboard!", pname, cmdtext[4]); TogglePlayerControllable(playerid, false); SendClientMessageToAll(0xFF8000FF, str); }
Код:
if (strcmp("/back", cmdtext, true, 5) == 0) { new str[256], pname[256]; GetPlayerName(playerid, pname, 256); format(str, 256, "%s is now back on keyboard!", pname, cmdtext[5]); TogglePlayerControllable(playerid, true); SendClientMessageToAll(0xFF8000FF, str); }
Код:
if (strcmp("/pullover", cmdtext, true, 9) == 0) { if(GetPlayerTeam(playerid) != 1) return SendClientMessage(playerid, 0xFF0000AA, "You are not a Police Officer."); new string[128]; new adminname[MAX_PLAYER_NAME]; GetPlayerName(playerid,adminname,sizeof(adminname)); format(string, sizeof(string),"Officer %s says Pull Over Now!",adminname); SendClientMessageToAll(0x0000BBAA, string); }