Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- /******************************************************************************\
- | |
- | [Include] - Processador de Dialogs |
- | By Jeffrey_Hatrix |
- | Special thanks to: SlashPT & Willian_Luigi |
- | |
- \******************************************************************************/
- // [22/06/2013] - Atualizado por Willian Luigi
- //JD processor, simples, fácil e rápido.
- #define msgbox DIALOG_STYLE_MSGBOX
- #define input DIALOG_STYLE_INPUT
- #define list DIALOG_STYLE_LIST
- #define pass DIALOG_STYLE_PASSWORD
- #if !defined isnull
- #define isnull(%1) \
- ((!(%1[0])) || (((%1[0]) == '\1') && (!(%1[1]))))
- #endif
- #define addDialogHandler(%0) \
- forward callDialog_%0(playerid, response, listitem, inputtext[]); \
- public callDialog_%0(playerid, response, listitem, inputtext[])
- #define Dialog:%0(%1,%2,%3,%4) \
- forward callDialog_%0(%1,%2,%3,%4); \
- public callDialog_%0(%1,%2,%3,%4)
- static CALL_DIALOG [ 24 ] ;
- public OnDialogResponse ( playerid , dialogid , response , listitem , inputtext [] )
- {
- if ( dialogid ) format ( CALL_DIALOG , 24 , "callDialog_%d" , dialogid ) ;
- return ( ( funcidx ( CALL_DIALOG ) != -1 ) ? ( CallLocalFunction ( CALL_DIALOG , "ddds" , playerid , response , listitem , isnull( inputtext ) ? ( "\1" ) : ( inputtext ) ) ) : ( 0 ) ) ;
- }
- // =================================================================================
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement