pawn Код:
CMD:kick(playerid,params[])
{
new id,reason;
Line 323 if(PlayerInfo[playerid][AdminLevel] < 1) return SendClientMessage(playerid,COLOR_RED,"[ERROR] You've to be an level 1 admin to use this command.");
else if(sscanf(params,"us",id,reason)) return SendClientMessage(playerid,COLOR_WHITE,"[SYNTAX] Usage: /kick [playerid] [Reason]");
else if(id == playerid)SendClientMessage(playerid,COLOR_WHITE,"[ERROR] You cannot kick yourself!");
else if(id == INVALID_PLAYER_ID) return SendClientMessage(playerid,COLOR_RED,"[ERROR] That player isn't connected.");
else
{
new string[124];
new name[MAX_PLAYER_NAME];
new nname[MAX_PLAYER_NAME];
GetPlayerName(id,name,MAX_PLAYER_NAME);
GetPlayerName(playerid,nname,MAX_PLAYER_NAME);
format(string,sizeof(string),"[KICK] %s has been kicked by %s [Reason: %s]",name,nname,string);
SendClientMessageToAll(COLOR_RED,string);
Kick(id);
}
return 1;
}
Also can you check if this kick command will work.