Everything is okay but...
#1

Okay I got a problem, I made a admin command and not only admin cmd does not work, it is in ZCMD and when I complie no errors happen it just gives me "Unknown Command" when trying to use it here is a code

pawn Код:
CMD:freeze(playerid, params[])
    {
    if(PlayerInfo[playerid][Admin] >=1) return SendClientMessage(playerid, 0x0259EAAA, "You are not admin");
    {
        new id;
        if(sscanf(params, "u", id))
        {
            if(IsPlayerConnected(id))
            {
                new string[64];
                new name[MAX_PLAYER_NAME], PlayerName[MAX_PLAYER_NAME];
                GetPlayerName(playerid, name, sizeof(name));
                GetPlayerName(id, PlayerName, sizeof(PlayerName));
                format(string, sizeof(string), "Admin Action: Admin %s Has Feeze You", name);
                SendClientMessage(id, 0xFF0000FF, string);
                format(string, sizeof(string), "You Has Freeze %s", PlayerName);
                SendClientMessage(playerid, 0xFF0000FF, string);
                TogglePlayerControllable(id, 0);
                return 1;
            }
            else return SendClientMessage(playerid, 0x0259EAAA, "Player is not connected");
        }
        else return SendClientMessage(playerid, 0x0259EAAA, "USAGE: /freeze [PlayerId/PartOfName]");
    }
}
What is wrong? I even tried to do /me it didnt work either
Reply


Messages In This Thread
Everything is okay but... - by Tachibana - 21.06.2011, 16:53
Re: Everything is okay but... - by Wesley221 - 21.06.2011, 17:04
Re: Everything is okay but... - by Tachibana - 21.06.2011, 17:06
Re: Everything is okay but... - by Donya - 21.06.2011, 17:12
Re: Everything is okay but... - by Tachibana - 21.06.2011, 17:15
Re: Everything is okay but... - by Laronic - 21.06.2011, 17:16
Re: Everything is okay but... - by Tachibana - 21.06.2011, 17:17
Re: Everything is okay but... - by Laronic - 21.06.2011, 17:20
Re: Everything is okay but... - by Tachibana - 21.06.2011, 17:21
Re: Everything is okay but... - by Donya - 21.06.2011, 17:35

Forum Jump:


Users browsing this thread: 2 Guest(s)