[Ajuda] Dъvidas com "||" "&&"
#1

Boa noite pessoal, estou com dъvidas em relaзгo a restriзгo de comandos. veja:

Код:
CMD:setbope(playerid, params[])
{
    if(Logado[playerid] == false) return
		SendClientMessage(playerid,-1,"{008B00}[ ATENЗГO ] {FFFFFF}Й preciso logar para executar este comando");
    if(!IsPlayerAdmin(playerid) && PlayerInfo[playerid][pAdmin] <= 5 && PlayerInfo[playerid][pOrg] != 5 && PlayerInfo[playerid][pLevel] != 5) return
		SendClientMessage(playerid, -1, "{008B00}[ ATENЗГO ] {FFFFFF}Comando Restrito, apуs 3 tentativas tomarб BAN");
    new id; new Jogador [MAX_PLAYER_NAME]; new Outro [MAX_PLAYER_NAME]; new string[128];
    if(sscanf(params, "ud", id, Nivel)) return
		SendClientMessage(playerid, -1, "{FFA500}[ USE ] /setbope [ID] [Nнvel de Bope]");
    if(!IsPlayerConnected(id)) return
		SendClientMessage(playerid, -1, "{FF0000}[ERRO] {FFFFFF}Jogador nгo conectado");
    if(Nivel > 5) return
		SendClientMessage(playerid, -1, "{008B00}[ ATENЗГO ] {FFFFFF}O Mбximo De Level a se dar й 5");
    GetPlayerName(playerid, Jogador, MAX_PLAYER_NAME);
    GetPlayerName(id, Outro, MAX_PLAYER_NAME);
    format(string, 100, "{FFFFFF}Vocк convidou {4F4F4F}%s {FFFFFF}para ser do BOPE", Outro);
    SendClientMessage(playerid, -1, string);
    GetPlayerName(playerid, Jogador, sizeof(Jogador));
    format(string, 128, "{4F4F4F}%s {FFFFFF}estб lhe convidando para ser BOPE level: {4F4F4F}%d \n{FFFFFF}Deseja aceitar?", Jogador, Nivel);
    ShowPlayerDialog(id, DIALOG_BOPE, DIALOG_STYLE_MSGBOX, "{FFFFFF}Convite para BOPE", string, "Sim", "Nгo");
    return 1;
}
Veja se estб correto, vou explicar oque desejo..
Quero que sу possa usar este comando, se o player estiver logado na rcon ou se for admin level 6, e quero que se nгo for nenhum dos dois anteriores й obrigatуrio que seja da org 5 e que tenha level 5.
Reply


Messages In This Thread
Dъvidas com "||" "&&" - by .ThePro - 13.01.2013, 23:39
Re: Dъvidas com "||" "&&" - by paulor - 13.01.2013, 23:55
Re: Dъvidas com "||" "&&" - by .ThePro - 14.01.2013, 00:06
Re: Dъvidas com "||" "&&" - by joeyleone - 14.01.2013, 00:11
Re: Dъvidas com "||" "&&" - by paulor - 14.01.2013, 00:12
Re: Dъvidas com "||" "&&" - by .ThePro - 14.01.2013, 00:22
Re: Dъvidas com "||" "&&" - by .ThePro - 14.01.2013, 00:24
Re: Dъvidas com "||" "&&" - by Maklister - 14.01.2013, 00:32
Re: Dъvidas com "||" "&&" - by .ThePro - 14.01.2013, 00:36
Re: Dъvidas com "||" "&&" - by paulor - 14.01.2013, 00:37

Forum Jump:


Users browsing this thread: 1 Guest(s)