Raised This Month: $ Target: $400
 0% 

Menus


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Natsheh
Veteran Member
Join Date: Sep 2012
Old 01-10-2015 , 11:21   Re: Menus
Reply With Quote #1

PHP Code:
             public Menu(id)
             {
             new 
Txt[64]
             
formatex(Txtcharsmax(Txt), "%s" Check() ? "Item":"\dItem")
             
menu_additem(MenuTxt"info"0)
             }
            public 
Handle_menu(idmenu ,item)
            {
                            switch( 
item )
                              case 
0:
                              {
                                              if(
Check()) //Code...
                                              
else Menu(id)
                                }
             } 
Check if item is disabled by function Check if it return's false then item is disable but the number color wont get grey, if returns true then item is enabled & his num color be white!.

i hope you get my idea

Last edited by Natsheh; 01-10-2015 at 11:28.
Natsheh is offline
Send a message via MSN to Natsheh Send a message via Skype™ to Natsheh
yan1255
Senior Member
Join Date: Jul 2011
Old 01-11-2015 , 13:13   Re: Menus
Reply With Quote #2

Quote:
Originally Posted by Natsheh View Post
PHP Code:
             public Menu(id)
             {
             new 
Txt[64]
             
formatex(Txtcharsmax(Txt), "%s" Check() ? "Item":"\dItem")
             
menu_additem(MenuTxt"info"0)
             }
            public 
Handle_menu(idmenu ,item)
            {
                            switch( 
item )
                              case 
0:
                              {
                                              if(
Check()) //Code...
                                              
else Menu(id)
                                }
             } 
Check if item is disabled by function Check if it return's false then item is disable but the number color wont get grey, if returns true then item is enabled & his num color be white!.

i hope you get my idea
I understand your idea of course and I even had it on my own but I want to see if theres any way of disabling the item while continuing seeing the number in red
__________________
yan1255 is offline
fysiks
Veteran Member
Join Date: Sep 2007
Location: Flatland, USA
Old 01-11-2015 , 14:07   Re: Menus
Reply With Quote #3

You can do it manually using the default menus. You cannot do it using newmenus.inc if you still want the text to be greyed out using the callback.
__________________
fysiks is offline
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 15:32.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode