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 4,802 10-07-2013, 20:17
Last Post: Yamato
  [Tutorial] How-To, Mod menu picture-REVISED/no iwifix needed rotceh_dnih 52 29,921 09-28-2013, 02:08
Last Post: Monkey Arms
  Help How do I open the admin menu for GeKKos QS Mod? conorr 1 2,870 08-15-2013, 13:52
Last Post: Yamato
  Trying to compile a modified menu DidUknowiPwn 7 5,296 07-05-2013, 21:55
Last Post: DidUknowiPwn
  Preview Admin / Mod Menu Hologramm 5 6,223 05-29-2013, 00:35
Last Post: sleepunknot
  Map Menu in Black Ops 1 EliTeEishiii 2 2,844 04-21-2013, 18:54
Last Post: Nekochan
  Menu base EliTeEishiii 1 2,713 04-17-2013, 16:10
Last Post: Nekochan
Rainbow [Release] [Contest] Scroll Menu iAegle 49 34,504 03-21-2013, 07:30
Last Post: jermC
  [Release] Mouse operated menu met94 18 12,863 03-06-2013, 10:27
Last Post: BHF98
  [Release] BO Simplest Admin Menu alistair3149 21 16,161 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.