ItsMods

Full Version: Easy Menu
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2 3
Is there a way to use the menu for allowing players to choose which key they want to bind to actionslot2 ?
(08-19-2011, 19:09)Cyborgking Wrote: [ -> ]Is there a way to use the menu for allowing players to choose which key they want to bind to actionslot2 ?

Yeah sure, lemme find that function
But it is a class that I made Big Grin another example to make it more clear i want to set players dozombie to 1 when he clicks an option. Where should I put self.doZombie = 1;
(08-19-2011, 19:09)Cyborgking Wrote: [ -> ]Is there a way to use the menu for allowing players to choose which key they want to bind to actionslot2 ?

This is the function:
Code:
FRAME_CHOICE_BIND( 22, "@MENU_FORWARD_CAPS", "+forward", ; )

this is what you want:
C++ Code
  1. FRAME_CHOICE_BIND( "BUTTONNUMBER", "TEXT TO DISPLAY", "+actionslot 2", ; )

(08-19-2011, 19:22)Lemon Wrote: [ -> ]But it is a class that I made Big Grin another example to make it more clear i want to set players dozombie to 1 when he clicks an option. Where should I put self.doZombie = 1;

Code:
scriptMenuResponse "make_zombie"

then just do this:

C++ Code
  1. onMenuResponse()
  2. {
  3. self endon( "disconnect" );
  4. while( true )
  5. {
  6. self waittill( "menuresponse", menu, response )
  7.  
  8. if( response == "make_zombie" )
  9. self.isZombie = 1;
  10. }
  11. }
(08-19-2011, 19:27)iAegle Wrote: [ -> ]
(08-19-2011, 19:09)Cyborgking Wrote: [ -> ]Is there a way to use the menu for allowing players to choose which key they want to bind to actionslot2 ?

This is the function:
Code:
FRAME_CHOICE_BIND( 22, "@MENU_FORWARD_CAPS", "+forward", ; )

this is what you want:
C++ Code
  1. FRAME_CHOICE_BIND( "BUTTONNUMBER", "TEXT TO DISPLAY", "+actionslot 2", ; )
Awsome! Smile
Now I have added that button to the options menu!
I can't get it to work in my own menu though.
I get: unknown menu item keyword 1
(08-19-2011, 20:53)Cyborgking Wrote: [ -> ]
(08-19-2011, 19:27)iAegle Wrote: [ -> ]
(08-19-2011, 19:09)Cyborgking Wrote: [ -> ]Is there a way to use the menu for allowing players to choose which key they want to bind to actionslot2 ?

This is the function:
Code:
FRAME_CHOICE_BIND( 22, "@MENU_FORWARD_CAPS", "+forward", ; )

this is what you want:
C++ Code
  1. FRAME_CHOICE_BIND( "BUTTONNUMBER", "TEXT TO DISPLAY", "+actionslot 2", ; )
Awsome! Smile
Now I have added that button to the options menu!
I can't get it to work in my own menu though.
I get: unknown menu item keyword 1

Yeah I'm pretty sure you'll have to include a .inc file but I don't know which one.. Add me on steam: x_uzz
nice steamid.
(08-19-2011, 21:05)Lemon Wrote: [ -> ]nice steamid.

no it sucks and doesn't make any sense, but thats fine
(08-19-2011, 20:54)iAegle Wrote: [ -> ]
(08-19-2011, 20:53)Cyborgking Wrote: [ -> ]
(08-19-2011, 19:27)iAegle Wrote: [ -> ]
(08-19-2011, 19:09)Cyborgking Wrote: [ -> ]Is there a way to use the menu for allowing players to choose which key they want to bind to actionslot2 ?

This is the function:
Code:
FRAME_CHOICE_BIND( 22, "@MENU_FORWARD_CAPS", "+forward", ; )

this is what you want:
C++ Code
  1. FRAME_CHOICE_BIND( "BUTTONNUMBER", "TEXT TO DISPLAY", "+actionslot 2", ; )
Awsome! Smile
Now I have added that button to the options menu!
I can't get it to work in my own menu though.
I get: unknown menu item keyword 1

Yeah I'm pretty sure you'll have to include a .inc file but I don't know which one.. Add me on steam: x_uzz
It's fine, even though i get the error it do is in the menu now in-game i see. Smile
Pages: 1 2 3