Here is your basic dialog setup in the map below I made it for a person who had difficulty creating one and decided to put it here for future reference.
Below is a tutorial to make one with screenshots and how to correct some common problems when making dialogs.
You can also download the completed dialog below.
Quote:
Step 1
Your going to have to create some variables you can get there by pressing F4 to call up the trigger editor then clicking the X button at the top menu. Now click the +X button to add a new variable type the dialogs title in the variable name field call it what you wish we will name ours TestDialog and select Dialog from the drop down box.
Step 2
Now we will create our button variables these should be named the same as the buttons titles are. We will call ours Button1 and Button2 selecting dialog button from the drop down menu this time.
Step 3
Now with the variables all configured you will set up a trigger named Dialog Player 1 you also as shown in the picture will set up a title change so instead of the dialog reading TestDialog you can rename it to Test Dialog set it up as shown in Picture 1.
All the images below of the dialog triggers are from the map file you can download below.
Step 4
The next step after all this is to make something happen when you click the button meaning we need it to run a trigger so you would create a trigger like the one in Picture 4 for both buttons. Now when you click dialog button 1 it will run button 1''s trigger. When you click button 2 it will run button 2's trigger etc.
|
Quote:
Common Problems
A very important thing to remember is that you can only create a dialog for one player at a time. You must create one of these triggers for each player you want it to be visible to. As for the variables you can simply create arrays by clicking the little checkbox and changing the number in the variable menu so you don't need any new variables just new triggers.
One of the most common errors in creating dialogs is putting the show/hide dialog command before setting up the buttons and the dialog title in that case you would just see an empty dialog without buttons. Correct configuration shown circled in Picture 1.
You can also make your dialog run at map initialization only if there is a wait command before dialog initialization as shown in Picture 2.
The next mistake people make most is they have trouble or don't know how to capture the button presses into a dialog button variable as properly shown in Picture 3.
|