Could this work? please answer!
#8

ok, this work well, but don't ask for reazon... just ban! I want this to tell the reazin too! But in my script form... Or just tell me what to add! THANKS

pawn Код:
COMMAND:iban(playerid, params[])
{
    new id;
    if(IsPlayerConnected(id))
    {
        if(IsPlayerAdmin(playerid))
        {
            if(!sscanf(params, "ui", 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), "You has been banned by %s.", name);
                SendClientMessage(playerid, 0x0259EAAA, string);
                format(string, sizeof(string), "You banned %s.", id);
                SendClientMessage(playerid, 0x0259EAAA, string);
                Ban(id);
                return 1;
            }
            else return SendClientMessage(playerid, 0x0259EAAA, "USAGE: /ban [PlayerId/PartOfName]");
        }
        else return SendClientMessage(playerid, 0x0259EAAA, "You are not admin.");
    }
    else return SendClientMessage(playerid, 0x0259EAAA, "Player is not connected.");
}
Reply


Messages In This Thread
Could this work? please answer! - by ricardo178 - 14.03.2011, 12:55
Re: Could this work? please answer! - by Macluawn - 14.03.2011, 13:01
Re: Could this work? please answer! - by HyperZ - 14.03.2011, 13:02
Re: Could this work? please answer! - by Macluawn - 14.03.2011, 13:04
Re: Could this work? please answer! - by Markx - 14.03.2011, 13:05
Re: Could this work? please answer! - by HyperZ - 14.03.2011, 13:05
Re: Could this work? please answer! - by ricardo178 - 14.03.2011, 13:11
Re: Could this work? please answer! - by ricardo178 - 14.03.2011, 13:54

Forum Jump:


Users browsing this thread: 1 Guest(s)