SA-MP Forums Archive
players that gets banned - 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)
+---- Forum: Help Archive (https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: players that gets banned (/showthread.php?tid=120005)



players that gets banned - `FuTuRe- - 10.01.2010

Hello, How do i make that the player that got banned gets this message:


You have been banned!
Admin that banned you:
Apply at *website*
Date:

This is my code:
pawn Код:
dcmd_ban(playerid, params[])
{
    new banid;
    new reason[128];
    new string[128];

    if(pInfo[playerid][level] < 2) return SendMsg(playerid,5000,"~r~Error: ~w~You aren't level 2 admin or higher! ");
    if(sscanf(params, "uz", banid, reason)) return SendMsg(playerid, 5000, "~b~USAGE: ~w~/ban <playerid/name> <reason>");

    format(string,sizeof(string),"[ADMIN] %s has banned %s [ID: %d] Reason: %s",pInfo[playerid][name],pInfo[banid][name],banid,reason);
    SendClientMessageToAll(GAME_ENGINE,string);

    BanEx(banid,reason);
    return 1;
}



Re: players that gets banned - Deat_Itself - 10.01.2010

Add this before BanEx
Код:
SendClientMessage(banid, COLOR_YOUWANt, "You have been banned!");
format(string,sizeof(string), "Admin that banned you: %s" , pName);
SendClientMessage(banid, COLOR_YOUWANT, string);
SendClientMessage(banid, COLOR_YOUWaNT, "Apply at *website*");
format(string2, sizeof(string2), "Date: %d" ,the text for ur date);
SendClientMessage(banid, COLOR_YOUWANt, string2);



Re: players that gets banned - `FuTuRe- - 10.01.2010

Tyvm!