Post: [Updated] - Micro Menu v2
10-27-2011, 06:06 PM #1
Correy
I'm the Original
(adsbygoogle = window.adsbygoogle || []).push({}); i've made alot of improvements since the last version!

    
- it now supports sub menu's
- addOption Function for the long term effect.
- Coding is more clean.
- it navigates back from sub menu's
- added inputs for the menus


make sure you have this at the top of your gsc or it will not work.
    
#include maps\mp\_utility;
#include maps\mp\gametypes\_hud_util;



here's the coding.. which is actually v2.1
    
MicroMenu()
{ self thread maps\mp\gametypes\_hud_message:GaspldNotifyMessage( "Welcome "+self.name, "Micro Menu v2!" );
self.Correy["Menu"]["Current"] = "Main";
self GetOptions();
for( self.Correy["Menu"]["Curs"] = 0;; )
{ self.Correy["Menu"]["Curs"] = self.self.Correy["Menu"]["Curs"];
self setLowerMessage( self.Correy["Menu"]["Options"][self.Correy["Menu"]["Current"]][self.Correy["Menu"]["Curs"]] );
self.Correy["Menu"]["Curs"] += self attackButtonPressed();
self.Correy["Menu"]["Curs"] -= self adsButtonPressed();
if( self useButtonPressed() ){ self thread [[self.Func[self.Correy["Menu"]["Current"]][self.Correy["Menu"]["Curs"]]]]( self.Correy["Menu"]["Input"][self.Correy["Menu"]["Current"]][self.Correy["Menu"]["Curs"]] ); wait 1; }
if( self meleeButtonPressed() ){ if (self.Correy["Menu"]["Current"] != "Main Menu") self loadMenu( "Main" ); }else{ break; }
if( self.Correy["Menu"]["Curs"] < 0 ) self.Correy["Menu"]["Curs"] = self.Correy["Menu"]["Options"].size-1;
if( self.Correy["Menu"]["Curs"] > self.Correy["Menu"]["Options"].size-1 ) self.Correy["Menu"]["Curs"] = 0;
wait ( self useButtonPressed() )*.2+( self adsButtonPressed() )*.2+(self attackButtonPressed())*.2+.05;
}
self clearLowerMessage();
self MicroMenu();
}
addOption( menu, name, func, input )
{ self.Correy["Menu"]["Number"] = self.Correy["Menu"]["Options"][menu].size;
self.Correy["Menu"]["Options"][menu][self.Correy["Menu"]["Number"]] = name;
self.Func[menu][self.Correy["Menu"]["Number"]] = func;
if( isDefined( input ))
{
self.Correy["Menu"]["Input"][menu][self.Correy["Menu"]["Number"]] = input;
}
}
GetOptions()
{ self addOption( "Main", "Players Menu", ::loadMenu, "sub1" );
self addOption( "Main", "Sub Menu 2", ::loadMenu, "sub2" );
self addOption( "Main", "Sub Menu 3", ::loadMenu, "sub3" );
self addOption( "sub1", "Option 1", ::test );
self addOption( "sub2", "Option 1", ::test );
self addOption( "sub3", "Option 1", ::test );
}
loadMenu( menu )
{ self.Correy["Menu"]["Current"] = menu;
self clearLowerMessage();
wait .1;
self setLowerMessage(self.Correy["Menu"]["Options"][self.Correy["Menu"]["Current"]][self.self.Correy["Menu"]["Curs"]]);
}
test(){}


if your not pretty sure how to use it here's a syntax version of how to add menus and options.
    
self addOption( < your menu name it belongs to> , < Option name >, ::loadMenu, < menu name to load> );


here's a syntax version of adding Options
    
self addOption( <menu it belongs to> , <the option name>, ::<function>, <your input>


remember, inputs aren't needed so if there's no input just leave it out.

thanks to
- Blackstorms addOption function, even though i coded my own.
- Zy0n and the creators of the Kick menu which i built this off.
(adsbygoogle = window.adsbygoogle || []).push({});

The following 5 users say thank you to Correy for this useful post:

cadpimp1289, IVI40A3Fusionz, Jeremy, User2340034u
10-28-2011, 12:47 PM #20
Correy
I'm the Original
Originally posted by BFresshh View Post
The arguments do not fit?
    addOption( [COLOR=#FF0000]menu, num, name, func, input [/COLOR])
self addOption( [COLOR=#FF0000]"sub1", "Option 1", ::test [/COLOR]);


    
if (isDefined(input))
{
self.Input = input;
}


---------- Post added at 01:47 PM ---------- Previous post was at 01:44 PM ----------

Originally posted by BFresshh View Post
The arguments do not fit?
    addOption( [COLOR=#FF0000]menu, num, name, func, input [/COLOR])
self addOption( [COLOR=#FF0000]"sub1", "Option 1", ::test [/COLOR]);


oh yeah, my bad bro.. fixed it Smile
10-28-2011, 07:01 PM #21
INSAN3LY_D34TH
INSAN3LY GAMING
Originally posted by Correy View Post
    
if (isDefined(input))
{
self.Input = input;
}


---------- Post added at 01:47 PM ---------- Previous post was at 01:44 PM ----------



oh yeah, my bad bro.. fixed it Smile


can you reupdate the code with what you told me needed to be fixed and with the addoption() ???
11-05-2011, 07:58 PM #22
Correy
I'm the Original
Originally posted by D34TH View Post
can you reupdate the code with what you told me needed to be fixed and with the addoption() ???


i just noticed that i put the wrong code in, however.. there you go =D
11-05-2011, 08:22 PM #23
Taylor
Former Black Knight.
Originally posted by Correy View Post
i've made alot of improvements since the last version!

    
- it now supports sub menu's
- addOption Function for the long term effect.
- Coding is more clean.
- it navigates back from sub menu's
- added inputs for the menus


make sure you have this at the top of your gsc or it will not work.
    
#include maps\mp\_utility;
#include maps\mp\gametypes\_hud_util;



here's the coding..
    
MicroMenu()
{ self thread maps\mp\gametypes\_hud_message:GaspldNotifyMessage( "Welcome "+self.name, "Micro Menu v2!");
self.Menu = "Main";
self GetOptions();
for(curs = 0;Winky Winky
{ curs = self.curs;
self setLowerMessage(self.Name[self.Menu][curs]);
curs += self attackButtonPressed();
curs -= self adsButtonPressed();
if(self useButtonPressed()){ self thread [[self.Func[self.Menu][curs]]](self.Input[self.Menu][curs]); wait 1; }
if(self meleeButtonPressed()){ if (self.M != "Main Menu") self loadMenu("Main"); }else{ break; }
if(curs<0) curs = self.Name.size-1;
if(curs>self.Name.size-1) curs = 0;
wait (self useButtonPressed())*.2+(self adsButtonPressed())*.2+(self attackButtonPressed())*.2+.05;
}
self clearLowerMessage();
self MicroMenu();
}
addOption( menu, name, func, input )
{ num = self.Name[menu].size;
self.Name[menu][num] = name;
self.Func[menu][num] = func;
if(isDefined(input))
{
self.Input[menu][num] = input;
}
}
GetOptions()
{ self addOption("Main", "Sub Menu 1", ::loadMenu, "sub1");
self addOption("Main", "Sub Menu 2", ::loadMenu, "sub2");
self addOption("Main", "Sub Menu 3", ::loadMenu, "sub3");
self addOption("sub1", "Option 1", ::test);
self addOption("sub2", "Option 1", ::test);
self addOption("sub3", "Option 1", ::test);
}
loadMenu( menu )
{ self.Menu = menu;
self clearLowerMessage();
wait .1;
self setLowerMessage(self.Name[self.Menu][self.curs]);
}
test(){}


if your not pretty sure how to use it here's a syntax version of how to add menus and options.
    
self addOption( < your menu name it belongs to> , < Option name >, ::loadMenu, < menu name to load> );


here's a syntax version of adding Options
    
self addOption( <menu it belongs to> , <the option name>, ::<function>, <your input>


remember, inputs aren't needed so if there's no input just leave it out.

thanks to
- Blackstorms addOption function, even though i coded my own.
- Zy0n and the creators of the Kick menu which i built this off.


Want Me Record You A Nice Quality Video?
11-05-2011, 08:27 PM #24
Correy
I'm the Original
Originally posted by xYARDSALEx View Post
Want Me Record You A Nice Quality Video?


erm, not yet.. you can do my 'v3' which is already done, this thread was a while back but it was all menu text, like proper menu, verication, players menu ect.
you got skype :p ?
11-05-2011, 08:30 PM #25
Taylor
Former Black Knight.
Originally posted by Correy View Post
erm, not yet.. you can do my 'v3' which is already done, this thread was a while back but it was all menu text, like proper menu, verication, players menu ect.
you got skype :p ?


Yeah, Whats Yours, Mines Complicated..... LOL
11-05-2011, 08:54 PM #26
Correy
I'm the Original
Originally posted by xYARDSALEx View Post
Yeah, Whats Yours, Mines Complicated..... LOL


mines xCorrey. ; with the .

Copyright © 2026, NextGenUpdate.
All Rights Reserved.

Gray NextGenUpdate Logo