Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Help I have created a menu
#1
I have created a menu like changeclass.menu, i have added:
Code:
menufile,menufile,ui_mp\scriptmenus\changeoffhand.menu

Now how I can open it by another menu? i use this:
Quote:open "menu name"
but it doesnt work, i have to precache menu?
PS: my menu is not like a quickmessage
Reply

#2
(07-29-2011, 11:39)Puffiamo Wrote: I have created a menu like changeclass.menu, i have added:
Code:
menufile,menufile,ui_mp\scriptmenus\changeoffhand.menu

Now how I can open it by another menu? i use this:
Quote:open "menu name"
but it doesnt work, i have to precache menu?
PS: my menu is not like a quickmessage

If the menuDef struct there is a line that says:
name "yourMenuNameHere".

Somewhere in a GSC file, preachce the menu using:
precacheMenu("yourMenuNameHere");
and you open the menu using:
self openMenu("yourMenuNameHere");

Pretty straight forward...
Oh wait.... 'open it by another menu'. didn't see that.
-------
Can't you just handle the message through the onMenuResponse loop and then open it through there?

Example:
In the menu file somewhere, add this when you want the other menu to open.
scriptMenuResponse "open_other_menu";

In the onMenuRespose loop,
Code:
onMenuResponse()
{
    self endon( "death" );
    self endon( "disconnect" );
    
    while( true )
    {
        self waittill( "menuresponse", menu, response );
        
        if( response == "open_other_menu" )
        {
            self closeMenus();
            self openMenu("other_menu_name_here");
        }
    }
}
[Image: 30xhrep.png]

A casual conversation between barata and I about Nukem.
Reply

#3
(07-29-2011, 12:17)master131 Wrote:
(07-29-2011, 11:39)Puffiamo Wrote: I have created a menu like changeclass.menu, i have added:
Code:
menufile,menufile,ui_mp\scriptmenus\changeoffhand.menu

Now how I can open it by another menu? i use this:
Quote:open "menu name"
but it doesnt work, i have to precache menu?
PS: my menu is not like a quickmessage

If the menuDef struct there is a line that says:
name "yourMenuNameHere".

Somewhere in a GSC file, preachce the menu using:
precacheMenu("yourMenuNameHere");
and you open the menu using:
self openMenu("yourMenuNameHere");

Pretty straight forward...
Oh wait.... 'open it by another menu'. didn't see that.

Thank you master but i solved by myself Blush

If you work with menu _menu.gsc is the way Smile
Reply



Possibly Related Threads…
Thread Author Replies Views Last Post
Question Help Admin menu koren30 4 5,104 10-07-2013, 20:17
Last Post: Yamato
  [Tutorial] How-To, Mod menu picture-REVISED/no iwifix needed rotceh_dnih 52 31,922 09-28-2013, 02:08
Last Post: Monkey Arms
  Help How do I open the admin menu for GeKKos QS Mod? conorr 1 3,067 08-15-2013, 13:52
Last Post: Yamato
  Trying to compile a modified menu DidUknowiPwn 7 5,655 07-05-2013, 21:55
Last Post: DidUknowiPwn
  Preview Admin / Mod Menu Hologramm 5 6,874 05-29-2013, 00:35
Last Post: sleepunknot
  Map Menu in Black Ops 1 EliTeEishiii 2 3,032 04-21-2013, 18:54
Last Post: Nekochan
  Menu base EliTeEishiii 1 2,860 04-17-2013, 16:10
Last Post: Nekochan
Rainbow [Release] [Contest] Scroll Menu iAegle 49 36,538 03-21-2013, 07:30
Last Post: jermC
  [Release] Mouse operated menu met94 18 13,609 03-06-2013, 10:27
Last Post: BHF98
  [Release] BO Simplest Admin Menu alistair3149 21 17,125 02-22-2013, 08:57
Last Post: ItsEffecT

Forum Jump:


Users browsing this thread:
1 Guest(s)

Forum Powered By MyBB, Theme by © 2002-2024 Melroy van den Berg.