SA-MP Forums Archive
[Include] pEscapemenu (New 'Dialog' Style) *19/Oct/2011* - 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] pEscapemenu (New 'Dialog' Style) *19/Oct/2011* (/showthread.php?tid=291242)

Pages: 1 2


pEscapemenu (New 'Dialog' Style) *19/Oct/2011* - Pablo Borsellino - 18.10.2011

Peace,

today I've decided, to publish a new Open Source Project. I sincerely apologize for my imperfect English. This Include allows you some functions for an new Dialog Style (Escape Menu). Its not perfect the same like the Escape Menu - cause of: I cant have the Chance to query the Escape Key for false response like KEY_ESCAPE - I don't can use the texture fronten2:back8 as sprite - I don't have enough mood, to calculate the hud:arrow Texture position, for every single letter because every Letter have an else X-Size, so comes this feature next time. Watch the Video, if you don't understand me.

Needed Function's:
pawn Код:
Needed Function's:
OnEscapeMenuInit(); //Use this in OnGameModeInit or OnFilterScriptInit
OnEscapeMenuExit(); //Use this in OnGameModeExit or OnFilterScriptExit
OnEscapeMenuKeyStateChange(playerid,newkeys); //Use this in OnPlayerKeyStateChange
OnEscapeMenuUpdate(playerid); //Use this in OnPlayerUpdate
OnEscapeMenuConnect(playerid); //Use this in OnPlayerDisconnect
OnEscapeMenuDisonnect(playerid); //Use this in OnPlayerDisconnect
Function's:
pawn Код:
ShowPlayerEscapeMenu(playerid,Title[],Option1[],Option2[],Option3[],Option4[],Option5[],Option6[],Option7[]);//If you want only use 6 or less Options use as empty Option "" - nothing else! The script convert the empty field to "_" & set variables.
HidePlayerEscapeMenu(playerid);
SetPlayerEscapeMenuOptionText(playerid,OptionID,NewText[]);//Is something same like "AddPlayerEscapeMenuOption" if this Option is Invalid.
RemovePlayerEscapeMenuOption(playerid,OptionID)
If-Queries:
pawn Код:
EscapeMenuOpen(playerid)//If the player see the Menu, it returns true - else it returns false
IsValidEscapeMenuOption(playerid,OptionID)//If the option exist, it returns true - else it returns false
Public's:
pawn Код:
OnPlayerEscapeMenuRowChange(playerid,NewRowID)
OnPlayerEscapeMenuResponse(playerid,SelectedRow)//The Menu dont hide by himself, so you have to use "HidePlayerEscapeMenu(playerid);" in this public - if you want to hide the Escapemenu after pressing the ENTER Key.
Video:
[ame]http://www.youtube.com/watch?v=-hBqThYYiTY[/ame]
pawn Код:
http://www.youtube.com/watch?v=-hBqThYYiTY
Downloads:
http://solidfiles.com/d/43278/ (Includes Include, Example Filterscript, Picture & Readme - Recommended)
http://pastebin.com/tA1dzk3P

Changelog:
pawn Код:
• v1.0 (19.10.2011)
-» Initial release
Rules:
Nother Mirrors: allowed (Desired)
Editing Script: allowed
Removing Credits: allowed
Publish it: forbidden (Only on request)
Sell it: forbidden

Greetz!



AW: pEscapemenu (New 'Dialog' Style) *19/Oct/2011* - xX60CentXx - 18.10.2011

O.O Nice


AW: pEscapemenu (New 'Dialog' Style) *19/Oct/2011* - Pablo Borsellino - 18.10.2011

@xX60CentXx: Thanks.


Re: pEscapemenu (New 'Dialog' Style) *19/Oct/2011* - Kingunit - 18.10.2011

Looks great. Unique idea, I like it.


AW: pEscapemenu (New 'Dialog' Style) *19/Oct/2011* - Pablo Borsellino - 18.10.2011

@Kingunit: Thanks.


Re: pEscapemenu (New 'Dialog' Style) *19/Oct/2011* - Shelby - 19.10.2011

Your ideas are awesome.
Idea: You can use the ******'s method to hook callbacks without asking to put in the script.


AW: pEscapemenu (New 'Dialog' Style) *19/Oct/2011* - Pablo Borsellino - 19.10.2011

@Shelby: Thanks. I had been thinking about it - eventually I add this in the next update.


Respuesta: pEscapemenu (New 'Dialog' Style) *19/Oct/2011* - usrb1n - 19.10.2011

Very nice ! I like all your scripts.
+1 Reputation.


Re: pEscapemenu (New 'Dialog' Style) *19/Oct/2011* - System64 - 19.10.2011

you always have unique and good ideas

Keep up man

Also can you sand me this mod for ped?


Re: pEscapemenu (New 'Dialog' Style) *19/Oct/2011* - Drakon - 19.10.2011

Amazing.


AW: pEscapemenu (New 'Dialog' Style) *19/Oct/2011* - Pablo Borsellino - 19.10.2011

@usrb1n & Drakon: Thanks.

@System64: Thanks & you get it via PM.



Re : pEscapemenu (New 'Dialog' Style) *19/Oct/2011* - Naruto_Emilio - 19.10.2011

GOOD ***** JOB, you are epic.


Re: pEscapemenu (New 'Dialog' Style) *19/Oct/2011* - Ricop522 - 19.10.2011

You're Insane, thats amazing


Re: pEscapemenu (New 'Dialog' Style) *19/Oct/2011* - TouR - 19.10.2011

Well dude i am speachless when it comes to talk about your releases. You are GODLIKE. Thank you very much


Re: pEscapemenu (New 'Dialog' Style) *19/Oct/2011* - justsomeguy - 19.10.2011

Oeh sexy! Great job, sow this is just like normal dialogs but in a menu?


AW: pEscapemenu (New 'Dialog' Style) *19/Oct/2011* - Pablo Borsellino - 19.10.2011

@Naruto_Emilio: No, I'am Pablo[/Irony]. Thanks!

@Ricop522 & tour15: Thanks.

@justsomeguy: Watch the Video, it explain everything.



Re: pEscapemenu (New 'Dialog' Style) *19/Oct/2011* - TheArcher - 19.10.2011

Another +rep for you i like your ideas :P Good job


AW: pEscapemenu (New 'Dialog' Style) *19/Oct/2011* - Nanory - 19.10.2011

This Script is good, but have you test that script with other players?
I saw the code and it looks like it will only work for one Person.

Example:
Player#1 and Player#2 see the Menu...
Player#1 change from Row 2 to 3 ... (So the text from Row 3 will change to a brighter blue, like in singleplayer).
But there are only 7 Textdraws for 2 Player. Also Player#2 will see Row 3 marked, althrough he didn't change the row.

There are only 7 Textdraws for 2 Player, but it should be 14 Textdraws for 2 Players and 21 Textdraws for 3 Players... Your amount of Textdraws never change.


Re: pEscapemenu (New 'Dialog' Style) *19/Oct/2011* - TheArcher - 19.10.2011

@Nanory what do you mean show the menu for other players? It seems useless. It's better to use the function when the player calls it.


Re: pEscapemenu (New 'Dialog' Style) *19/Oct/2011* - Zh3r0 - 19.10.2011

Quote:
Originally Posted by Pablo Borsellino
Посмотреть сообщение
pawn Код:
Needed Function's:
OnEscapeMenuInit(); //Use this in OnGameModeInit or OnFilterScriptInit
OnEscapeMenuExit(); //Use this in OnGameModeExit or OnFilterScriptExit
OnEscapeMenuKeyStateChange(playerid,newkeys); //Use this in OnPlayerKeyStateChange
OnEscapeMenuUpdate(playerid); //Use this in OnPlayerUpdate
OnEscapeMenuConnect(playerid); //Use this in OnPlayerDisconnect
OnEscapeMenuDisonnect(playerid); //Use this in OnPlayerDisconnect
Have you not heard about hooking?