Dialogs
#2

Well this is an example of a 2 button message box.

To show it:
pawn Код:
ShowPlayerDialog(playerid,1,DIALOG_STYLE_MSGBOX,"Dialog title","This is a new feature!\nCool, isn't it?","Yes","No");
Under the OnDialogResponse callback:
pawn Код:
public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
{
  if(dialogid == 1) // The dialog ID we assigned the message box to
  {
    if(response) SendClientMessage(playerid, 0xFFFFFFFF, "Yes? Me too!"); // If they clicked Yes
    else SendClientMessage(playerid, 0xFFFFFFFF, "No? Well I think it's cool."); // If they cliked no
  }
  return 1;
}
If you need help with lists or input boxes, just ask.
Reply


Messages In This Thread
Dialogs - by Daem - 18.09.2009, 07:44
Re: Dialogs - by Mikep. - 18.09.2009, 09:36
Re: Dialogs - by Daem - 18.09.2009, 09:53
Re: Dialogs - by Mikep. - 18.09.2009, 10:00
Re: Dialogs - by Daem. - 19.09.2009, 17:29
Re: Dialogs - by Mikep. - 19.09.2009, 17:30

Forum Jump:


Users browsing this thread: 2 Guest(s)