[HELP] Unban CMD
#1

hello there, i got problem, i have the gm revolution survival and im intersted on that.. it has ban command but doesnt have unban, anyone can make unban cmd for it?

here is the code of ban cmd

Код:
CMD:ban(playerid, params[])
	{
	    new
	        giveplayerid,
	        szReason[32];

		if(sscanf(params, "us[32]", giveplayerid, szReason))
  		return SendClientMessage(playerid, RED, "[Database:]{FFFFFF} /ban [ID] [REASON]");

	    if(IsPlayerNPC(giveplayerid))
	        return SendClientMessage(playerid, RED, "[Database:]{FFFFFF} You cant kick npcs");

	    if(AccountInfo[playerid][pAdmin] >= 2) {
	        if(giveplayerid != INVALID_PLAYER_ID) {
	            new
	                sendername[MAX_PLAYER_NAME],
	                string[128],
	                giveplayer[MAX_PLAYER_NAME];

	            GetPlayerName(giveplayerid, giveplayer, sizeof(giveplayer));
	            GetPlayerName(playerid, sendername, sizeof(sendername));

	            format(string, 128, "[Database:]{FFFFFF} [ADMIN] %s has banned %s! Reason: %s", sendername, giveplayer, szReason);
	            SendClientMessageToAll(RED, string);
	            Ban(giveplayerid);

	            new Hour, Minute, Second;
	            gettime(Hour, Minute, Second);
	            format(string,sizeof(string),"[%02d:%02d:%02d]%s has banned %s! Reason:%s",Hour,Minute,Second,sendername,giveplayer, szReason);
	            SaveIn("BanLog.txt",string);
	        }
	    }
	    return 1;
	}
+rep
Reply


Messages In This Thread
[HELP] Unban CMD - by cleanboy - 27.06.2014, 13:01
Re: [HELP] Unban CMD - by cleanboy - 27.06.2014, 13:09
Re: [HELP] Unban CMD - by ScripteRNaBEEL - 27.06.2014, 13:20
Re: [HELP] Unban CMD - by cleanboy - 27.06.2014, 13:44
Re: [HELP] Unban CMD - by ScripteRNaBEEL - 27.06.2014, 13:49
Re: [HELP] Unban CMD - by ScripteRNaBEEL - 27.06.2014, 13:54
Re: [HELP] Unban CMD - by DaniceMcHarley - 27.06.2014, 14:10
Re: [HELP] Unban CMD - by BroZeus - 27.06.2014, 14:47
Respuesta: [HELP] Unban CMD - by Shura - 27.06.2014, 15:22
Re: [HELP] Unban CMD - by miguelangel988 - 27.06.2014, 16:27

Forum Jump:


Users browsing this thread: 1 Guest(s)