SA-MP Forums Archive
Ban cmd - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: Ban cmd (/showthread.php?tid=439642)



Ban cmd - Yako - 26.05.2013

Hello everyone, I would like to ask, what is the best way to make /ban cmd with choosable time. I mean that you could choose hours, minutes or days. Thanks everyone for advices


AW: Ban cmd - Blackazur - 26.05.2013

Why you dont use something like this:

Код:
CMD:ban(playerid,params[])
{
    new id,reason,pName[MAX_PLAYER_NAME],string[128];
    if(sscanf(params,"uz[128]",id)) SendClientMessage(playerid,COLOR_RED,"System: /ban [ID]");
    else
    {
        if(PlayerInfo[playerid][pAdmin] >=4)
        {
            GetPlayerName(playerid, pName, MAX_PLAYER_NAME);
            format(string,sizeof(string),"Player %s was banned by %s Reason: %s",id,pName,reason);
            SendClientMessageToAll(COLOR_RED,string);
            BanEx(id,"reason");
        }
    }
    return 1;
}



Re: Ban cmd - Yako - 26.05.2013

I want to make temporary bans