Dialog help
#1

I have a problem:

if(dialogid == 3)
{
if(response)
{
SendClientMessage(playerid,FARBE_GELB2, "you are male!");
dini_IntSet(accFormat,"sex",Player[playerid][sex]=0);
SpawnPlayer(playerid);
}
else
{
SendClientMessage(playerid,FARBE_GELB2, "you are female!");
dini_IntSet(accFormat,"Sex",Player[playerid][Sex]=1);
SpawnPlayer(playerid);
}
}

here the problem:
if i click male comes the text:you are male
but if i click female nothing happens

thanks for help
Reply
#2

Try this:

pawn Код:
ShowPlayerDialog(playerid,3,DIALOG_STYLE_MSGBOX,"Gender","You're Male or Female?","Male","Female");

//OnDialogResponse
if (dialogid == 3)
    {
        if(response == 0)
        {
        SendClientMessage(playerid,FARBE_GELB2, "you are male!");
        dini_IntSet(accFormat,"sex",Player[playerid][sex]=0);
        SpawnPlayer(playerid);
        }
        if(response)
        {
        SendClientMessage(playerid,FARBE_GELB2, "you are female!");
        dini_IntSet(accFormat,"Sex",Player[playerid][Sex]=1);
        SpawnPlayer(playerid);
        }
        return 1;
    }
Reply
#3

thank you
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)