[Ajuda] Comando
#2

Код HTML:
     if(strcmp(cmd, "/Duelo", true) == 0) 
    { 
        tmp = strtok(cmdtext, idx); 
        new iNomeid = strval(tmp); 
        if(!strlen(tmp)) 
        { 
            SendClientMessage(playerid, ERRO, "| ERRO | Uso: /Duelo [id]"); 
            return 1; 
        } 
        if(!IsPlayerConnected(iNomeid)) 
        { 
            SendClientMessage(playerid, ERRO, "| ERRO | Jogador nгo conectado!"); 
            return 1; 
        } 
        if(DueloMais == 2) 
        { 
        SendClientMessage(playerid, ERRO, "| DUELO | Aguarde um pouco jб а um duelo em andamento."); 
        return 1; 
        } 
        if(playerid == iNomeid) 
        { 
            SendClientMessage(playerid, ERRO, "| ERRO | Vocк nгo pode duelar com vocк mesmo!"); 
            return 1; 
        } 
        if(PlayerToPoint(3.0, playerid, 2153.9209,-1013.4620,62.9507)){ 
        if(GetDistanceBetweenPlayers(iNomeid,playerid) < 3){ 
        //new strino[128]; 
        new pNome[MAX_PLAYER_NAME]; 
        new iNome[MAX_PLAYER_NAME]; 
        GetPlayerName(playerid, pNome, sizeof(pNome)); 
        GetPlayerName(iNomeid, iNome, sizeof(iNome)); 
        Enviouoc[playerid] = iNomeid; 
        Recebeuc[iNomeid] = playerid; 
        format(file2, sizeof(file2), "* '%s' vocк estб convidando %s para um duelo.", pNome, iNome); 
        SendClientMessage(playerid, 0x91C8FFAA, file2); 
        new StringFF[1000]; 
        format(StringFF, sizeof(StringFF), "%s, o jogador '%s' estб lhe convidando para um duelo"); 
        ShowPlayerDialog(iNomeid, Convidoux1, DIALOG_STYLE_MSGBOX, "Vocк deseja aceitar?", StringFF, "Aceitar", "Recusar"); 

/*        format(strino, sizeof(strino), "* %s o player %s estб lhe convidando para um duelo. ( /AceitarDuelo ou /RecusarDuelo )", iNome, pNome); 
       SendClientMessage(iNomeid, 0x55AAFFAA, strino); 
       format(strino, sizeof(strino), "* %s o player %s estб lhe convidando para um duelo. ( /AceitarDuelo ou /RecusarDuelo )", iNome, pNome); 
       SendClientMessage(iNomeid, 0x55AAFFAA, strino); 
       format(strino, sizeof(strino), "* %s o player %s estб lhe convidando para um duelo. ( /AceitarDuelo ou /RecusarDuelo )", iNome, pNome); 
       SendClientMessage(iNomeid, 0x55AAFFAA, strino);*/ 
        DueloTimer[iNomeid] = SetTimerEx("OnPlayerMesagemDuelo", 4000, true, "i", iNomeid); 
        }else{ 
        SendClientMessage( playerid, Vermelho, "[ x ] Voce e o outro player terao que ficar encima do icone !" ); 
        return 1; 
        } 
        }else{ 
        SendClientMessage( playerid, Vermelho, "[ x ] Vocк nao esta em cima do icone de duelo !" ); 
        return 1; 
        } 
        return 1; 
    }
Reply


Messages In This Thread
Comando - by GabrielMT - 17.06.2017, 19:13
Re: Comando - by DelK - 17.06.2017, 19:20
Re: Comando - by GabrielMT - 17.06.2017, 20:28
Re: Comando - by DelK - 17.06.2017, 21:08
Re: Comando - by MrEdu - 17.06.2017, 22:01

Forum Jump:


Users browsing this thread: 1 Guest(s)