SA-MP Forums Archive
[Include] aDialog - Create textdraw dialogs with a few lines of code - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Filterscripts (https://sampforum.blast.hk/forumdisplay.php?fid=17)
+---- Forum: Includes (https://sampforum.blast.hk/forumdisplay.php?fid=83)
+---- Thread: [Include] aDialog - Create textdraw dialogs with a few lines of code (/showthread.php?tid=412741)

Pages: 1 2


aDialog - Create textdraw dialogs with a few lines of code - adri1 - 02.02.2013

Info:
Create Textdraws dialogues, using the function SelectTextDraw

Functions:
pawn Code:
native ShowTextDrawDialog(playerid, dialogid, info[], button1[], button2[], line1[]="", line2[]="", line3[]="", line4[]="", line5[]="", line6[]="", line7[]="", line8[]="", line9[]="", line10[]="", line11[]="")
forward OnTextDrawDialogResponse(playerid, response, dialogid, listitem)
Notes:
* To create dialogue with one button to leave the 'button2' to null, ie ""
EXAMPLE: ShowTextDrawDialog(playerid, dialogid, info[], button1[], ""....

* To create less than 11 lines simply not add line ...
EXAMPLE: ShowTextDrawDialog(playerid, dialogid, info[], button1[], button2[], "A", "B", "C"...
Only three lines show the 11 you can create


Video:
[ame="http://www.youtube.com/watch?v=LfT4EcBwigQ"]http://www.youtube.com/watch?v=LfT4EcBwigQ[/ame]

Downloads:
Include: (Mediafire) (Mega)
Example filterscript: (Pastebin) (Paste2)


Re: aDialog - Create textdraw dialogs with a few lines of code - T0pAz - 02.02.2013

Seems good enough. May come in handy. Good work!


Re: aDialog - Create textdraw dialogs with a few lines of code - MP2 - 02.02.2013

Grey = unselected and Black = selected seems wrong. Should be opposite?


Respuesta: Re: aDialog - Create textdraw dialogs with a few lines of code - adri1 - 02.02.2013

Quote:
Originally Posted by MP2
View Post
Grey = unselected and Black = selected seems wrong. Should be opposite?
Change 'PlayerTextDrawBoxColor(playerid, Lines_Texts[playerid][GetPVarInt(playerid, "menu_active")][i], 0x00000066);'
0x00000066 to your color...


Re: aDialog - Create textdraw dialogs with a few lines of code - Scenario - 02.02.2013

It's actually pretty cool. Nice job!


Re: Respuesta: Re: aDialog - Create textdraw dialogs with a few lines of code - MP2 - 03.02.2013

Quote:
Originally Posted by adri1
View Post
Change 'PlayerTextDrawBoxColor(playerid, Lines_Texts[playerid][GetPVarInt(playerid, "menu_active")][i], 0x00000066);'
0x00000066 to your color...
I'm not asking how to change it; I'm giving you a suggestion.


Re: aDialog - Create textdraw dialogs with a few lines of code - Spookie98 - 17.02.2013

Yeah, it would be nice if you could create more items, I mean, if there are more than 11 items, create a new page. I suppose it can be done ( I`m almost sure ).

- iPoke.


Re: aDialog - Create textdraw dialogs with a few lines of code - Mance - 17.02.2013

Looks nice! You will create more styles of dialog?


Re: aDialog - Create textdraw dialogs with a few lines of code - xqz - 27.06.2013

I'm getting "Unknown command" after use ShowTextDrawDialog if using zcmd. In simple cmdtext it's works perfectly. Why?


Re: aDialog - Create textdraw dialogs with a few lines of code - xqz - 28.07.2013

I found a bug.

-1 is set to array.

Lines_Texts[playerid][GetPVarInt(playerid, "menu_active")..

===


Lines_Texts[playerid][-1][i]


Re: aDialog - Create textdraw dialogs with a few lines of code - SwisherSweet - 22.09.2013

I wanted to ask is there any way to like INPUT_PASSWORD or something?


Re: aDialog - Create textdraw dialogs with a few lines of code - Glad2BeHere - 22.09.2013

This is more a menu than a dialog.....isn't very hard to be done something a little more create this is textdraws.... what about changing menu colors, i mean without editing the include like if i want a green menu or something...... i mean i can be easy " {color code} " to change the colors of the text but and think u can add a little more to it.... Overall its just a menu but ++ for ideas


Re: aDialog - Create textdraw dialogs with a few lines of code - Patryk98 - 08.12.2013

Quote:

[02:31:41] [debug] Run time error 4: "Array index out of bounds"
[02:31:41] [debug] Accessing element at negative index -1
[02:31:41] [debug] AMX backtrace:
[02:31:41] [debug] #0 0000e278 in public OnPlayerClickPlayerTextDraw (0x00000000, 0x00000003) from gm.amx

Through what is this error ??


Re: aDialog - Create textdraw dialogs with a few lines of code - JoaoMonteiro452 - 10.12.2013

God job...


Re: aDialog - Create textdraw dialogs with a few lines of code - DemME - 16.12.2013

Works perfectly, used it for Mobile Data computer ( RP )
Much appriceate.


Re: aDialog - Create textdraw dialogs with a few lines of code - futuredj - 16.12.2013

wrong post wrong post wrong post wrong post


Re: aDialog - Create textdraw dialogs with a few lines of code - theYiin - 17.12.2013

pretty much useless. You can't use custom symbols, only english letters, desigin looks terrible. Why should someone use this, when we already have dialogs?


Re: aDialog - Create textdraw dialogs with a few lines of code - MadLeet - 17.12.2013

Awesome.


Re : aDialog - Create textdraw dialogs with a few lines of code - JacobWilkerson - 26.12.2013

It's not work for me.


Re: aDialog - Create textdraw dialogs with a few lines of code - [XPG]MarlonCS - 13.11.2014

Great Job ...
A suggestion: A double click on the line executes the action of button 1