Dialog help [+REP]
#1

Hello im making a Roleplay test so when someone logs must answer the good question or he is kicked, how to do?!?!?

So:

"Answer the following question"

What is the OOC

(BUTTON) OUT OF CHARTER
(BUTTON) 2 Option
(BUTTON) 3 Option

So if someone press the 1 button he spawns if he dont he is kicked,... +REP!
Reply
#2

You can't put multiple buttons on a dialog.

https://sampwiki.blast.hk/wiki/ShowPlayerDialog
Reply
#3

ShowPlayerDialog(playerid,4156,DIALOG_STYLE_LIST," What is OOC,"1. Out of character\r\n2. Derp\r\n3. Herp","Continue", "Cancel");


pawn Код:
public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
{
      if(dialogid == 4156)
      {
            if(!response)
            {
                Kick(playerid); // Send also a message that he failed at clicking something or don't kick and ShowPlayerDialog again
                return 1; // We processed it
            }
            if(listitem==0) SpawnPlayer[playerid];
            if(listitem==1 || listitem == 2) return Kick(playerid);
                 
      }
      return 0; // If you put return 1 here the callback will not continue to be called in other scripts (filterscripts, etc.).
}
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)