28.11.2016, 19:33
Description:
Example:
Download:
The library add a new syntax that is not similar to other dialog processors. Also it add new functions.Functions:
pawn Код:
Dialog_Open(playerid, const dialog_response[], style, caption[], info[], button[], button1[] = !"\0");
Dialog_Close(playerid);
Dialog_Show(playerid, const template_name[]);
IsPlayerInDialog(playerid);
GetPlayerUsingDialog(const dialog_name[], player_list[], size = sizeof player_list);
pawn Код:
// To open the dialog box, you must call Dialog_Open
// You can specify not all arguments, but only those that you need.
dialog SomeDialog(playerid, response, inputtext[])
{
/* ... */
}
// This dialog will be called only when response is set to true.
dialog SomeDialogWithResponse<true>(playerid, inputtext[])
{
/* ... */
}
// You can create templates of dialogs.
dtempl TemplateOfSomeDialog(playerid)
{
// You may omit the last argument of this function.
Dialog_Open(playerid, dfunc:SomeDialog, DIALOG_STYLE_MSGBOX, !"Caption", !"Info", !"Button");
}
Download:
githubInstallation:
- Download it!
- Copy all files to the folder '/pawno/include' which is located in the folder with the server.
- The library need to include after the SAMP libraries.
Example:
pawn Код:#include <a_samp>
#include <tdw_dialog> - Compile the modified scripts!