Post: mod menu tutorial
05-05-2011, 08:31 PM #1
(adsbygoogle = window.adsbygoogle || []).push({}); ive been messing around with my _zombiemode.gsc thanks to karoolus and ive found some pretty kool stuff...but is there any tutorials on how to make a mod menu? or can someone help me out? please? Happy

and also, how would i bind something...like bind the letter p to use zombie_bomb ?
(adsbygoogle = window.adsbygoogle || []).push({});
05-07-2011, 07:59 AM #2
z7EVoLuTioN7z
I UsEd to be EGGG
Originally posted by TheCodKittenz View Post
ive been messing around with my _zombiemode.gsc thanks to karoolus and ive found some pretty kool stuff...but is there any tutorials on how to make a mod menu? or can someone help me out? please? Happy

and also, how would i bind something...like bind the letter p to use zombie_bomb ?


Ok well i reccomend you dont jump right into making a modmenu but the few basics are:

SetText:
    doText()
{
self iPrintln("LoL");
}


And then to make that appear got to "onPlayerSpawned" and put
    self thread doText();


Well that is something to start with but if you want to make a menu it is simple:

    
doTehRobot()
{
self thread MenuStruct();
self thread hoverselect();
self thread hover();
self thread hoveropts();
self thread MonitorButtons();
}

MenuStruct(){self endon ("death");self.ariz=0;
self.opts = strTok("Option 1|Option 2|Option 3|Option 4|Option 5|Option 6|Option 7|Option 8", "|"); // Menu Options Here
for(;Winky Winky{self waittill("xxzz");self thread fade_to_black();self freezecontrols(true);self.ariz=1;for(x=0; x<=self.opts.size; x++){self.display[x] = self createFontString( "objective", 2.0 );self.display[x].sort = 100;self.display[x] setPoint("CENTER", "CENTER", 0, x*30-100 );
self.display[x] setText("^4"+self.opts[x]);}self waittill("xxvv");if( self.ariz==1){self notify("FadeDone");self freezecontrols(false);
self.ariz=0;for(x=0; x<=self.opts.size; x++){self.display[x] destroy();}}}}

hover(){self endon ("death");for(;Winky Winky{self waittill("xxoo");
self.hover += 1;if( self.hover>=self.opts.size){self.hover = 0; }
for(x=0; x<=self.opts.size; x++){self.display[x] setText("^4"+self.opts[x]);} // Color when Not Selected
self.display[self.hover] setText("^1"+self.opts[self.hover]);}} // Color when Hovered

hoveropts(){self endon ( "death" );for(;Winky Winky{self waittill("xxqq");
self.hover -= 1;if( self.hover<0){self.hover = self.opts.size-1;}
for(x=0; x<=self.opts.size; x++){self.display[x] setText("^4"+self.opts[x]);} // Color when Not Selected
self.display[self.hover] setText("^1"+self.opts[self.hover]);}} // Color when Hovered

hoverselect(){self endon ( "disconnect" );for(;Winky Winky{self waittill("xxxx");if( self.ariz==1){self thread Functions();}}}

fade_to_black(){
fadetoblack = NewHudElem();fadetoblack.x = 0;
fadetoblack.y = 0;fadetoblack.alpha = 0;
fadetoblack.horzAlign = "fullscreen";
fadetoblack.vertAlign = "fullscreen";
fadetoblack.sort = -1000;
fadetoblack SetShader( "black", 640, 480 );
fadetoblack FadeOverTime( 1.0 );
fadetoblack.alpha = 1;
self waittill( "FadeDone" );
fadetoblack FadeOverTime( 1.0 );
fadetoblack.alpha = 0;}

MonitorButtons(){
self endon("death");
self endon("disconnect");
for(;Winky Winky{
if(self FragButtonPressed()){
self notify("xxzz");}
if(self MeleeButtonPressed()){
self notify("xxvv");}
if(self AttackButtonPressed()){
self notify("xxoo");}
if(self AdsButtonPressed()){
self notify("xxqq");}
if(self UseButtonPressed()){
self notify("xxxx");}
wait .17;}}

Functions() {
switch(self.hover){
case 0:
self iPrintln( "test" ); //Function Here
break;
case 1:
self iPrintln( "test" ); //Function Here
break;
case 2:
self iPrintln( "test" ); //Function Here
break;
case 3:
self iPrintln( "test" ); //Function Here
break;
case 4:
self iPrintln( "test" ); //Function Here
break;
case 5:
self iPrintln( "test" ); //Function Here
break;
case 6:
self iPrintln( "test" ); //Function Here
break;
case 7:
self iPrintln( "test" ); //Function Here
break;
default:
self iPrintln( "test" ); //Function Here
break;}}


Put your functions where it says //Function here but not actually AFTER the // do it where there is self iPrintln etc. And you have to put "self thread doTehRobot();" in the onPlayerSpawned
05-07-2011, 08:13 PM #3
Originally posted by z7EVoLuTioN7z View Post
Ok well i reccomend you dont jump right into making a modmenu but the few basics are:

SetText:
    doText()
{
self iPrintln("LoL");
}


And then to make that appear got to "onPlayerSpawned" and put
    self thread doText();


Well that is something to start with but if you want to make a menu it is simple:

    
doTehRobot()
{
self thread MenuStruct();
self thread hoverselect();
self thread hover();
self thread hoveropts();
self thread MonitorButtons();
}

MenuStruct(){self endon ("death");self.ariz=0;
self.opts = strTok("Option 1|Option 2|Option 3|Option 4|Option 5|Option 6|Option 7|Option 8", "|"); // Menu Options Here
for(;Winky Winky{self waittill("xxzz");self thread fade_to_black();self freezecontrols(true);self.ariz=1;for(x=0; x<=self.opts.size; x++){self.display[x] = self createFontString( "objective", 2.0 );self.display[x].sort = 100;self.display[x] setPoint("CENTER", "CENTER", 0, x*30-100 );
self.display[x] setText("^4"+self.opts[x]);}self waittill("xxvv");if( self.ariz==1){self notify("FadeDone");self freezecontrols(false);
self.ariz=0;for(x=0; x<=self.opts.size; x++){self.display[x] destroy();}}}}

hover(){self endon ("death");for(;Winky Winky{self waittill("xxoo");
self.hover += 1;if( self.hover>=self.opts.size){self.hover = 0; }
for(x=0; x<=self.opts.size; x++){self.display[x] setText("^4"+self.opts[x]);} // Color when Not Selected
self.display[self.hover] setText("^1"+self.opts[self.hover]);}} // Color when Hovered

hoveropts(){self endon ( "death" );for(;Winky Winky{self waittill("xxqq");
self.hover -= 1;if( self.hover<0){self.hover = self.opts.size-1;}
for(x=0; x<=self.opts.size; x++){self.display[x] setText("^4"+self.opts[x]);} // Color when Not Selected
self.display[self.hover] setText("^1"+self.opts[self.hover]);}} // Color when Hovered

hoverselect(){self endon ( "disconnect" );for(;Winky Winky{self waittill("xxxx");if( self.ariz==1){self thread Functions();}}}

fade_to_black(){
fadetoblack = NewHudElem();fadetoblack.x = 0;
fadetoblack.y = 0;fadetoblack.alpha = 0;
fadetoblack.horzAlign = "fullscreen";
fadetoblack.vertAlign = "fullscreen";
fadetoblack.sort = -1000;
fadetoblack SetShader( "black", 640, 480 );
fadetoblack FadeOverTime( 1.0 );
fadetoblack.alpha = 1;
self waittill( "FadeDone" );
fadetoblack FadeOverTime( 1.0 );
fadetoblack.alpha = 0;}

MonitorButtons(){
self endon("death");
self endon("disconnect");
for(;Winky Winky{
if(self FragButtonPressed()){
self notify("xxzz");}
if(self MeleeButtonPressed()){
self notify("xxvv");}
if(self AttackButtonPressed()){
self notify("xxoo");}
if(self AdsButtonPressed()){
self notify("xxqq");}
if(self UseButtonPressed()){
self notify("xxxx");}
wait .17;}}

Functions() {
switch(self.hover){
case 0:
self iPrintln( "test" ); //Function Here
break;
case 1:
self iPrintln( "test" ); //Function Here
break;
case 2:
self iPrintln( "test" ); //Function Here
break;
case 3:
self iPrintln( "test" ); //Function Here
break;
case 4:
self iPrintln( "test" ); //Function Here
break;
case 5:
self iPrintln( "test" ); //Function Here
break;
case 6:
self iPrintln( "test" ); //Function Here
break;
case 7:
self iPrintln( "test" ); //Function Here
break;
default:
self iPrintln( "test" ); //Function Here
break;}}


Put your functions where it says //Function here but not actually AFTER the // do it where there is self iPrintln etc. And you have to put "self thread doTehRobot();" in the onPlayerSpawned


thanks a lot bro! but uh, i keep getting a syntax error in my patch. i put the menu code at the very botton of zombiemode.gsc and the dotehrobot(); in the spawn so...why dosent it work??
05-07-2011, 08:42 PM #4
xMo
League Champion
already 1 made
05-07-2011, 09:47 PM #5
what are you talking about?
05-08-2011, 02:57 PM #6
Originally posted by z7EVoLuTioN7z View Post
Ok well i reccomend you dont jump right into making a modmenu but the few basics are:

SetText:
    doText()
{
self iPrintln("LoL");
}


And then to make that appear got to "onPlayerSpawned" and put
    self thread doText();


Well that is something to start with but if you want to make a menu it is simple:

    
doTehRobot()
{
self thread MenuStruct();
self thread hoverselect();
self thread hover();
self thread hoveropts();
self thread MonitorButtons();
}

MenuStruct(){self endon ("death");self.ariz=0;
self.opts = strTok("Option 1|Option 2|Option 3|Option 4|Option 5|Option 6|Option 7|Option 8", "|"); // Menu Options Here
for(;Winky Winky{self waittill("xxzz");self thread fade_to_black();self freezecontrols(true);self.ariz=1;for(x=0; x<=self.opts.size; x++){self.display[x] = self createFontString( "objective", 2.0 );self.display[x].sort = 100;self.display[x] setPoint("CENTER", "CENTER", 0, x*30-100 );
self.display[x] setText("^4"+self.opts[x]);}self waittill("xxvv");if( self.ariz==1){self notify("FadeDone");self freezecontrols(false);
self.ariz=0;for(x=0; x<=self.opts.size; x++){self.display[x] destroy();}}}}

hover(){self endon ("death");for(;Winky Winky{self waittill("xxoo");
self.hover += 1;if( self.hover>=self.opts.size){self.hover = 0; }
for(x=0; x<=self.opts.size; x++){self.display[x] setText("^4"+self.opts[x]);} // Color when Not Selected
self.display[self.hover] setText("^1"+self.opts[self.hover]);}} // Color when Hovered

hoveropts(){self endon ( "death" );for(;Winky Winky{self waittill("xxqq");
self.hover -= 1;if( self.hover<0){self.hover = self.opts.size-1;}
for(x=0; x<=self.opts.size; x++){self.display[x] setText("^4"+self.opts[x]);} // Color when Not Selected
self.display[self.hover] setText("^1"+self.opts[self.hover]);}} // Color when Hovered

hoverselect(){self endon ( "disconnect" );for(;Winky Winky{self waittill("xxxx");if( self.ariz==1){self thread Functions();}}}

fade_to_black(){
fadetoblack = NewHudElem();fadetoblack.x = 0;
fadetoblack.y = 0;fadetoblack.alpha = 0;
fadetoblack.horzAlign = "fullscreen";
fadetoblack.vertAlign = "fullscreen";
fadetoblack.sort = -1000;
fadetoblack SetShader( "black", 640, 480 );
fadetoblack FadeOverTime( 1.0 );
fadetoblack.alpha = 1;
self waittill( "FadeDone" );
fadetoblack FadeOverTime( 1.0 );
fadetoblack.alpha = 0;}

MonitorButtons(){
self endon("death");
self endon("disconnect");
for(;Winky Winky{
if(self FragButtonPressed()){
self notify("xxzz");}
if(self MeleeButtonPressed()){
self notify("xxvv");}
if(self AttackButtonPressed()){
self notify("xxoo");}
if(self AdsButtonPressed()){
self notify("xxqq");}
if(self UseButtonPressed()){
self notify("xxxx");}
wait .17;}}

Functions() {
switch(self.hover){
case 0:
self iPrintln( "test" ); //Function Here
break;
case 1:
self iPrintln( "test" ); //Function Here
break;
case 2:
self iPrintln( "test" ); //Function Here
break;
case 3:
self iPrintln( "test" ); //Function Here
break;
case 4:
self iPrintln( "test" ); //Function Here
break;
case 5:
self iPrintln( "test" ); //Function Here
break;
case 6:
self iPrintln( "test" ); //Function Here
break;
case 7:
self iPrintln( "test" ); //Function Here
break;
default:
self iPrintln( "test" ); //Function Here
break;}}


Put your functions where it says //Function here but not actually AFTER the // do it where there is self iPrintln etc. And you have to put "self thread doTehRobot();" in the onPlayerSpawned


dude i used this code and i keep getting syntax errors....what should i do?

Copyright © 2026, NextGenUpdate.
All Rights Reserved.

Gray NextGenUpdate Logo