17.12.2014, 17:25
Hi All
i need a Cmd That it gives me to kick all the players
Plz Give it Plz
it is my /kick code that kick just 1 player how can i make it for all the players?
i need a Cmd That it gives me to kick all the players
Plz Give it Plz
it is my /kick code that kick just 1 player how can i make it for all the players?
Код:
CMD:kick(playerid, params[]) { new playerb, string[128]; if(!IsPlayerLoggedIn(playerid)) return SendClientMessage(playerid, COLOR_GREY, "Aval Bayad login Koni Ghabl Az inke Az CMD Ha Estefade Koni."); if(PlayerInfo[playerid][pAdmin] < 1 && PlayerInfo[playerid][pHelper] < 1) return SendClientMessage(playerid, COLOR_GREY, "Shoma Sath Dast Resi Be In CMD Ra Nadarid."); // if(!aDuty[playerid]) return SendClientMessage(playerid, COLOR_GREY, "You are not on admin duty."); if(sscanf(params, "us[128]", playerb, params)) return SendClientMessage(playerid, COLOR_WHITE, "USAGE: /kick [playerid] [reason]"); if(!IsPlayerConnected(playerb)) return SendClientMessage(playerid, COLOR_GREY, "ID Bazikon Vared Shode Eshtebah Ast."); if(IsPlayerNPC(playerb)) return SendClientMessage(playerid, COLOR_GREY, "You can't kick NPCs out of the server."); if(PlayerInfo[playerid][pAdmin] < PlayerInfo[playerb][pAdmin]) return SendClientMessage(playerid, COLOR_GREY, "Player has a higher admin level than you."); format(string, sizeof(string), "{FF0000}[Admin]{FF6347} %s has been kicked by %s, reason: %s", NORPN(playerb), NORPN(playerid), params); SendClientMessageToAll(COLOR_LIGHTRED, string); format(string, sizeof(string), "{FF0000}[Admin]{FF6347} %s has been kicked by %s (%s), reason: %s", NORPN(playerb), NORPN(playerid), RPIP(playerid), params); Log("logs/kick.log", string); // Textdraw TextDrawShowForPlayer(playerb, KickedNotice); // Kick Action FixedKick(playerb); return 1; }