This site is a testing version, but all data is shared with the live forum.


Raised This Month: $ Target: $400
 0% 

New AMXX Menu System


Post New Thread Reply   
 
Thread Tools Display Modes
dark_style
Senior Member
Join Date: Jul 2009
Location: Bulgaria
Old 10-13-2011 , 00:44   Re: New AMXX Menu System
Reply With Quote #351

Quote:
Originally Posted by ConnorMcLeod View Post
Should work (you may convert seconds to something more friendly though).
Well, I tried this:

PHP Code:
formatextimeleftcharsmaxtimeleft ), "Timeleft: %d"get_timeleft() / 60 
Now it shows me the minutes, but without the seconds.. For example - if the timelimit is set to 59 the title will be "59", how I can do it to shows me the seconds?

Last edited by dark_style; 10-13-2011 at 00:54.
dark_style is offline
jim_yang
Veteran Member
Join Date: Aug 2006
Old 10-13-2011 , 01:02   Re: New AMXX Menu System
Reply With Quote #352

get_timeleft() % 60
__________________
Project : CSDM all in one - 99%
<team balancer#no round end#entity remover#quake sounds#fake full#maps management menu#players punishment menu#no team flash#colored flashbang#grenade trails#HE effect#spawn protection#weapon arena#weapon upgrade#auto join#no weapon drop#one name>
jim_yang is offline
dark_style
Senior Member
Join Date: Jul 2009
Location: Bulgaria
Old 10-13-2011 , 01:09   Re: New AMXX Menu System
Reply With Quote #353

Quote:
Originally Posted by jim_yang View Post
get_timeleft() % 60
Thanks.

PHP Code:
formatextimeleftcharsmaxtimeleft ), "Timeleft: %d:%d"get_timeleft() / 60get_timeleft() % 60 
Works perfectly fine. Thank you guys!

Last edited by dark_style; 10-13-2011 at 01:38.
dark_style is offline
hannes
Member
Join Date: Sep 2010
Old 10-22-2011 , 11:47   Re: New AMXX Menu System
Reply With Quote #354

thx helped me alot
hannes is offline
Evaldas.Grigas
Senior Member
Join Date: Sep 2011
Location: Lithuania
Old 10-29-2011 , 03:36   Re: New AMXX Menu System
Reply With Quote #355

I read Anywai, Idiots. In the end of the text
__________________
Please enter this website everyday: http://forums.alliedmods.net/showthread.php?t=169067
Evaldas.Grigas is offline
Send a message via Skype™ to Evaldas.Grigas
makavelli
Senior Member
Join Date: Nov 2006
Location: Belgium
Old 01-16-2012 , 11:57   Re: New AMXX Menu System
Reply With Quote #356

I'm confused, you said this
menu_additem(menu, "\wGo to SubMenu", "2", 0);
but does the first selection have a submenu too?
cous i dont want my 2nd choice to say go to submenu becous then i would need a menu in a menu in a menu (a sub-sub menu :p)
makavelli is offline
Atov
Junior Member
Join Date: Jan 2012
Old 01-16-2012 , 13:39   Re: New AMXX Menu System
Reply With Quote #357

Is it possible to delete the blank menu lines, if you only have 3 items?

Last edited by Atov; 01-16-2012 at 13:39.
Atov is offline
fysiks
Veteran Member
Join Date: Sep 2007
Location: Flatland, USA
Old 01-16-2012 , 16:12   Re: New AMXX Menu System
Reply With Quote #358

Quote:
Originally Posted by makavelli View Post
I'm confused, you said this
menu_additem(menu, "\wGo to SubMenu", "2", 0);
but does the first selection have a submenu too?
cous i dont want my 2nd choice to say go to submenu becous then i would need a menu in a menu in a menu (a sub-sub menu :p)
The first option is not a sub-menu. The second option is. You can name it whatever you want. You can change the order however you want. You only code what you want to have in your menu.

Quote:
Originally Posted by Atov View Post
Is it possible to delete the blank menu lines, if you only have 3 items?
What blank llines? The lines between the options and the exit option? Afaik, no you can't remove blank lines.
__________________
fysiks is offline
makavelli
Senior Member
Join Date: Nov 2006
Location: Belgium
Old 01-17-2012 , 09:58   Re: New AMXX Menu System
Reply With Quote #359

ok so if i want to make 2 submenu's in the main menu,
can do do this then in public menu_handler(id, menu, item):
PHP Code:
case 1:         
   {          
   
SubMenu1 (id);        
   }        
 case 
2:         
  {  
   
SubMenu2(id);         
  } 
and then just go work out submenu 1 and 2 in 2 seperate code blocks? and should i also have 2 submenu_handler blocks?
(submenu1 (id) and submenu2 (id) ) / ( public submenu_handler (id, menu, item)
how do i let the plugin know out of wich submenu handler to choose for submenu1 en submenu2 is?

Last edited by makavelli; 01-17-2012 at 09:59.
makavelli is offline
fysiks
Veteran Member
Join Date: Sep 2007
Location: Flatland, USA
Old 01-17-2012 , 19:18   Re: New AMXX Menu System
Reply With Quote #360

You need one handler for every time you use menu_create(). This means that if you have one menu with two sub menu's then you need a total of three handler functions.
__________________
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 14:38.


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