03.07.2014, 15:37
pawn Код:
CMD:kick(playerid, params[])
{
if(Login[playerid] == 0)
return SendClientMessage(playerid, COR_AMARELO, "Vocк nгo estб logado.");
if(PlayerInfo[playerid][pAdmin] == 0)
return SendClientMessage(playerid, -1, "Vocк nгo й admin.");
if(adminstatus[playerid] == 1)
return SendClientMessage(playerid, COR_VERMELHO, "Vocк nгo estб em modo admin, use /trabalhar.");
if(sscanf(params, "us[128]", params[0], params[1]))
return SendClientMessage(playerid,-1,"Uso correto: /kick [id] [motivo]");
if(!(params[0] != playerid || params[0] != INVALID_PLAYER_ID || IsPlayerConnected(params[0])))
return SendClientMessage(playerid, -1, "! Vocк nгo pode se kickar / ID Invбlido / Jogador offline");
new szPT[128], nome[MAX_PLAYER_NAME], nome1[MAX_PLAYER_NAME];
GetPlayerName(playerid,nome,sizeof(nome));
GetPlayerName(params[0], nome1, sizeof(nome1));
format(szPT, sizeof(szPT),"[ADMIN] %s kikou o player %s. Motivo: %s", nome, nome1, params[1]);
SendClientMessageToAll(COR_TOMATO, szPT);
format(szPT, sizeof(szPT), "Vocк kikou o player %s.", nome1);
SendClientMessage(playerid, -1, szPT);
Kick(params[0]);
return true;
}