Dialog Problem!
#1

Hello,

Ok so this is my player enum:
pawn Код:
enum pInfo
{
    pPass,
    pCash,
    pAdminLevel,
    pGender,
    pAge,
    pSkin,
    pNew
}
new PlayerInfo[MAX_PLAYERS][pInfo];
And here is my dialog:
pawn Код:
case DIALOG_REG:
        {
            if(!response) return Kick ( playerid );
            new INI:File = INI_Open(UserPath(playerid));
            switch( listitem )
            {
                case 0:
                {
                    INI_WriteInt(File, "Age", PlayerInfo[playerid][pAge]);
                    SendClientMessage(playerid, COLOR_GREY, "Great, so we have your age!");
                }
                case 1:
                {
                    INI_WriteInt(File, "Age", PlayerInfo[playerid][pAge]);
                    SendClientMessage(playerid, COLOR_GREY, "Great, so we have your age!");
                }
                case 2:
                {
                    INI_WriteInt(File, "Age", PlayerInfo[playerid][pAge]);
                    SendClientMessage(playerid, COLOR_GREY, "Great, so we have your age!");
                }
                case 3:
                {
                    INI_WriteInt(File, "Age", PlayerInfo[playerid][pAge]);
                    SendClientMessage(playerid, COLOR_GREY, "Great, so we have your age!");
                }
                case 4:
                {
                    INI_WriteInt(File, "Age", PlayerInfo[playerid][pAge]);
                    SendClientMessage(playerid, COLOR_GREY, "Great, so we have your age!");
                }
                case 5:
                {
                    INI_WriteInt(File, "Age", PlayerInfo[playerid][pAge]);
                    SendClientMessage(playerid, COLOR_GREY, "Great, so we have your age!");
                }
                case 6:
                {
                    INI_WriteInt(File, "Age", PlayerInfo[playerid][pAge]);
                    SendClientMessage(playerid, COLOR_GREY, "Great, so we have your age!");
                }
                case 7:
                {
                    INI_WriteInt(File, "Age", PlayerInfo[playerid][pAge]);
                    SendClientMessage(playerid, COLOR_GREY, "Great, so we have your age!");
                }
                case 8:
                {
                    INI_WriteInt(File, "Age", PlayerInfo[playerid][pAge]);
                    SendClientMessage(playerid, COLOR_GREY, "Great, so we have your age!");
                }
                case 9:
                {
                    INI_WriteInt(File, "Age", PlayerInfo[playerid][pAge]);
                    SendClientMessage(playerid, COLOR_GREY, "Great, so we have your age!");
                }
                case 10:
                {
                    INI_WriteInt(File, "Age", PlayerInfo[playerid][pAge]);
                    SendClientMessage(playerid, COLOR_GREY, "Great, so we have your age!");
                }
                case 11:
                {
                    INI_WriteInt(File, "Age", PlayerInfo[playerid][pAge]);
                    SendClientMessage(playerid, COLOR_GREY, "Great, so we have your age!");
                }
            }
            INI_Close(File);
        }
    }
    return 1;
}
but this is the outcome and it doesn't save the number they pressed! (say they pressed 1.
pawn Код:
Age = 0
[data]
Password = 256967457
Cash = 0
AdminLevel = 0
Reply
#2

What style of dialog is DIALOG_REG ?
Reply
#3

That's his dialogid..
Reply
#4

Quote:
Originally Posted by MP2
Посмотреть сообщение
That's his dialogid..
I know that )
But thats is for Dialog ID and i wos talking about style..i think he is using MSGBOX.
Show me where you show the dialog.
Reply
#5

Quote:
Originally Posted by ******
Посмотреть сообщение
Nowhere in that code do you set their age or the ini tag.
That`s why i asked about dialog style.
Set the age like this

INI_WriteInt(File, "Age", Number);
Put the number with that case..when selected..this is only way like this.
But better is to make id DIALOG_STYLE_INPUT
Reply


Forum Jump:


Users browsing this thread: 2 Guest(s)