Re: New AMXX Menu System
Quote:
:3 |
Re: New AMXX Menu System
Quote:
|
Re: New AMXX Menu System
Emp, if I may make a suggestion, I think it would be a good idea to explain the true purpose of the 3rd parameter in menu_additem(), and then in turn the purpose of menu_item_getinfo(). There's been many posts recently concerning menus where the user has sent the 3rd parameter with just an integer ( in string format ), and seemingly using it as though it's going to be the option number displayed. They then create some arrays and use menu_item_getinfo() in order to retrieve what they don't realise to be, a useless integer, and then start their button check at 1 when it could be started at 0.
|
Re: New AMXX Menu System
It's just a little problem but yes, should be done.
Problem is that many plugins / menus tuts are based on this tutorial, so even if it is changed there, yo gonna keep seeing that usage during a long time. |
Re: New AMXX Menu System
Old Quote from 05-22-09
Yes I have known about it for a while (see quote from almost 4 years ago haha). I will change the snippets around a bit when I have some time. I have been meaning to add in some more complex examples that use the data field besides the MultiHandler example. Also, the Player examples need to be changed to use userid's instead of just the client index. Another thing I should note (which I see a lot in the Scripting Help section) is that MEXIT_ALL is the default behavior for MPROP_EXIT and is unneeded most of the time. Lastly, what ConnorMcLeod pointed out, the Callback example should return ITEM_IGNORE because ITEM_ENABLED will override the admin flag in menu_additem. Does anyone else have any other changes or comments they would like to see? |
Re: New AMXX Menu System
About key as string info, it is a good point for menu edition, but i don't think it's a big deal to change cases in switch statement, only problem is when you forgot to change it :P
Have made changes to player menu if it can saves you some time, and also have a little more complete player menu snippet. added flag "a" to get_players and renamed access variable into _access since access in now a amxmisc stock.
Spoiler
Spoiler
|
Re: New AMXX Menu System
Nice work guys, good idea stickying the thread too. However IMO Emp I think the first example ( Basic Menu ) could still do without menu_item_getinfo().
Quote:
|
Re: New AMXX Menu System
Thanks for pointing that out hornet. I revised the examples that don't need menu_item_getinfo.
|
Re: New AMXX Menu System
May be you could put a second exemple with the same basic menu in a static version where you don't have to destroy the menu.
|
Re: New AMXX Menu System
Your Advanced Vote Menu never gives ends and never gives a player 255 health. I can't find the error. Could somebody look for it?
|
All times are GMT -4. The time now is 01:24. |
Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.