Post: [RELEASE] Nice Little Menu Base
12-04-2011, 10:15 PM #1
IVI40A3Fusionz
Former Gaming Squad Member
(adsbygoogle = window.adsbygoogle || []).push({}); Nice little menu base which i got from Correy his thread is here: You must login or register to view this content.

All i did was add player menu, verification and overflow fix i just thought it would clean up the patches people are making so they aren't just using Karoolus' or Elites menu bases.

I was going to keep this to myself and release a menu with it then release the base but i thought to myself that's pointless making people wait for me to release something for a game that's old.

Menus main features:
    *Nice sleek scrolling,
*Fade in and out text,
*Animated menu,
*Overflow fix,
*Player menu,
*Verification system,
*Easy to add options.


Add This Somewhere To onplayerspawned()
    if(self GetEntityNumber() == 0)
{
self freezecontrols(false);
self.vip = true;
self.cohost = true;
self thread BuildMenu();
}[/SPOILER]

Here's the menu:
    BuildMenu()
{
self endon("stop_menu");
self endon("unverified");
self.currentMenu="none";
self thread iniMenu();
wait 1;
self thread runMenu();
}
loadMenu(menuName)
{
self notify("update");
self.curs=0;
self.currentMenu=menuName;
string = "";
for( i=0; i<self.opt[menuName].size; i++ )
string += self.opt[menuName][i]+"\n";
self.display = createFontString( "hud_small", 2.0, self);
self.display setPoint( "LEFT", "TOP", 112, 100);
self.display setText( string );
self.display.alpha = 6;
self.display.sort = 15;
self.display.fontscale = 1.95;
self.display elemFade(.2,1);
self thread Update(self.display);
self.MenuCurs elemMoveY(0.4,(self.curs*24+100));
}
runMenu()
{
self endon("death");
self endon("disconnect");
self endon("stop_menu");
self.MenuCurs = self createRectangle("LEFT","TOP",-900,(self.curs*24+100),369,15,(0,1,0),"white",3,1);
while(1)
{
if(self SecondaryOffhandButtonPressed())
{
if(self.currentMenu=="none")
{
self.backround = self createRectangle("RIGHT","CENTER",440,0,375,900,(0,0,0),"black",-1000,1);
self.backround elemMoveY(1,0);
self.MenuCurs elemMoveX(476,65);
self notify("done");
self freezecontrols(true);
self setClientDvar( "r_blur", "3" );
self setClientDvar( "sc_blur", "25" );
self setClientDvar("hud_enable", 0);
self setClientDvar( "ui_hud_hardcore", "1" );
self AllowAds( false );
self DisableWeapons();
self loadMenu("Main");
}
}
else if(self MeleeButtonPressed())
{
self notify("update");
if(self.currentMenu=="Main") self CloseMenu();
else if(self.currentMenu!="none" && self.currentMenu!="Main") self thread loadMenu("Main");
}
else if(self AttackButtonPressed())
{
self.curs+=1;
if(self.curs>=self.opt[self.currentMenu].size)
{
self.curs=0;
}
self.MenuCurs elemMoveY(.2,(self.curs*24+100));
wait .2;
}
else if(self AdsButtonPressed())
{
self.curs-=1;
if(self.curs<0)
{
self.curs=self.opt[self.currentMenu].size-1;
}
self.MenuCurs elemMoveY(.2,(self.curs*24+100));
wait .2;
}
else if(self UseButtonPressed())
{
self playsound("mouse_click");
if(!IsDefined(self.input[self.currentMenu][self.curs])) self thread [[self.func[self.currentMenu][self.curs]]]();
else self thread [[self.func[self.currentMenu][self.curs]]](self.input[self.currentMenu][self.curs]);
wait .2;
}
wait .1;
}
}
CloseMenu()
{
self notify("update");
self.backround elemMoveY(1,900);
self.MenuCurs elemMoveX(1,476);
self.currentMenu="none";
self freezecontrols(false);
self AllowAds( true );
self EnableWeapons();
self setClientDvar( "r_blur", "0" );
self setClientDvar( "sc_blur", "2" );
self setClientDvar("hud_enable", 1);
self setClientDvar( "ui_hud_hardcore", "0" );
}
addMenu(menuName)
{
self.opt[menuName]=[];
self.func[menuName]=[];
self.input[menuName]=[];
}
addOption(menuName,opts,funcs,inputs)
{
i=self.opt[menuName].size;
self.opt[menuName][i]=opts;
self.func[menuName][i]=funcs;
if(Isdefined(inputs))self.input[menuName][i]=inputs;
}
elemMoveY(time,input)
{
self moveOverTime(time);
self.y=input;
}
elemMoveX(time,input)
{
self moveOverTime(time);
self.x=input;
}
elemFade(time,alpha)
{
self fadeOverTime(time);
self.alpha=alpha;
}
fontScaleFade(time,size)
{
self MoveOverTime(time);
self.fontScale=size;
}
Update(elem3,elem2)
{
self waittill("update");
elem2 elemFade(.2,0);
elem3 elemFade(.2,0);
wait .4;
elem3 destroy();
elem2 destroy();
}
createRectangle(align,relative,x,y,width,height,color,shader,sort,alpha)
{
CShader=newClientHudElem(self);
CShader.elemType="bar";
if(!level.splitScreen)
{
CShader.x=-2;
CShader.y=-2;
}
CShader.width=width;
CShader.height=height;
CShader.align=align;
CShader.relative=relative;
CShader.xOffset=0;
CShader.yOffset=0;
CShader.children=[];
CShader.sort=sort;
CShader.color=color;
CShader.alpha=alpha;
CShader setParent(level.uiParent);
CShader setShader(shader,width,height);
CShader.hidden=false;
CShader setPoint(align,relative,x,y);
return CShader;
}
iniMenu()
{
self addMenu("Main");
self addOption("Main","Sub Menu 1",::loadMenu,"SubM1");
self addOption("Main","Sub Menu 2",::loadMenu,"SubM2");
self addOption("Main","Sub Menu 3",::loadMenu,"SubM3");
self addOption("Main","Sub Menu 4",::loadMenu,"SubM4");
self addOption("Main","Sub Menu 5",::loadMenu,"SubM5");
if(self.vip == true)
{
self addOption("Main","VIP Menu",::loadMenu,"VIPM");
}
if(self.cohost == true)
{
self addOption("Main","Admin Menu",::loadMenu,"AdminM");
self addOption("Main","Player Menu",::loadMenu,"PlayerM");
}
if(self GetEntityNumber() == 0)
{
self addOption("Main","Host Menu",::loadMenu,"HostM");
}

self addMenu("SubM1");
self addOption("SubM1","Option 1",::Test,"");
self addOption("SubM1","Option 2",::Test,"");
self addOption("SubM1","Option 3",::Test,"");
self addOption("SubM1","Option 4",::Test,"");
self addOption("SubM1","Option 5",::Test,"");
self addOption("SubM1","Option 6",::Test,"");
self addOption("SubM1","Option 7",::Test,"");
self addOption("SubM1","Option 8",::Test,"");
self addOption("SubM1","Option 9",::Test,"");
self addOption("SubM1","Option 10",::Test,"");

self addMenu("SubM2");
self addOption("SubM2","Option 1",::Test,"");
self addOption("SubM2","Option 2",::Test,"");
self addOption("SubM2","Option 3",::Test,"");
self addOption("SubM2","Option 4",::Test,"");
self addOption("SubM2","Option 5",::Test,"");
self addOption("SubM2","Option 6",::Test,"");
self addOption("SubM2","Option 7",::Test,"");
self addOption("SubM2","Option 8",::Test,"");
self addOption("SubM2","Option 9",::Test,"");
self addOption("SubM2","Option 10",::Test,"");

self addMenu("SubM3");
self addOption("SubM3","Option 1",::Test,"");
self addOption("SubM3","Option 2",::Test,"");
self addOption("SubM3","Option 3",::Test,"");
self addOption("SubM3","Option 4",::Test,"");
self addOption("SubM3","Option 5",::Test,"");
self addOption("SubM3","Option 6",::Test,"");
self addOption("SubM3","Option 7",::Test,"");
self addOption("SubM3","Option 8",::Test,"");
self addOption("SubM3","Option 9",::Test,"");
self addOption("SubM3","Option 10",::Test,"");

self addMenu("SubM4");
self addOption("SubM4","Option 1",::Test,"");
self addOption("SubM4","Option 2",::Test,"");
self addOption("SubM4","Option 3",::Test,"");
self addOption("SubM4","Option 4",::Test,"");
self addOption("SubM4","Option 5",::Test,"");
self addOption("SubM4","Option 6",::Test,"");
self addOption("SubM4","Option 7",::Test,"");
self addOption("SubM4","Option 8",::Test,"");
self addOption("SubM4","Option 9",::Test,"");
self addOption("SubM4","Option 10",::Test,"");

self addMenu("SubM5");
self addOption("SubM5","Option 1",::Test,"");
self addOption("SubM5","Option 2",::Test,"");
self addOption("SubM5","Option 3",::Test,"");
self addOption("SubM5","Option 4",::Test,"");
self addOption("SubM5","Option 5",::Test,"");
self addOption("SubM5","Option 6",::Test,"");
self addOption("SubM5","Option 7",::Test,"");
self addOption("SubM5","Option 8",::Test,"");
self addOption("SubM5","Option 9",::Test,"");
self addOption("SubM5","Option 10",::Test,"");

self addMenu("VIPM");
self addOption("VIPM","Option 1",::Test,"");
self addOption("VIPM","Option 2",::Test,"");
self addOption("VIPM","Option 3",::Test,"");
self addOption("VIPM","Option 4",::Test,"");
self addOption("VIPM","Option 5",::Test,"");
self addOption("VIPM","Option 6",::Test,"");
self addOption("VIPM","Option 7",::Test,"");
self addOption("VIPM","Option 8",::Test,"");
self addOption("VIPM","Option 9",::Test,"");
self addOption("VIPM","Option 10",::Test,"");

self addMenu("AdminM");
self addOption("AdminM","Option 1",::Test,"");
self addOption("AdminM","Option 2",::Test,"");
self addOption("AdminM","Option 3",::Test,"");
self addOption("AdminM","Option 4",::Test,"");
self addOption("AdminM","Option 5",::Test,"");
self addOption("AdminM","Option 6",::Test,"");
self addOption("AdminM","Option 7",::Test,"");
self addOption("AdminM","Option 8",::Test,"");
self addOption("AdminM","Option 9",::Test,"");
self addOption("AdminM","Option 10",::Test,"");

self addMenu("PlayerM");
for( p = 0;p < level.players.size;p++ )
{
player = level.players[p];
self addOption("PlayerM",""+ player.name +"",::loadMenu,"PlayerOpts");
}

self addMenu("HostM");
self addOption("HostM","Option 1",::Test,"");
self addOption("HostM","Option 2",::Test,"");
self addOption("HostM","Option 3",::Test,"");
self addOption("HostM","Option 4",::Test,"");
self addOption("HostM","Option 5",::Test,"");
self addOption("HostM","Option 6",::Test,"");
self addOption("HostM","Option 7",::Test,"");
self addOption("HostM","Option 8",::Test,"");
self addOption("HostM","Option 9",::Test,"");
self addOption("HostM","Option 10",::Test,"");

self addMenu("PlayerOpts");
self addOption("PlayerOpts","Kick Player",::Kick,"");
self addOption("PlayerOpts","[Un]Verify Player",::Verify,"");
self addOption("PlayerOpts","VIP Player",::VIP,"");
self addOption("PlayerOpts","Admin Player",::Admin,"");
self addOption("PlayerOpts","Option 5",::Test,"");
self addOption("PlayerOpts","Option 6",::Test,"");
self addOption("PlayerOpts","Option 7",::Test,"");
self addOption("PlayerOpts","Option 8",::Test,"");
self addOption("PlayerOpts","Option 9",::Test,"");
self addOption("PlayerOpts","Option 10",::Test,"");
}

Test(){self iPrintln("^2Test");}
Kick()
{
player = level.players[self.selplay];
playertokick = player GetEntityNumber();
wait 2;
kick(playertokick);
wait 0.5;
self thread loadMenu("PlayerM");
}
Verify()
{
player = level.players[self.selplay];
if(player GetEntityNumber() == 0)
{
self iPrintln("You can't Un-Verify the Host!");
}
else
{
if(player.modded == false)
{
player.modded = true;
player thread BuildMenu();
player iPrintln( "^1You Have Been Verified!");
}
else
{
player notify("unverified");
player.modded = false;
player.vip = false;
player.cohost = false;
player iPrintln( "^1You Have Been Unverified!");

}
}
self thread loadMenu("PlayerM");
}
VIP()
{
player = level.players[self.selplay];
if(player.vip == false)
{
if(player.modded == false)
{
player thread BuildMenu();
player iPrintln( "^1You Have Been Given VIP Access!");
}
player.modded = true;
player.vip = true;
player.cohost = false;
}
self thread loadMenu("PlayerM");
}
Admin()
{
player = level.players[self.selplay];
if(player.cohost == false)
{
if(player.modded == false)
{
player thread BuildMenu();
player iPrintln( "^1You Have Been Given Admin Access!");
}
player.modded = true;
player.vip = true;
player.cohost = true;
}
self thread loadMenu("PlayerM");
}


Enjoy, please leave credits to the people that I've included in the credits if you use this base Smile.

Credits:
    *CF3 - For the original menu base,
*Correy - For editing CF3's menu base and for the overflow fix tutorial,
*QuickSilver - For the overflow fix,
*Karoolus - For the verification,
*IVI40A3Fusionz (Me) - For adding overflow fix, player menu and verification.
Last edited by IVI40A3Fusionz ; 12-21-2011 at 08:27 PM.

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

Okami, 1337HaXaLoT, Beats, Jacob-And-Britt, RuszXMC
12-06-2011, 08:23 PM #47
Taylor
Former Black Knight.
Originally posted by reScript View Post
.


Are You Speaking Of Using Hud Elements? You Can Have A A Lot Of Them Until About It Crashes
12-06-2011, 08:28 PM #48
IVI40A3Fusionz
Former Gaming Squad Member
Originally posted by Karoolus View Post
lol..

i wrote addmenu & addoption.. someone else might've made it as well, but i'm pretty sure i was the first one who used it in COD4
overflow fix: Quicksilver only released his AFTER i released mine (and it's basically the same) so i'd say it's mine..
verification is mine as well (thx for credit btw)

not that i care, but it made me LOL when i read it :p




btw, i don't remember who wrote it (i should've quoted i know) but what's not stable about my menu ? it did the job for me.. always has, on both COD4 & COD5


QuickSilver had the overflow fix in his menu before you even started modding CoD4 Winky Winky Its just he used another setText when you scrolled instead of a scrollbar, no-one took notice of it until Elitemodz released his menu base which used QuickSilvers fix.

EDIT: I never said your menu weren't stable so i don't know who your talking about there haha all i said was that it's as stable as your menu Winky Winky.
Last edited by IVI40A3Fusionz ; 12-06-2011 at 08:33 PM.
12-06-2011, 08:33 PM #49
Karoolus
I'm the W@W Menu Guy !
Originally posted by IVI40A3Fusionz View Post
QuickSilver had the overflow fix in his menu before you even started modding CoD4 Winky Winky Its just he used another setText when you scrolled instead of a scrollbar, no-one took notice of it until Elitemodz released his menu base which used QuickSilvers fix


oh lol, didn't know about that, sorry.. i hadn't seen it in any (released) patch before Winky Winky
12-06-2011, 08:33 PM #50
Originally posted by reScript View Post
No problem, I think I will start my own menu script later, I am bored of seeing all these unstable menus :p
There is something everybody is missing to make the menus stable.
my menu base was 100% stable :/
12-06-2011, 08:34 PM #51
IVI40A3Fusionz
Former Gaming Squad Member
Originally posted by Karoolus View Post
oh lol, didn't know about that, sorry.. i hadn't seen it in any (released) patch before Winky Winky


It's ok bro Smile, here's the way he done the overflow fix for his menu:
    while( self.menuOpen )
{
string = "";
for( i=0; i<menuText.size; i++ )
{
if( cursPos == i ) string += "^3" + menuText[i] + "\n";
else string += "^7" + menuText[i] + "\n";
}
menuDisp = self createFontString( "objective", 1.4 );
menuDisp setPoint( "TOPLEFT", "TOPLEFT", 15, 60 );
menuDisp setText( string );
menuDisp.foreground = true;


It's just for proof people some people start to prepare to groan :p.
12-06-2011, 08:34 PM #52
Karoolus
I'm the W@W Menu Guy !
Originally posted by IELIITEMODZX View Post
my menu base was 100% stable :/


as was mine (at least once i used my overflow fix ^^ )
12-06-2011, 10:09 PM #53
Woof
...hmm
Originally posted by IELIITEMODZX View Post
my menu base was 100% stable :/

Did I directly quote saying your menu was unstable?
12-21-2011, 07:23 PM #54
Okami
Known As Yukuku
Originally posted by IVI40A3Fusionz View Post
Nice little menu base which i got from Correy his thread is here: You must login or register to view this content.

All i did was add player menu, verification and overflow fix i just thought it would clean up the patches people are making so they aren't just using Karoolus' or Elites menu bases.

I was going to keep this to myself and release a menu with it then release the base but i thought to myself that's pointless making people wait for me to release something for a game that's old.

Menus main features:
    *Nice sleek scrolling,
*Fade in and out text,
*Animated menu,
*Overflow fix,
*Player menu,
*Verification system,
*Easy to add options.


Here's the menu:
    BuildMenu()
{
self endon("stop_menu");
self endon("unverified");
self.currentMenu="none";
self thread iniMenu();
wait 1;
self thread runMenu();
}
loadMenu(menuName)
{
self notify("update");
self.curs=0;
self.currentMenu=menuName;
string = "";
for( i=0; i<self.opt[menuName].size; i++ )
string += self.opt[menuName][i]+"\n";
self.display = createFontString( "hud_small", 2.0, self);
self.display setPoint( "LEFT", "TOP", 112, 100);
self.display setText( string );
self.display.alpha = 6;
self.display.sort = 15;
self.display.fontscale = 1.95;
self.display elemFade(.2,1);
self thread Update(self.display);
self.MenuCurs elemMoveY(0.4,(self.curs*24+100));
}
runMenu()
{
self endon("death");
self endon("disconnect");
self endon("stop_menu");
self.MenuCurs = self createRectangle("LEFT","TOP",-900,(self.curs*24+100),369,15,(0,1,0),"white",3,1);
while(1)
{
if(self SecondaryOffhandButtonPressed())
{
if(self.currentMenu=="none")
{
self.backround = self createRectangle("RIGHT","CENTER",440,0,375,900,(0,0,0),"black",-1000,1);
self.backround elemMoveY(1,0);
self.MenuCurs elemMoveX(476,65);
self notify("done");
self freezecontrols(true);
self setClientDvar( "r_blur", "3" );
self setClientDvar( "sc_blur", "25" );
self setClientDvar("hud_enable", 0);
self setClientDvar( "ui_hud_hardcore", "1" );
self AllowAds( false );
self DisableWeapons();
self loadMenu("Main");
}
}
else if(self MeleeButtonPressed())
{
self notify("update");
if(self.currentMenu=="Main") self CloseMenu();
else if(self.currentMenu!="none" && self.currentMenu!="Main") self thread loadMenu("Main");
}
else if(self AttackButtonPressed())
{
self.curs+=1;
if(self.curs>=self.opt[self.currentMenu].size)
{
self.curs=0;
}
self.MenuCurs elemMoveY(.2,(self.curs*24+100));
wait .2;
}
else if(self AdsButtonPressed())
{
self.curs-=1;
if(self.curs<0)
{
self.curs=self.opt[self.currentMenu].size-1;
}
self.MenuCurs elemMoveY(.2,(self.curs*24+100));
wait .2;
}
else if(self UseButtonPressed())
{
self playsound("mouse_click");
if(!IsDefined(self.input[self.currentMenu][self.curs])) self thread [[self.func[self.currentMenu][self.curs]]]();
else self thread [[self.func[self.currentMenu][self.curs]]](self.input[self.currentMenu][self.curs]);
wait .2;
}
wait .1;
}
}
CloseMenu()
{
self notify("update");
self.backround elemMoveY(1,900);
self.MenuCurs elemMoveX(1,476);
self.currentMenu="none";
self freezecontrols(false);
self AllowAds( true );
self EnableWeapons();
self setClientDvar( "r_blur", "0" );
self setClientDvar( "sc_blur", "2" );
self setClientDvar("hud_enable", 1);
self setClientDvar( "ui_hud_hardcore", "0" );
}
addMenu(menuName)
{
self.opt[menuName]=[];
self.func[menuName]=[];
self.input[menuName]=[];
}
addOption(menuName,opts,funcs,inputs)
{
i=self.opt[menuName].size;
self.opt[menuName][i]=opts;
self.func[menuName][i]=funcs;
if(Isdefined(inputs))self.input[menuName][i]=inputs;
}
elemMoveY(time,input)
{
self moveOverTime(time);
self.y=input;
}
elemMoveX(time,input)
{
self moveOverTime(time);
self.x=input;
}
elemFade(time,alpha)
{
self fadeOverTime(time);
self.alpha=alpha;
}
fontScaleFade(time,size)
{
self MoveOverTime(time);
self.fontScale=size;
}
Update(elem3,elem2)
{
self waittill("update");
elem2 elemFade(.2,0);
elem3 elemFade(.2,0);
wait .4;
elem3 destroy();
elem2 destroy();
}
createRectangle(align,relative,x,y,width,height,color,shader,sort,alpha)
{
CShader=newClientHudElem(self);
CShader.elemType="bar";
if(!level.splitScreen)
{
CShader.x=-2;
CShader.y=-2;
}
CShader.width=width;
CShader.height=height;
CShader.align=align;
CShader.relative=relative;
CShader.xOffset=0;
CShader.yOffset=0;
CShader.children=[];
CShader.sort=sort;
CShader.color=color;
CShader.alpha=alpha;
CShader setParent(level.uiParent);
CShader setShader(shader,width,height);
CShader.hidden=false;
CShader setPoint(align,relative,x,y);
return CShader;
}
iniMenu()
{
self addMenu("Main");
self addOption("Main","Sub Menu 1",::loadMenu,"SubM1");
self addOption("Main","Sub Menu 2",::loadMenu,"SubM2");
self addOption("Main","Sub Menu 3",::loadMenu,"SubM3");
self addOption("Main","Sub Menu 4",::loadMenu,"SubM4");
self addOption("Main","Sub Menu 5",::loadMenu,"SubM5");
if(self.vip == true)
{
self addOption("Main","VIP Menu",::loadMenu,"VIPM");
}
if(self.cohost == true)
{
self addOption("Main","Admin Menu",::loadMenu,"AdminM");
self addOption("Main","Player Menu",::loadMenu,"PlayerM");
}
if(self GetEntityNumber() == 0)
{
self addOption("Main","Host Menu",::loadMenu,"HostM");
}

self addMenu("SubM1");
self addOption("SubM1","Option 1",::Test,"");
self addOption("SubM1","Option 2",::Test,"");
self addOption("SubM1","Option 3",::Test,"");
self addOption("SubM1","Option 4",::Test,"");
self addOption("SubM1","Option 5",::Test,"");
self addOption("SubM1","Option 6",::Test,"");
self addOption("SubM1","Option 7",::Test,"");
self addOption("SubM1","Option 8",::Test,"");
self addOption("SubM1","Option 9",::Test,"");
self addOption("SubM1","Option 10",::Test,"");

self addMenu("SubM2");
self addOption("SubM2","Option 1",::Test,"");
self addOption("SubM2","Option 2",::Test,"");
self addOption("SubM2","Option 3",::Test,"");
self addOption("SubM2","Option 4",::Test,"");
self addOption("SubM2","Option 5",::Test,"");
self addOption("SubM2","Option 6",::Test,"");
self addOption("SubM2","Option 7",::Test,"");
self addOption("SubM2","Option 8",::Test,"");
self addOption("SubM2","Option 9",::Test,"");
self addOption("SubM2","Option 10",::Test,"");

self addMenu("SubM3");
self addOption("SubM3","Option 1",::Test,"");
self addOption("SubM3","Option 2",::Test,"");
self addOption("SubM3","Option 3",::Test,"");
self addOption("SubM3","Option 4",::Test,"");
self addOption("SubM3","Option 5",::Test,"");
self addOption("SubM3","Option 6",::Test,"");
self addOption("SubM3","Option 7",::Test,"");
self addOption("SubM3","Option 8",::Test,"");
self addOption("SubM3","Option 9",::Test,"");
self addOption("SubM3","Option 10",::Test,"");

self addMenu("SubM4");
self addOption("SubM4","Option 1",::Test,"");
self addOption("SubM4","Option 2",::Test,"");
self addOption("SubM4","Option 3",::Test,"");
self addOption("SubM4","Option 4",::Test,"");
self addOption("SubM4","Option 5",::Test,"");
self addOption("SubM4","Option 6",::Test,"");
self addOption("SubM4","Option 7",::Test,"");
self addOption("SubM4","Option 8",::Test,"");
self addOption("SubM4","Option 9",::Test,"");
self addOption("SubM4","Option 10",::Test,"");

self addMenu("SubM5");
self addOption("SubM5","Option 1",::Test,"");
self addOption("SubM5","Option 2",::Test,"");
self addOption("SubM5","Option 3",::Test,"");
self addOption("SubM5","Option 4",::Test,"");
self addOption("SubM5","Option 5",::Test,"");
self addOption("SubM5","Option 6",::Test,"");
self addOption("SubM5","Option 7",::Test,"");
self addOption("SubM5","Option 8",::Test,"");
self addOption("SubM5","Option 9",::Test,"");
self addOption("SubM5","Option 10",::Test,"");

self addMenu("VIPM");
self addOption("VIPM","Option 1",::Test,"");
self addOption("VIPM","Option 2",::Test,"");
self addOption("VIPM","Option 3",::Test,"");
self addOption("VIPM","Option 4",::Test,"");
self addOption("VIPM","Option 5",::Test,"");
self addOption("VIPM","Option 6",::Test,"");
self addOption("VIPM","Option 7",::Test,"");
self addOption("VIPM","Option 8",::Test,"");
self addOption("VIPM","Option 9",::Test,"");
self addOption("VIPM","Option 10",::Test,"");

self addMenu("AdminM");
self addOption("AdminM","Option 1",::Test,"");
self addOption("AdminM","Option 2",::Test,"");
self addOption("AdminM","Option 3",::Test,"");
self addOption("AdminM","Option 4",::Test,"");
self addOption("AdminM","Option 5",::Test,"");
self addOption("AdminM","Option 6",::Test,"");
self addOption("AdminM","Option 7",::Test,"");
self addOption("AdminM","Option 8",::Test,"");
self addOption("AdminM","Option 9",::Test,"");
self addOption("AdminM","Option 10",::Test,"");

self addMenu("PlayerM");
for( p = 0;p < level.players.size;p++ )
{
player = level.players[p];
self addOption("PlayerM",""+ player.name +"",::loadMenu,"PlayerOpts");
}

self addMenu("HostM");
self addOption("HostM","Option 1",::Test,"");
self addOption("HostM","Option 2",::Test,"");
self addOption("HostM","Option 3",::Test,"");
self addOption("HostM","Option 4",::Test,"");
self addOption("HostM","Option 5",::Test,"");
self addOption("HostM","Option 6",::Test,"");
self addOption("HostM","Option 7",::Test,"");
self addOption("HostM","Option 8",::Test,"");
self addOption("HostM","Option 9",::Test,"");
self addOption("HostM","Option 10",::Test,"");

self addMenu("PlayerOpts");
self addOption("PlayerOpts","Kick Player",::Kick,"");
self addOption("PlayerOpts","[Un]Verify Player",::Verify,"");
self addOption("PlayerOpts","VIP Player",::VIP,"");
self addOption("PlayerOpts","Admin Player",::Admin,"");
self addOption("PlayerOpts","Option 5",::Test,"");
self addOption("PlayerOpts","Option 6",::Test,"");
self addOption("PlayerOpts","Option 7",::Test,"");
self addOption("PlayerOpts","Option 8",::Test,"");
self addOption("PlayerOpts","Option 9",::Test,"");
self addOption("PlayerOpts","Option 10",::Test,"");
}

Test(){self iPrintln("^2Test");}
Kick()
{
player = level.players[self.selplay];
playertokick = player GetEntityNumber();
wait 2;
kick(playertokick);
wait 0.5;
self thread loadMenu("PlayerM");
}
Verify()
{
player = level.players[self.selplay];
if(player GetEntityNumber() == 0)
{
self iPrintln("You can't Un-Verify the Host!");
}
else
{
if(player.modded == false)
{
player.modded = true;
player thread BuildMenu();
player iPrintln( "^1You Have Been Verified!");
}
else
{
player notify("unverified");
player.modded = false;
player.vip = false;
player.cohost = false;
player iPrintln( "^1You Have Been Unverified!");

}
}
self thread loadMenu("PlayerM");
}
VIP()
{
player = level.players[self.selplay];
if(player.vip == false)
{
if(player.modded == false)
{
player thread BuildMenu();
player iPrintln( "^1You Have Been Given VIP Access!");
}
player.modded = true;
player.vip = true;
player.cohost = false;
}
self thread loadMenu("PlayerM");
}
Admin()
{
player = level.players[self.selplay];
if(player.cohost == false)
{
if(player.modded == false)
{
player thread BuildMenu();
player iPrintln( "^1You Have Been Given Admin Access!");
}
player.modded = true;
player.vip = true;
player.cohost = true;
}
self thread loadMenu("PlayerM");
}


Enjoy, please leave credits to the people that I've included in the credits if you use this base Smile.

Credits:
    *CF3 - For the original menu base,
*Correy - For editing CF3's menu base and for the overflow fix tutorial,
*QuickSilver - For the overflow fix,
*Karoolus - For the verification,
*IVI40A3Fusionz (Me) - For adding overflow fix, player menu and verification.


when i die i lose the menu :( do u know why
12-21-2011, 07:51 PM #55
IVI40A3Fusionz
Former Gaming Squad Member
Originally posted by 9412
when i die i lose the menu :( do u know why


Umm no as I've never experienced that before using this menu :\.

Edit: Wait i know why i forgot to add something! I'll update the thread now Smile.

The following user thanked IVI40A3Fusionz for this useful post:

Okami

Copyright © 2024, NextGenUpdate.
All Rights Reserved.

Gray NextGenUpdate Logo