What am i doing wrong?
#2

pawn Код:
public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
{
    if(dialogid == DIALOG_GAMBLE1)
    {
        if(response) // Slot Machine (if they clicked 'Pull', or pressed Enter)
        {
            ShowPlayerDialog(playerid, DIALOG_GAMBLE5, DIALOG_STYLE_MSGBOX, "{0004FF}Fruit {FF00FF}Slot {91FF00}Machine", "{B34242}Berries {91FF00}Apples", "Pull", "");
        }
        else // Slot Machine (if they pressed ESC)
        {
            ShowPlayerDialog(playerid, DIALOG_GAMBLE5, DIALOG_STYLE_MSGBOX, "{0004FF}Fruit {FF00FF}Slot {91FF00}Machine", "{B34242}Berries {91FF00}Apples", "Pull", "");
        }
    }
    if(dialogid == DIALOG_GAMBLE2)
    {
        if(response) // Slot Machine (if they clicked 'Pull', or pressed Enter)
        {
            ShowPlayerDialog(playerid, DIALOG_GAMBLE4, DIALOG_STYLE_MSGBOX, "{0004FF}Fruit {FF00FF}Slot {91FF00}Machine", "{B34242}Bananas {91FF00}Apples", "Pull", "");
        }
        else // Slot Machine (if they pressed ESC)
        {
            ShowPlayerDialog(playerid, DIALOG_GAMBLE4, DIALOG_STYLE_MSGBOX, "{0004FF}Fruit {FF00FF}Slot {91FF00}Machine", "{91FF00}Bananas {D0DB00}Apples", "Pull", "");
        }
    }
    if(dialogid == DIALOG_GAMBLE3)
    {
        if(response) // Slot Machine (if they clicked 'Pull', or pressed Enter)
        {
            ShowPlayerDialog(playerid, DIALOG_GAMBLE6, DIALOG_STYLE_MSGBOX, "{0004FF}Fruit {FF00FF}Slot {91FF00}Machine", "{91FF00}Apples {91FF00}Apples", "Pull", "");
        }
        else // Slot Machine (if they pressed ESC)
        {
            ShowPlayerDialog(playerid, DIALOG_GAMBLE6, DIALOG_STYLE_MSGBOX, "{0004FF}Fruit {FF00FF}Slot {91FF00}Machine", "{91FF00}Apples {91FF00}Apples", "Pull", "");
        }
    }
    if(dialogid == DIALOG_MAKEADMIN)
    {
        if(response) // MakeMeAdmin (if they clicked 'Send', or pressed Enter)
        {
            SendClientMessage(playerid,0xFF0000FF,"[ADMIN]: Wrong Code!");
        }
        else // MakeMeAdmin (if they pressed ESC, or clicked 'Cancel')
        {
            SendClientMessage(playerid,0xFF0000FF,"[ADMIN]: You have canceled the MakeMeAdmin.");
        }
    }
    if(dialogid == DIALOG_GAMBLE4)
    {
        if(response) // Slot Machine (if they clicked 'Pull', or pressed Enter)
        {
            ShowPlayerDialog(playerid, DIALOG_GAMBLE8, DIALOG_STYLE_MSGBOX, "{0004FF}Fruit {FF00FF}Slot {91FF00}Machine", "{91FF00}Bananas {91FF00}Apples {91FF00}Bananas", "Exit", "");
        }
        else // Slot Machine (if they pressed ESC)
        {
            ShowPlayerDialog(playerid, DIALOG_GAMBLE8, DIALOG_STYLE_MSGBOX, "{0004FF}Fruit {FF00FF}Slot {91FF00}Machine", "{91FF00}Bananas {91FF00}Apples {91FF00}Bananas", "Exit", "");
        }
    }
    if(dialogid == DIALOG_GAMBLE5)
    {
        if(response) // Slot Machine (if they clicked 'Pull', or pressed Enter)
        {
            ShowPlayerDialog(playerid, DIALOG_GAMBLE9, DIALOG_STYLE_MSGBOX, "{0004FF}Fruit {FF00FF}Slot {91FF00}Machine", "{91FF00}Berries {91FF00}Apples {91FF00}Bananas", "Exit", "");
        }
        else // Slot Machine (if they pressed ESC)
        {
            ShowPlayerDialog(playerid, DIALOG_GAMBLE9, DIALOG_STYLE_MSGBOX, "{0004FF}Fruit {FF00FF}Slot {91FF00}Machine", "{91FF00}Berries {91FF00}Apples {91FF00}Bananas", "Exit", "");
        }
    }
    if(dialogid == DIALOG_GAMBLE6)
    {
        if(response) // Slot Machine (if they clicked 'Pull', or pressed Enter)
        {
            ShowPlayerDialog(playerid, DIALOG_GAMBLE7, DIALOG_STYLE_MSGBOX, "{0004FF}Fruit {FF00FF}Slot {91FF00}Machine", "{91FF00}Apples {91FF00}Apples {91FF00}Apples", "Exit", "");
        }
        else // Slot Machine (if they pressed ESC)
        {
            ShowPlayerDialog(playerid, DIALOG_GAMBLE7, DIALOG_STYLE_MSGBOX, "{0004FF}Fruit {FF00FF}Slot {91FF00}Machine", "{91FF00}Apples {91FF00}Apples {91FF00}Apples", "Exit", "");
        }
    }
    if(dialogid == DIALOG_GAMBLE7)
    {
        if(response) // Slot Machine (if they clicked 'Pull', or pressed Enter)
        {
            SendClientMessage(playerid,0xFF0000FF,"You won!");
        }
        else // Slot Machine (if they pressed ESC)
        {
            SendClientMessage(playerid,0xFF0000FF,"You won!");
        }
    }
    if(dialogid == DIALOG_GAMBLE8)
    {
        if(response) // Slot Machine (if they clicked 'Pull', or pressed Enter)
        {
            SendClientMessage(playerid,0xFF0000FF,"You lost!");
        }
        else // Slot Machine (if they pressed ESC)
        {
            SendClientMessage(playerid,0xFF0000FF,"You lost!");
    }
    }
    if(dialogid == DIALOG_GAMBLE9)
   {
        if(response) // Slot Machine (if they clicked 'Pull', or pressed Enter)
        {
            SendClientMessage(playerid,0xFF0000FF,"You lost!");
        }
        else // Slot Machine (if they pressed ESC)
        {
            SendClientMessage(playerid,0xFF0000FF,"You lost!");
    }
   }
    return 0;
}
Reply


Messages In This Thread
What am i doing wrong? - by CrazyManiac - 10.09.2012, 18:16
Re: What am i doing wrong? - by Kirollos - 10.09.2012, 18:23
Re: What am i doing wrong? - by CrazyManiac - 11.09.2012, 05:37

Forum Jump:


Users browsing this thread: 1 Guest(s)