SA-MP Forums Archive
[AJUDA]Dialog - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: Non-English (https://sampforum.blast.hk/forumdisplay.php?fid=9)
+--- Forum: Languages (https://sampforum.blast.hk/forumdisplay.php?fid=33)
+---- Forum: Português/Portuguese (https://sampforum.blast.hk/forumdisplay.php?fid=34)
+---- Thread: [AJUDA]Dialog (/showthread.php?tid=287955)



Resolvido [ Closed] - leandroak - 05.10.2011

RESOLVIDO CLOSED


Re: [AJUDA]Dialog - ViniBorn - 05.10.2011

pawn Код:
if(dialogid == 914)
{
    if(response)
    {
        if(listitem == 0)
        {
            GivePlayerWeapon(playerid, 24,999); //> da arma ao player deagle q no caso o 1 botao
            SendClientMessage(playerid, COLOR_GREEN, "Voce ganhou uma eagle!");
        }
        if(listitem == 1)
        {
            GivePlayerWeapon(playerid, 25, 999); //~~> da arma shotgun ao player na 2 botao
            SendClientMessage(playerid, COLOR_DBLUE, "voce pegou shotgun");
        }
        if(listitem == 2)
        {
            SetPlayerArmour(playerid, 100); // Da colete ao player no caso 3 botгo!
            SendClientMessage(playerid, COLOR_GREEN, "Voce pego colete!");
        }
    }
    return 1;//fim do dialog
}



Re: [AJUDA]Dialog - WLSF - 05.10.2011

tenta retornar os listitem nesse que o viniborn fez. Pra evitar isso...


Re: [AJUDA]Dialog - leandroak - 05.10.2011

OBRIGADO + RESP


Re: [AJUDA]Dialog - ViniBorn - 05.10.2011

Sу pra explicar.

response й o parвmetro que й usado para saber se o jogador clicou no botгo da esquerda(ou apertou ESC) ou no botгo da direita (ou apertou Enter).

Vocк estava usando para detectar qual opзгo da lista foi escolhido, o que nгo dб certo. Pra isso usa-se o outro parвmetro, listitem