Quantcast
Channel: SA-MP Forums
Viewing all articles
Browse latest Browse all 18226

ZCMD error command

$
0
0
Hello! I've made a kick zcmd command but it doesn't do anything

Help me please! Here is the code of the command
Code:

COMMAND:kick(playerid, params[])
{
    new pid, reason[105];
    if(PlayerInfo[playerid][pAdmin] <= 2) return SendClientMessage(playerid, 0xAAAAAAAA, "ERROR: Íÿìàø ëåâúë çà òàçè êîìàíäà");
        if(PlayerInfo[playerid][pAdmin] >= 3)
        {
    if(sscanf(params, "us[128]", pid, reason)) return SendClientMessage(playerid,  0xFFFFFFFF, "Èçïîëçâàé: /kick [playerid/name] [reason]");
    if(IsPlayerConnected(pid) && pid != INVALID_PLAYER_ID && pid != playerid)
        {
            new adminname[MAX_PLAYER_NAME], paramname[MAX_PLAYER_NAME], string[180];
            GetPlayerName(pid, paramname, sizeof(paramname));
            GetPlayerName(playerid, adminname, sizeof(adminname));
            format(string, sizeof(string), "%s áåøå èçõâúðëåí îò ñúðâúðà îò %s![Ïðè÷èíà:%s]", paramname, adminname, reason);
            SendClientMessageToAll(0xCC0000FF, string);
            Kick(pid);
          }
        else return SendClientMessage(playerid, 0xFFFFFFFF, "Òîâà ñè òè èëè íÿìà òàêúâ èãðà÷");
        }
    return 1;
}

Thanks in advance! :)

Viewing all articles
Browse latest Browse all 18226

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>