Whats wrong with this code?
#1

Why are these dialog not working,can you guys please help or show me how to fix it? sorry for loose indentions.

pawn Код:
if(dialogid == REG4)

{
    switch( listitem ) {

        case 0:

            {
                ClearChatbox(playerid, 10);
                SendClientMessage(playerid, COLOR_GREY, "Wrong answer!");
                Kick(playerid);

            }
        case 1:

            {
                ClearChatbox(playerid, 10);
                SendClientMessage(playerid, COLOR_GREY, "Wrong answer!");
                Kick(playerid);

            }
        case 2:

            {
                ClearChatbox(playerid, 10);
                SendClientMessage(playerid, COLOR_GREY, "Wrong answer!");
                Kick(playerid);

            }
        case 3:

            {
// RegistrationStep[playerid] = 5;
                ShowPlayerDialog(playerid,REG5,DIALOG_STYLE_LIST,"What is the meaning of Metagame","To Not roleplay eat a hotdog \nTo scam money off of noobs\nTo kill someone for no reason\nTo use OOC knowledge IC","Exit","Next");

            }
        case 4:

            {
                ClearChatbox(playerid, 10);
                SendClientMessage(playerid, COLOR_GREY, "Wrong answer!");
                Kick(playerid);

            }

    }
    if(dialogid == REG5) {

        switch( listitem ) {

            case 0:

                {
                    ClearChatbox(playerid, 10);
                    SendClientMessage(playerid, COLOR_GREY, "Wrong answer!");
                    Kick(playerid);

                }
            case 1:

                {
                    Kick(playerid);

                }
            case 2:

                {
                    Kick(playerid);

                }
            case 3:
            {
                Kick(playerid);

            }
            case 4:
            {
                Kick(playerid);

            }
            case 5:
            {

                ShowPlayerDialog(playerid,REG6,DIALOG_STYLE_LIST,"What is a proper way to use /me 2 out of 4 are right","/me pulls out his wallet and examines it\n* Lilcuete has a big screen T.V. in his room\n* Lilcuete car\n* Lilcuete attempts to push someone","Exit","Next");

            }

        }

        if(dialogid == REG6) {

            if(response) {

                if (listitem == 0) {

                    Kick(playerid);

                }
                else if (listitem == 1) {

                    Kick(playerid);

                }

            }
            else if (listitem == 2) {

                Kick(playerid);

            }

        }
        else if (listitem == 3) {

            RegistrationStep[playerid] = 7;
            ShowPlayerDialog(playerid,REG7,DIALOG_STYLE_LIST,"What is a example of Powergaming","/me pushes carlos to the car and hits him in the head\n* Lilcuete grabs juan's bat and hits juan's head\n* Lilcuete attempts to push carlos to the car.\n* Lilcuete hits the clerk in the face","Exit","Next");

        }
        else if (listitem == 4) {

            Kick(playerid);

        }
    }
}


if(dialogid == REG7)

{
    if(response) {

        if (listitem == 0) {

            Kick(playerid);

        }
        else if (listitem == 1) {

            Kick(playerid);

        }

    }
    else if (listitem == 2) {

        Kick(playerid);

    }

}


else if (listitem == 3)

{

    RegistrationStep[playerid] = 8;
    ShowPlayerDialog(playerid,REG8,DIALOG_STYLE_LIST,"What is a example of Revenge Kill","Carlos got shot in the head,and then comes out of the hospital and shoots the same person who shot him\nCarlos DM's everyone\nCarlos RK's\nCarlos get's shot in the head and is in the hospital but doesn't remember anything","Exit","Next");

}


else if (listitem == 4)

{

    Kick(playerid);

}


if(dialogid == REG8)

{
    if(response) {

        if (listitem == 0) {

            RegistrationStep[playerid] = 9;
            ShowPlayerDialog(playerid,REG9,DIALOG_STYLE_LIST,"Are drivers allowed to drive-by?","Yes if they want to\nNo only passangers\nYes,but only cops\nYes but if there admins","Exit","Next");

        }
        else if (listitem == 1) {

            Kick(playerid);

        }

    }
    else if (listitem == 2) {

        Kick(playerid);

    }

}


else if (listitem == 3)

{

    Kick(playerid);

}


else if (listitem == 4)

{

    Kick(playerid);

}


if(dialogid == REG9)

{
    if(response) {

        if (listitem == 0) {

            Kick(playerid);

        }
        else if (listitem == 1) {

            RegistrationStep[playerid] = 10;
            ShowPlayerDialog(playerid,REG10,DIALOG_STYLE_LIST,"What happens if you disobey the rules?","You will get 100,000$\nYou will get punished\nYou will get to become a admin\nYou will get to be in a faction","Exit","Next");

        }

    }
    else if (listitem == 2) {

        Kick(playerid);

    }

}


else if (listitem == 3)

{

    Kick(playerid);

}


else if (listitem == 4)

{

    Kick(playerid);

}


if(dialogid == REG10)

{
    if(response) {

        if (listitem == 0) {

            Kick(playerid);

        }
        else if (listitem == 1) {

            RegistrationStep[playerid] = 11;
            ShowPlayerDialog(playerid,REG11,DIALOG_STYLE_LIST,"What level can you rob and scamm and what's the limit?","You can scamm and rob at level 3 or above,limit is 50,000$ for scamm,robbing is 5,000$\nYou can rob and scamm at any level,and as much as you want\nYou can rob,and scamm at level 15,and max is 50,0000$\nWho cares?","Exit","Next");

        }

    }
    else if (listitem == 2) {

        Kick(playerid);

    }

}


else if (listitem == 3)

{

    Kick(playerid);

}


else if (listitem == 4)

{

    Kick(playerid);

}


if(dialogid == REG11)

{
    if(response) {

        if (listitem == 0) {

            RegistrationStep[playerid] = 12;
            ShowPlayerDialog(playerid,REG12,DIALOG_STYLE_LIST,"Do you accept to roleplay at all times in this server,and don't disobey the rules?","Yes at all times\nNo i don't even like roleplay\nYes,but i might hack\nI'm going to hack this server","Exit","Next");

        }
        else if (listitem == 1) {

            Kick(playerid);

        }

    }
    else if (listitem == 2) {

        Kick(playerid);

    }

}


else if (listitem == 3)

{

    Kick(playerid);

}


else if (listitem == 4)

{

    Kick(playerid);

}


if(dialogid == REG13)

{
    if(response) {

        RegistrationStep[playerid] = 0;
        PlayerInfo[playerid][pTut] = 1;
        TutTime[playerid] = 1;
        gPlayerAccount[playerid]=1;
        strmid(PlayerInfo[playerid][pAccent], "Says", 0, strlen("Says"), 255);
        strmid(PlayerInfo[playerid][pTaunt], "None", 0, strlen("None"), 128);

    }

}


if(dialogid == REG12)

{
    if(response) {

        if (listitem == 0) {

            new string[256];

            format(string, sizeof(string), "Congratulations %s you have just passed the exam,please click,Ok to go to tutorials");
            ShowPlayerDialog(playerid,REG13,DIALOG_STYLE_MSGBOX,"Click O or K to go on to tutorials",string,"O","K");

        }
        else if (listitem == 1) {

            Kick(playerid);

        }

    }
    else if (listitem == 2) {

        Kick(playerid);

    }

}


else if (listitem == 3)

{

    Kick(playerid);

}


else if (listitem == 4)

{

    Kick(playerid);

}
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)