You are viewing our Forum Archives. To view or take place in current topics click here.
LOT OF Mod Menu Bases {Thread} + How to Test Mods! on PC
Posted:
LOT OF Mod Menu Bases {Thread} + How to Test Mods! on PCPosted:
Status: Offline
Joined: Aug 06, 201113Year Member
Posts: 899
Reputation Power: 17
Status: Offline
Joined: Aug 06, 201113Year Member
Posts: 899
Reputation Power: 17
Ok so i will add this in the comments because it says i used to much smile faces? lol well heres one to start with
Don't No how to make a mod menu go to this post Forums/t=2081781/updatedhow-to-ma...on-pc.html
Goes good with coding thread sticky
Make sure you read the comments ( first 11 ) for the rest of the menus
CF3
Must put this in maps/_debug.gsc
Video what it looks like::
How to make a mod menu and Test on the PC!.p.s. sorry about all the spoils
First thing you want to do is download a clean menu base I think CF3 menu base works the best! Controls for CF3 menu are, you throw a grenade or on the computer its G
then f to select and v to go backon the computer and right click and left click to go up and down[spoil]
[ Register or Signin to view external links. ]
Also it might be easier to download (notepad ++ )
[ Register or Signin to view external links. ]
it looks like this
[ Register or Signin to view external links. ]
Last edited by MrCoolGuy ; edited 6 times in total
Don't No how to make a mod menu go to this post Forums/t=2081781/updatedhow-to-ma...on-pc.html
MrCoolGuy (aka Da_MoDDer) 's Mod menu Bases Thread
Goes good with coding thread sticky
Make sure you read the comments ( first 11 ) for the rest of the menus
CF3
#include common_scripts\utility;
#include maps\_utility;
#include maps\_hud_util;
menu()// thread this on onPlayerSpawn
{
self.currentMenu="none";// variable i've used used to notify current Menu
self thread iniMenu();
wait 1;
self thread runMenu();
}
iniMenu()
{
self addMenu("main", "Main Menu");
self addOption("main", "Sub Menu 1", ::loadMenu, "sub1" );
self addOption("main", "Option 2", ::test );
self addOption("main", "Option 3", ::test );
self addOption("main", "Option 4", ::test );
self addOption("main", "Option 5", ::test );
self addMenu("sub1", "Sub Menu 1");
self addOption("sub1", "Option 1", ::test );
self addOption("sub1", "Option 2", ::test );
self addOption("sub1", "Option 3", ::test );
self addOption("sub1", "Option 4", ::test );
self addOption("sub1", "Option 5", ::test );
}
loadMenu(menuName)
{
self notify("update");
self.curs=0;
self.currentMenu=menuName;
self.titleText = createfontString("defualt", 2.0, self);
self.titleText.sort = 100;
self.titleText setPoint("LEFT", "TOP", -290, (-2*20+100));
self.titleText setText(self.title[menuName]);
self.titleText.alpha = 0;
self.titleText elemFade(.2,1);
for(x=0; x<=self.opt[menuName].size; x++)
{
self.display[x] = createfontString("defualt", 1.7, self);
self.display[x].sort = 100;
self.display[x] setPoint("LEFT", "TOP", -290, x*20+100);
self.display[x].alpha = 0;
self.display[x] setText(self.opt[menuName][x]);
self.display[x] elemFade(.2,1);
self thread Update(self.display[x],self.titleText);
}
self.MenuCurs elemMoveY(0.2, (self.curs*20+100));
}
runMenu()
{
self endon ("death");
self endon ("disconnect");
self.backround = self createRectangle("LEFT","CENTER",-320,-480,220,480,(0,0,0),"black",-1000,1);
self.MenuCurs = self createRectangle("LEFT", "TOP", -534, (self.curs*20+100), 214, 17,(1,0,0),"white",3,1);
while( 1 )
{
if( self FragButtonPressed())
{
if(self.currentMenu=="none" )
{
self.backround elemMoveY(1,0);
self.MenuCurs elemMoveX(1,-317);
self notify("done");
self freezecontrols(true);
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*20+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*20+100));
wait .2;
}
else if( self UseButtonPressed())
{
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,-480);
self.MenuCurs elemMoveX(1,-534);
self.currentMenu="none";
self freezecontrols(false);
}
Update( elem3, elem2)
{
self waittill("update");
elem2 elemFade(.2, 0);
elem3 elemFade(.2, 0);
wait .4;
elem3 destroy();
elem2 destroy();
}
test()
{
self iPrintlnBold("Menu:"+self.currentMenu );
self iPrintlnBold( "Option:"+self.curs);
}
createRectangle(align,relative,x,y,width,height,color,shader,sort,alpha)
{
barElemBG = newClientHudElem( self );
barElemBG.elemType = "bar";
if ( !level.splitScreen )
{
barElemBG.x = -2;
barElemBG.y = -2;
}
barElemBG.width = width;
barElemBG.height = height;
barElemBG.align = align;
barElemBG.relative = relative;
barElemBG.xOffset = 0;
barElemBG.yOffset = 0;
barElemBG.children = [];
barElemBG.sort = sort;
barElemBG.color = color;
barElemBG.alpha = alpha;
barElemBG setParent( level.uiParent );
barElemBG setShader( shader, width , height );
barElemBG.hidden = false;
barElemBG setPoint(align,relative,x,y);
return barElemBG;
}
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;
}
empty(){}
addMenu(mName,titl)
{
self.title[mName] = titl;
self.opt[mName] = [];
self.func[mName] = [];
self.input[mName] = [];
}
addOption(mName,opts,funcs,inputs)
{
i = self.opt[mName].size ;
self.opt[mName][i] = opts;
self.func[mName][i] = funcs;
if(Isdefined(inputs)) self.input[mName][i] = inputs;
}
Video what it looks like::
How to make a mod menu and Test on the PC!.p.s. sorry about all the spoils
How To make a mod menu
First thing you want to do is download a clean menu base I think CF3 menu base works the best! Controls for CF3 menu are, you throw a grenade or on the computer its G
then f to select and v to go backon the computer and right click and left click to go up and down[spoil]
[ Register or Signin to view external links. ]
Also it might be easier to download (notepad ++ )
[ Register or Signin to view external links. ]
it looks like this
[ Register or Signin to view external links. ]
Then once you have all that downloaded open up ff.viewer
go to: [ Register or Signin to view external links. ] then copy and paste everything in maps/_art.gsc and paste it in notepad ( not notepad ++ but regular notepad ) and then go to File>save as > _art.gsc (like this) to desktop
[ Register or Signin to view external links. ]
do the samething to the following:
Also for each make sure you save it as Ex: for maps/_debug.gsc save as _debug.gsc and so on.Make sure you change the Save as type to all files! for each
go to: [ Register or Signin to view external links. ] then copy and paste everything in maps/_art.gsc and paste it in notepad ( not notepad ++ but regular notepad ) and then go to File>save as > _art.gsc (like this) to desktop
[ Register or Signin to view external links. ]
do the samething to the following:
- maps/_debug.gsc
maps/_cheat.gsc
maps/_createdments.gsc
maps/_hud_message.gsc
Also for each make sure you save it as Ex: for maps/_debug.gsc save as _debug.gsc and so on.Make sure you change the Save as type to all files! for each
Then right click on _debug.gsc notepad file that you made and open with notepad ++ then this should pop up:
[ Register or Signin to view external links. ]
You can name your main menu names by editing the text in the main box like this
[ Register or Signin to view external links. ]
[color=green]And in you want to edit the name of a submenu you go to this:
[ Register or Signin to view external links. ]
the main menu 1 to whatever goes to a submenu 1 and that brings you to a new page in the menu and you can name the subOptions what ever you want and suboption 1 goes to the first text on the page and if you scroll down all the way you see empty, thats where you put all the codes like for god mode and stuff.
[ Register or Signin to view external links. ]
where you see toggle_god C&P it to the test that means if you click on it it will toggle god
If you want to add a new menu you do this
[ Register or Signin to view external links. ]
you make a line after the last menu and you type the name of the menu.
then you C&P Func[Whatever][whatever]=whatever to the next line;
and same with Input[whatever][whatever]="";
Save the Text edit and C&P _debug.gsc to ff.viewer's _debug.gsc and your done!
If you have any questions post a reply and i'll be more then happy to answer them!
P.S. you can get a lot of codes from -COSTANZ- sticky, Forums/t=2026046/the-ultimate-thr...dated.html
First off You need to buy CoD WaW for the PC (No! I will not supply the Download Link to CoD WaW Don't Be Cheap Buy it yourself)
This is a Follow Up to my other post, Forums/t=2065547/how-to-make-a-mo...ailed.html *MUST Complete That TUT Before You use this one* You need JZip and WinWar. Once you have these Files,
[ Register or Signin to view external links. ]
Make a folder called whatever you want and make a folder inside that one called maps and drag the folders in there. After you did that, Drag the folder, (Not maps but the folder you put maps into) it into JZip i named mine (Great White)
[ Register or Signin to view external links. ]
Then delete the file. Drag the folder inside that folder, Maps like this
[ Register or Signin to view external links. ]
You can exit out of JZip Now!
Then you should see a JZip file on your Desktop,Right click it and click Open With>Winwar it should come up in a winwar file once you did that, then click the three dots and right click the file and click rename as whatever your name is then put .IWD
then go to computer> Local disk c:>Users>Your user that has Cod WaW>click this box and right AppData>Local>Activision>CoD WaW
[ Register or Signin to view external links. ]
Then make a new folder called mods
[ Register or Signin to view external links. ]
Then open Mods Folder and make a new folder called whatever you want and drag the .IWD file into the folder
Then start up CoD WaW (Signal player if you have Downloaded version)And go to Mods
[ Register or Signin to view external links. ]
Then the screen should go black then start up the modded version of CoD WaW
Hope this Helped!
-Da MoDDer
Voches
[ Register or Signin to view external links. ]
[ Register or Signin to view external links. ]
[ Register or Signin to view external links. ]
[ Register or Signin to view external links. ]
You can name your main menu names by editing the text in the main box like this
[ Register or Signin to view external links. ]
[color=green]And in you want to edit the name of a submenu you go to this:
[ Register or Signin to view external links. ]
the main menu 1 to whatever goes to a submenu 1 and that brings you to a new page in the menu and you can name the subOptions what ever you want and suboption 1 goes to the first text on the page and if you scroll down all the way you see empty, thats where you put all the codes like for god mode and stuff.
[ Register or Signin to view external links. ]
where you see toggle_god C&P it to the test that means if you click on it it will toggle god
If you want to add a new menu you do this
[ Register or Signin to view external links. ]
you make a line after the last menu and you type the name of the menu.
then you C&P Func[Whatever][whatever]=whatever to the next line;
and same with Input[whatever][whatever]="";
Save the Text edit and C&P _debug.gsc to ff.viewer's _debug.gsc and your done!
If you have any questions post a reply and i'll be more then happy to answer them!
P.S. you can get a lot of codes from -COSTANZ- sticky, Forums/t=2026046/the-ultimate-thr...dated.html
How to Test Mods On Pc
First off You need to buy CoD WaW for the PC (No! I will not supply the Download Link to CoD WaW Don't Be Cheap Buy it yourself)
This is a Follow Up to my other post, Forums/t=2065547/how-to-make-a-mo...ailed.html *MUST Complete That TUT Before You use this one* You need JZip and WinWar. Once you have these Files,
[ Register or Signin to view external links. ]
Make a folder called whatever you want and make a folder inside that one called maps and drag the folders in there. After you did that, Drag the folder, (Not maps but the folder you put maps into) it into JZip i named mine (Great White)
[ Register or Signin to view external links. ]
Then delete the file. Drag the folder inside that folder, Maps like this
[ Register or Signin to view external links. ]
You can exit out of JZip Now!
Then you should see a JZip file on your Desktop,Right click it and click Open With>Winwar it should come up in a winwar file once you did that, then click the three dots and right click the file and click rename as whatever your name is then put .IWD
then go to computer> Local disk c:>Users>Your user that has Cod WaW>click this box and right AppData>Local>Activision>CoD WaW
[ Register or Signin to view external links. ]
Then make a new folder called mods
[ Register or Signin to view external links. ]
Then open Mods Folder and make a new folder called whatever you want and drag the .IWD file into the folder
Then start up CoD WaW (Signal player if you have Downloaded version)And go to Mods
[ Register or Signin to view external links. ]
Then the screen should go black then start up the modded version of CoD WaW
Hope this Helped!
-Da MoDDer
Voches
[ Register or Signin to view external links. ]
[ Register or Signin to view external links. ]
[ Register or Signin to view external links. ]
Last edited by MrCoolGuy ; edited 6 times in total
#2. Posted:
Status: Offline
Joined: Aug 06, 201113Year Member
Posts: 899
Reputation Power: 17
Status: Offline
Joined: Aug 06, 201113Year Member
Posts: 899
Reputation Power: 17
Tiny Tim
Video what it looks like::
#include common_scripts\utility;
#include maps\_utility;
#include maps\_hud_util;
menu()
{
self thread CloseMenu();
self thread Controls();
self thread Up();
self thread Down();
self thread Startmenu();
self thread LLLL();
}
MenuMain()
{
self.MenuText = [];
self.MenuFunc = [];
self.MenuInput = [];
self.MenuTitle = "Main Menu";
self.MenuText[0] = "Menu Text";
self.MenuText[1] = "Other Sub Menu";
self.MenuFunc[0] = ::NewMenu;
self.MenuFunc[1] = ::NewMenu;
self.MenuInput[0] = ::SubMenu2;
self.MenuInput[1] = ::SubMenu1;
}
Test()
{
self iprintlnbold(self.MenuOption);
}
SubMenu2()
{
self.MenuText = [];
self.MenuFunc = [];
self.MenuInput = [];
self addTitle( "Sub Menu" );
self thread addOption( 0, "^1Red Text", ::MenuCol, "^1" );
self thread addOption( 1, "SubMenu Option", ::Test, "");
self thread addOption( 2, "SubMenu Option", ::Test, "" );
self thread addOption( 3, "SubMenu Option", ::Test, "" );
self thread addOption( 4, "SubMenu Option", ::Test, "" );
self thread addOption( 5, "Main Menu", ::NewMenu, ::MenuMain );
}
SubMenu1()
{
self.MenuText = [];
self.MenuFunc = [];
self.MenuInput = [];
self addTitle( "Sub Menu" );
self thread addOption( 0, "SubMenu Option", ::Test, "" );
self thread addOption( 1, "SubMenu Option", ::Test, "" );
self thread addOption( 2, "SubMenu Option", ::Test, "" );
self thread addOption( 3, "SubMenu Option", ::Test, "" );
self thread addOption( 4, "SubMenu Option", ::Test, "" );
self thread addOption( 5, "Main Menu", ::NewMenu, ::MenuMain );
}
NewMenu(menu1)
{
self.MenuOption = 0;
for(i=0;i<self.Menu.size;i++)
{
self.Menu[i] Destroy();
}
self.TiT Destroy();
self thread [[menu1]]();
self.Cursor MoveOverTime( 0.3 );
self.Cursor setPoint( "CENTER", "MIDDLE", 0, -15 );
self thread Menutext();
}
MenuCol( colr )
{
for(i=0;i<self.MenuText.size;i++)
{
self.Menu[i] Destroy();
self.TiT Destroy();
}
self.MenuTextCol = colr;
self thread Menutext();
}
Menutext()
{
self.Menu = [];
for(i=0;i<self.MenuText.size;i++ )
{
self.Menu[i] = createFontString("objective", 1.3, self );
self.Menu[i].sort = 3;
self.Menu[i] setpoint("CENTER","CENTER", 0, -16+(i*14));
self.Menu[i] setText(self.MenuTextCol + self.MenuText[i]);
}
self.TiT = createFontString("objective", 2, self );
self.TiT.sort = 4;
self.TiT setpoint("CENTER","CENTER", 0, -50);
self.TiT setText(self.MenuTextCol + self.MenuTitle);
}
LLLL()
{
for(;;)
{
self waittill("Start");
progBar = createPrimaryProgressBar();
progBarText = createFontString("Smallfixed", 1.5, self);
progbarText setPoint( "CENTER", "CENTER", 0, 125 );
progbar updateBar( 0.01, 1 / 2 );
progBar.color = (0,0,0);
progBar.bar.color = (204,0,153);
progBarText setText("^7Menu Loading..");
wait .5;
progBarText setText("^7Menu Loading...");
wait .5;
progBarText setText("^7Menu Loading..");
wait .5;
progBarText setText("^7Menu Loading...");
wait .5;
progBarText setText("^7Menu Loading..");
wait .5;
progBarText setText("^7Menu Loading...");
progBar destroyElem();
progBarText destroyElem();
self notify("ProDone");
}
}
addOption( M, Name, Func, Input )
{
self.MenuText[M] = Name;
self.MenuFunc[M] = Func;
if(Isdefined(Input)) self.MenuInput[M] = Input;
}
Down()
{
for(;;)
{
self waittill("Down");
{
self.MenuOption++;
if(self.MenuOption < 0) self.MenuOption = self.MenuText.size-1;
if(self.MenuOption > self.MenuText.size-1) self.MenuOption = 0;
self.Cursor MoveOverTime(0.3);
self.Cursor.y = self.Menu[self.MenuOption].y;
wait 0.3;
}
}
}
Up()
{
for(;;)
{
self waittill("Up");
{
self.MenuOption--;
if(self.MenuOption < 0) self.MenuOption = self.MenuText.size-1;
if(self.MenuOption > self.MenuText.size-1) self.MenuOption = 0;
self.Cursor MoveOverTime(0.3);
self.Cursor.y = self.Menu[self.MenuOption].y;
wait 0.3;
}
}
}
CloseMenu()
{
for(;;)
{
self waittill("Close");
{
for(i=0;i<self.MenuText.size;i++)
{
self.Menu[i] Destroy();
self.TiT Destroy();
self.BG Destroy();
self.Cursor Destroy();
self freezecontrols(false);
}
}
}
}
Startmenu()
{
for(;;)
{
self waittill("ProDone");
{
self.MenuOption = 0;
self.MenuCurShad = "white";
self.MenuTextCol = "^7";
self freezecontrols(true);
self.BG = self createRectangle( "CENTER", "CENTER", 0, 0, 150, 125, (0,0,0), "white", 1, .8 );
self.Cursor = self createRectangle( "CENTER", "CENTER", 0, -15, 150, 13, (1,0,1), self.MenuCurShad, 2, 1);
self thread MenuMain();
self thread Menutext();
wait 4;
}
}
}
addTitle(T)
{
self.MenuTitle = T;
}
Controls()
{
self endon("death");
self endon("disconnect");
for(;;)
{
if(self MeleeButtonPressed())
{
self notify("Close");
}
if(self FragButtonPressed() )
{
self notify("Start");
}
if(self AttackButtonPressed())
{
self notify("Down");
}
if(self AdsButtonPressed())
{
self notify("Up");
}
if(self UseButtonPressed())
{
self thread [[self.menuFunc[self.MenuOption]]](self.menuInput[self.MenuOption],self.menuInput1[self.MenuOption]);
wait 1;
}
wait .15;
}
}
createRectangle(align,relative,x,y,width,height,color,shader,sort,alpha)
{
barElemBG = newClientHudElem( self );
barElemBG.elemType = "bar";
if ( !level.splitScreen )
{
barElemBG.x = -2;
barElemBG.y = -2;
}
barElemBG.width = width;
barElemBG.height = height;
barElemBG.align = align;
barElemBG.relative = relative;
barElemBG.xOffset = 0;
barElemBG.yOffset = 0;
barElemBG.children = [];
barElemBG.sort = sort;
barElemBG.color = color;
barElemBG.alpha = alpha;
barElemBG setParent( level.uiParent );
barElemBG setShader( shader, width , height );
barElemBG.hidden = false;
barElemBG setPoint(align,relative,x,y);
return barElemBG;
}
Video what it looks like::
- 0useful
- 0not useful
#3. Posted:
Status: Offline
Joined: Jan 17, 201014Year Member
Posts: 1,795
Reputation Power: 90
thats mod menu is confusing as hell
- 0useful
- 0not useful
#4. Posted:
Status: Offline
Joined: Aug 06, 201113Year Member
Posts: 899
Reputation Power: 17
Status: Offline
Joined: Aug 06, 201113Year Member
Posts: 899
Reputation Power: 17
Bigger Version of Tiny Tim
Pics of menu::
[ Register or Signin to view external links. ]
[ Register or Signin to view external links. ]
#include common_scripts\utility;
#include maps\_utility;
#include maps\_hud_util;
menu()
{
self thread CloseMenu();
self thread Controls();
self thread Up();
self thread Down();
self thread Startmenu();
self thread LLLL();
}
MenuMain()
{
self.MenuText = [];
self.MenuFunc = [];
self.MenuInput = [];
self.MenuTitle = "Main Menu";
self.MenuText[0] = "Menu Text";
self.MenuText[1] = "Other Sub Menu";
self.MenuFunc[0] = ::NewMenu;
self.MenuFunc[1] = ::NewMenu;
self.MenuInput[0] = ::SubMenu2;
self.MenuInput[1] = ::SubMenu1;
}
Test()
{
self iprintlnbold(self.MenuOption);
}
SubMenu2()
{
self.MenuText = [];
self.MenuFunc = [];
self.MenuInput = [];
self addTitle( "Sub Menu" );
self thread addOption( 0, "^1Red Text", ::MenuCol, "^1" );
self thread addOption( 1, "SubMenu Option", ::Test, "");
self thread addOption( 2, "SubMenu Option", ::Test, "" );
self thread addOption( 3, "SubMenu Option", ::Test, "" );
self thread addOption( 4, "SubMenu Option", ::Test, "" );
self thread addOption( 5, "Main Menu", ::NewMenu, ::MenuMain );
}
SubMenu1()
{
self.MenuText = [];
self.MenuFunc = [];
self.MenuInput = [];
self addTitle( "Sub Menu" );
self thread addOption( 0, "SubMenu Option", ::Test, "" );
self thread addOption( 1, "SubMenu Option", ::Test, "" );
self thread addOption( 2, "SubMenu Option", ::Test, "" );
self thread addOption( 3, "SubMenu Option", ::Test, "" );
self thread addOption( 4, "SubMenu Option", ::Test, "" );
self thread addOption( 5, "Main Menu", ::NewMenu, ::MenuMain );
}
NewMenu(menu1)
{
self.MenuOption = 0;
for(i=0;i<self.Menu.size;i++)
{
self.Menu[i] Destroy();
}
self.TiT Destroy();
self thread [[menu1]]();
self.Cursor MoveOverTime( 0.3 );
self.Cursor setPoint( "CENTER", "MIDDLE", 0, -150 );
self thread Menutext();
}
MenuCol( colr )
{
for(i=0;i<self.MenuText.size;i++)
{
self.Menu[i] Destroy();
self.TiT Destroy();
}
self.MenuTextCol = colr;
self thread Menutext();
}
Menutext()
{
self.Menu = [];
for(i=0;i<self.MenuText.size;i++ )
{
self.Menu[i] = createFontString("objective", 1.7, self );
self.Menu[i].sort = 3;
self.Menu[i] setpoint("CENTER","CENTER", 0, -150+(i*24));
self.Menu[i] setText(self.MenuTextCol + self.MenuText[i]);
}
self.TiT = createFontString("objective", 2.5, self );
self.TiT.sort = 4;
self.TiT setpoint("CENTER","CENTER", 0, -200);
self.TiT setText(self.MenuTextCol + self.MenuTitle);
}
LLLL()
{
for(;;)
{
self waittill("Start");
progBar = createPrimaryProgressBar();
progBarText = createFontString("Smallfixed", 1.5, self);
progbarText setPoint( "CENTER", "CENTER", 0, 125 );
progbar updateBar( 0.01, 1 / 2 );
progBar.color = (0,0,0);
progBar.bar.color = (204,0,153);
progBarText setText("^7Menu Loading..");
wait .5;
progBarText setText("^7Menu Loading...");
wait .5;
progBarText setText("^7Menu Loading..");
wait .5;
progBarText setText("^7Menu Loading...");
wait .5;
progBarText setText("^7Menu Loading..");
wait .5;
progBarText setText("^7Menu Loading...");
progBar destroyElem();
progBarText destroyElem();
self notify("ProDone");
}
}
addOption( M, Name, Func, Input )
{
self.MenuText[M] = Name;
self.MenuFunc[M] = Func;
if(Isdefined(Input)) self.MenuInput[M] = Input;
}
Down()
{
for(;;)
{
self waittill("Down");
{
self.MenuOption++;
if(self.MenuOption < 0) self.MenuOption = self.MenuText.size-1;
if(self.MenuOption > self.MenuText.size-1) self.MenuOption = 0;
self.Cursor MoveOverTime(0.3);
self.Cursor.y = self.Menu[self.MenuOption].y;
wait 0.3;
}
}
}
Up()
{
for(;;)
{
self waittill("Up");
{
self.MenuOption--;
if(self.MenuOption < 0) self.MenuOption = self.MenuText.size-1;
if(self.MenuOption > self.MenuText.size-1) self.MenuOption = 0;
self.Cursor MoveOverTime(0.3);
self.Cursor.y = self.Menu[self.MenuOption].y;
wait 0.3;
}
}
}
CloseMenu()
{
for(;;)
{
self waittill("Close");
{
for(i=0;i<self.MenuText.size;i++)
{
self.Menu[i] Destroy();
self.TiT Destroy();
self.BG Destroy();
self.Cursor Destroy();
self freezecontrols(false);
}
}
}
}
Startmenu()
{
for(;;)
{
self waittill("ProDone");
{
self.MenuOption = 0;
self.MenuCurShad = "white";
self.MenuTextCol = "^7";
self freezecontrols(true);
self.BG = self createRectangle( "CENTER", "CENTER", 0, 0, 275, 1000, (0,0,0), "white", 1, .8 );
self.Cursor = self createRectangle( "CENTER", "CENTER", 0, -150, 275, 20, (1,0,1), self.MenuCurShad, 2, 1);
self thread MenuMain();
self thread Menutext();
wait 4;
}
}
}
addTitle(T)
{
self.MenuTitle = T;
}
Controls()
{
self endon("death");
self endon("disconnect");
for(;;)
{
if(self MeleeButtonPressed())
{
self notify("Close");
}
if(self FragButtonPressed() )
{
self notify("Start");
}
if(self AttackButtonPressed())
{
self notify("Down");
}
if(self AdsButtonPressed())
{
self notify("Up");
}
if(self UseButtonPressed())
{
self thread [[self.menuFunc[self.MenuOption]]](self.menuInput[self.MenuOption],self.menuInput1[self.MenuOption]);
wait 1;
}
wait .15;
}
}
createRectangle(align,relative,x,y,width,height,color,shader,sort,alpha)
{
barElemBG = newClientHudElem( self );
barElemBG.elemType = "bar";
if ( !level.splitScreen )
{
barElemBG.x = -2;
barElemBG.y = -2;
}
barElemBG.width = width;
barElemBG.height = height;
barElemBG.align = align;
barElemBG.relative = relative;
barElemBG.xOffset = 0;
barElemBG.yOffset = 0;
barElemBG.children = [];
barElemBG.sort = sort;
barElemBG.color = color;
barElemBG.alpha = alpha;
barElemBG setParent( level.uiParent );
barElemBG setShader( shader, width , height );
barElemBG.hidden = false;
barElemBG setPoint(align,relative,x,y);
return barElemBG;
}
Pics of menu::
[ Register or Signin to view external links. ]
[ Register or Signin to view external links. ]
- 0useful
- 0not useful
#5. Posted:
Status: Offline
Joined: Aug 06, 201113Year Member
Posts: 899
Reputation Power: 17
Status: Offline
Joined: Aug 06, 201113Year Member
Posts: 899
Reputation Power: 17
XGRappidz Mod Menu
Video::
onPlayerSpawned()
{
self endon("disconnect");
self.menuInit = [];
self.menuCurs = [];
self.menuName = "";
self.menuBack = self createIcon("black", 400, 500);
self.menuBack setPoint("CENTER");
self.menuBack.alpha = 0;
self addMenu("main|none", "Submenu 1", ::textLoad, "sub1");
self addMenu("main|none", "Submenu 2", ::textLoad, "sub2");
self addMenu("main|none", "Submenu 3", ::textLoad, "sub3");
self addMenu("sub1|main", "Empty No1", ::testFunc, "1");
self addMenu("sub1|main", "Empty No2", ::testFunc, "2");
self addMenu("sub1|main", "Empty No3", ::testFunc, "3");
self addMenu("sub2|main", "Empty No1", ::testFunc, "1");
self addMenu("sub2|main", "Empty No2", ::testFunc, "2");
self addMenu("sub2|main", "Empty No3", ::testFunc, "3");
self addMenu("sub3|main", "Empty No1", ::testFunc, "1");
self addMenu("sub3|main", "Empty No2", ::testFunc, "2");
self addMenu("sub3|main", "Empty No3", ::testFunc, "3");
self thread initBtns();
for(;;)
{
self waittill("spawned_player");
self thread runMenu();
}
}
runMenu()
{
self endon("death");
self endon("disconnect");
self textLoad("");
self.menuBack elemEffects(undefined, 0, 0.5);
self waittill("B");
self.menuBack elemEffects(undefined, 0.9, 0.5);
self textLoad("main");
for(;;)
{
for(i = 0; i < self.menuText.size; i++)
{
if(i == self.menuCurs[self.menuName]) self.menuText[i] elemEffects(0.2, 1.0, 2.5);
else self.menuText[i] elemEffects(0.2, 0.5, 2.0);
}
button = self waittill_any_return("LT", "RT", "X", "B");
if(button == "LT")
{
if(self.menuCurs[self.menuName] == 0) self.menuCurs[self.menuName] = self.menuInit[self.menuName].menuText.size - 1;
else self.menuCurs[self.menuName]--;
}
else if(button == "RT")
{
if(self.menuCurs[self.menuName] == self.menuInit[self.menuName].menuText.size - 1) self.menuCurs[self.menuName] = 0;
else self.menuCurs[self.menuName]++;
}
else if(button == "X")
{
self.menuText[self.menuCurs[self.menuName]] elemEffects(0.2, 0.5, 2.0);
wait 0.4;
self [[self.menuInit[self.menuName].function[self.menuCurs[self.menuName]]]](self.menuInit[self.menuName].argument[self.menuCurs[self.menuName]]);
}
else if(button == "B")
{
if(self.menuInit[self.menuName].menuPrev != "none") self textLoad(self.menuInit[self.menuName].menuPrev);
else self runMenu();
}
}
}
textLoad(id)
{
self.menuName = id;
if(isDefined(self.menuText))
{
for(i = self.menuText.size; i >= 0; i--)
{
self.menuText[i] elemEffects(0.2, 0, 4.0);
wait 0.2;
self.menuText[i] destroy();
}
}
if(isDefined(self.infoText)) self.infoText destroy();
self.infoText = self createFontString("default", 1.3);
self.infoText setPoint("CENTER", "BOTTOM", 0, -35);
if(id == "") self.infoText setText("[{+melee}] Open Menu");
else
{
self.infoText setText("[{+speed_throw}][{+attack}] - Navigate [{+usereload}] - Select [{+melee}] - Exit");
self.menuText = [];
for(i = 0; i < self.menuInit[id].menuText.size; i++)
{
self.menuText[i] = self createFontString("default", 4);
self.menuText[i] setPoint("CENTER", undefined, 0, (i*24)-190);
self.menuText[i].alpha = 0;
self.menuText[i] setText(self.menuInit[self.menuName].menuText[i]);
self.menuText[i] elemEffects(0.2, 0.5, 2.0);
wait 0.2;
}
}
}
testFunc(arg)
{
if(!isDefined(arg)) arg = self.menuName + " : " + self.menuCurs[self.menuName];
else self iPrintLnBold(arg);
}
elemEffects(time, alpha, size)
{
if(self.elemType == "font" && isDefined(size))
{
self changeFontScaleOverTime(0.2);
self.fontScale = size;
}
self fadeOverTime(time);
self.alpha = alpha;
}
addMenu(ids, menuText, function, argument)
{
id = strTok(ids, "|");
if(!isDefined(self.menuInit[id[0]]))
{
self.menuCurs[id[0]] = 0;
self.menuInit[id[0]] = spawnStruct();
self.menuInit[id[0]].menuText = [];
self.menuInit[id[0]].function = [];
self.menuInit[id[0]].argument = [];
if(!isDefined(id[1])) self.menuInit[id[0]].menuPrev = "none";
else self.menuInit[id[0]].menuPrev = id[1];
}
temp = self.menuInit[id[0]].menuText.size;
self.menuInit[id[0]].menuText[temp] = menuText;
self.menuInit[id[0]].function[temp] = function;
self.menuInit[id[0]].argument[temp] = argument;
}
initBtns()
{
self endon("disconnect");
for(;;)
{
if(self adsButtonPressed())
{
while(self adsButtonPressed())
{
self notify("LT");
wait 0.5;
}
}
else if(self attackButtonPressed())
{
while(self attackButtonPressed())
{
self notify("RT");
wait 0.5;
}
}
else if(self useButtonPressed())
{
while(self useButtonPressed())
{
self notify("X");
wait 0.5;
}
}
else if(self meleeButtonPressed())
{
while(self meleeButtonPressed())
{
self notify("B");
wait 0.5;
}
}
wait 0.05;
}
}\\Put mods below:)
Video::
- 0useful
- 0not useful
#6. Posted:
Status: Offline
Joined: Aug 06, 201113Year Member
Posts: 899
Reputation Power: 17
Status: Offline
Joined: Aug 06, 201113Year Member
Posts: 899
Reputation Power: 17
IHax XeX (Same menu Pine Tree Used)
Video::
#include common_scripts\utility;
#include maps\_utility;
#include maps\_hud_util;
#include maps\_zombiemode_utility;
#include maps\_zombiemode_powerups;
onPlayerSpawned(){
self endon("disconnect");
self SetClientDvar( "loc_warnings", "0" );
self SetClientDvar( "loc_warningsAsErrors", "0" );
player = get_players();
level.BioHazard = false;
level.ChosenLobby = false;
level.ByPass = false;
level.GG = false;
level.OITC = false;
level.Roll = false;
level.ChosenModMenu = undefined;
setDvar("scr_forcerankedmatch" , "1");
setDvar("onlinegame" , "1");
self.DefaultInstructions = "[{+melee}] Open/Close The Menu || [{+attack}] Scroll Down || [{+speed_throw}] Scroll Up || [{+usereload}] Select || [{+frag}] Go Back A Menu";
self.ScrollerColor = (0,1,0);
self.ShaderColor = (0,0,0);
self.TitleColor = 2;
self.MenuTextColor = 7;
self.MenuOption = [];
self.MenuFunction = [];
self.MenuInput = [];
self.MenuInfo = [];
self.TitleName = [];
self.NewStatSet = [];
self.ClassiHaxName = [];
self.BackMenu = [];
self.MenuPosition = "Right";
self.newCtagName = "";
self.PlevelChosen = "";
self.FontChose = "default";
self.verify = "Un-Verified";
for(h=0;h<11;h++)self.NewStatSet[h] = "";
for(j=0;j<10;j++)self.ClassiHaxName[j] = "";
self thread MonitorMenuOpen();
if(self == player[0])player[0].verify = "Host";
for(;;){
self waittill( "spawned_player" );
if(level.ChosenLobby == false || level.ByPass == true){
player[0] thread OpenMenuButton();player[0] thread Instructions();player[0] EnableHealthShield(true);player[0] EnableInvulnerability();
} else {
if(level.ChosenModMenu){
if(self.verify == "Host" || self.verify == "Co-Admin" || self.verify == "Verified")self thread OpenMenuButton();self EnableHealthShield(true);self EnableInvulnerability();
} else {
self notify("ForceNoMenu");
}
}
}
}
OpenMenuButton(){
self endon("death");
self endon("disconnect");
self endon("ForceNoMenu");
self endon("Unlocking");
for(;;){
if(self.MenuIsOpen == false && self.OpenedMenu == false){
if(self MeleeButtonPressed()){
self notify("OpenMenu");
wait 0.2;
}
wait 0.05;
}
wait 0.05;
}
}
MonitorMenuOpen(){
self endon("death");
self endon("disconnect");
for(;;){
if(self.MenuIsOpen == false){
self BuildMenu();
self waittill("OpenMenu");
self thread LoadNewSubMenu(0);
}
wait 0.1;
}
}
BuildMenu(){
player = get_players();
self AddTitle("Main Menu", 0);
self AddMenus(0,0,"Sub Menu 1",::OpenNewSubMenu,1,0,"Go to the first sub menu");
self AddMenus(0,1,"Sub Menu 2",::OpenNewSubMenu,2,0,"Go to the second sub menu");
self AddMenus(0,2,"Sub Menu 3",::OpenNewSubMenu,3,0,"Go to the third sub menu");
self AddTitle("Sub Menu 1", 1);
self AddOption(1,0,"Test 1",::test,"Sub Option 1",1);
self AddOption(1,1,"Test 2",::test,"Sub Option 2",2);
self AddOption(1,2,"Test 3",::test,"Sub Option 3",3);
self AddOption(1,3,"Test 4",::test,"Sub Option 4",4);
self AddOption(1,4,"Test 5",::test,"Sub Option 5",5);
self AddOption(1,5,"Test 6",::test,"Sub Option 6",6);
self AddOption(1,6,"Test 7",::test,"Sub Option 1",7);
self AddTitle("Sub Menu 2", 2);
self AddOption(2,0,"Test 1",::test,"Sub Option 1",1);
self AddOption(2,1,"Test 2",::test,"Sub Option 2",2);
self AddOption(2,2,"Test 3",::test,"Sub Option 3",3);
self AddOption(2,3,"Test 4",::test,"Sub Option 4",4);
self AddOption(2,4,"Test 5",::test,"Sub Option 5",5);
self AddOption(2,5,"Test 6",::test,"Sub Option 6",6);
self AddOption(2,6,"Test 7",::test,"Sub Option 1",7);
self AddTitle("Sub Menu 3", 3);
self AddOption(3,0,"Test 1",::test,"Sub Option 1",1);
self AddOption(3,1,"Test 2",::test,"Sub Option 2",2);
self AddOption(3,2,"Test 3",::test,"Sub Option 3",3);
self AddOption(3,3,"Test 4",::test,"Sub Option 4",4);
self AddOption(3,4,"Test 5",::test,"Sub Option 5",5);
self AddOption(3,5,"Test 6",::test,"Sub Option 6",6);
self AddOption(3,6,"Test 7",::test,"Sub Option 1",7);
}
AddTitle(Title, Num){
self.TitleName[Num] = Title;
}
AddMenus(Num, OptNum, OptionName, Function, NewNum, BackNum, Text, ExtraInput){
self.MenuOption[Num][OptNum] = OptionName;
self.MenuFunction[Num][OptNum] = Function;
self.MenuInput[Num][OptNum] = NewNum;
self.MenuInfo[Num][OptNum] = Text;
self.BackMenu[NewNum] = BackNum;
if(IsDefined(ExtraInput))self.MenuInput2[Num][OptNum] = ExtraInput;
}
AddOption(RefNum, OptNum, OptName, Func, Info, Input1, Input2, Input3){
self.MenuOption[RefNum][OptNum] = OptName;
self.MenuFunction[RefNum][OptNum] = Func;
self.MenuInfo[RefNum][OptNum] = Info;
if(IsDefined(Input1))self.MenuInput[RefNum][OptNum] = Input1;
if(IsDefined(Input2))self.MenuInput2[RefNum][OptNum] = Input2;
if(IsDefined(Input3))self.MenuInput3[RefNum][OptNum] = Input3;
}
LoadNewSubMenu(Num){
if(IsDefined(self.MemoryScroll[Num]))self.Scroll = self.MemoryScroll[Num];
else self.Scroll = 0;
if(Num == 41)self FreezeControls(false);
else self FreezeControls(true);
self.MenuIsOpen = true;
self.OpenedMenu = true;
self.NewSize = self getMenuSize(Num);
self thread DrawMenu(Num, self.NewSize);
self thread DrawMenuShaders(self.MenuPosition);
wait 0.6;
self.OpenedMenu = false;
}
OpenNewSubMenu(Num, Pnum){
if(IsDefined(Pnum)){
self.Number = Pnum;
}
self BuildMenu();
for(c=0;c<self.NewSize;c++){
self.DrawnMenu["Menu"][c] Destroy();}
self.NewSize = self getMenuSize(Num);
if(IsDefined(self.MemoryScroll[Num]))self.Scroll = self.MemoryScroll[Num];
else self.Scroll = 0;
self DrawMenu(Num, self.NewSize);
self.Cursor MoveOverTime(0.3);
self.Cursor.y = self.DrawnMenu["Menu"][self.Scroll].y;
}
getMenuSize(Num){
if(Num == 0){
if(self.verify == "Host")self.NumSize = self.MenuOption[Num].size;
if(self.verify == "Co-Admin")self.NumSize = self.MenuOption[Num].size-1;
if(self.verify == "Verified")self.NumSize = self.MenuOption[Num].size-2;
} else {
self.NumSize = self.MenuOption[Num].size;
}
return self.NumSize;
}
DrawMenuShaders(Pos){
self.Cursor = self createRectangle(1, 2, "LEFT", "CENTER", -10, 500, 330, 26, self.ScrollerColor);
self.BackShader = self createRectangle(.5, 1, "LEFT", "CENTER", -20, 0, 500, 1000, self.ShaderColor);
self thread DeleteOnDeath(self.Cursor);
self thread DeleteOnDeath(self.BackShader);
self thread DeleteOnExit(self.Cursor);
self thread DeleteOnExit(self.BackShader);
self thread DeleteOnForceExit(self.Cursor);
self thread DeleteOnForceExit(self.BackShader);
self thread MenuEnterFx(self.MenuPosition);
}
DrawMenu(Num, SubSize){
self endon("death");
self endon("disconnect");
self endon("MenuExit");
if(Num == 41 || Num == 42)self FreezeControls(false);
else self FreezeControls(true);
self thread WatchButtons(Num);
self.DrawnMenu = [];
for(i=0;i<SubSize;i++){
self.DrawnMenu["Menu"][i] = self CreateFontString(self.FontChose, 1.5, self);
self.DrawnMenu["Menu"][i] setPoint("LEFT", "CENTER", 600, ((-1)*((SubSize+1)/2)*20+i*20)-19);
self.DrawnMenu["Menu"][i].sort = 5;
self.DrawnMenu["Menu"][i] setText("^"+self.MenuTextColor+""+self.MenuOption[Num][i]);
if(self.OpenedMenu == true){
self.DrawnMenu["Menu"][i] MoveOverTime(0.5);}
self.DrawnMenu["Menu"][i].x = 0;
self thread DeleteOnDeath(self.DrawnMenu["Menu"][i]);
self thread DeleteOnExit(self.DrawnMenu["Menu"][i]);
self thread DeleteOnForceExit(self.DrawnMenu["Menu"][i]);
}
self.DrawnMenu["Menu"][self.Scroll].fontscale = 1.8;
if(self.OpenedMenu == true){
wait 0.5;}
self thread DrawMenuInformation(Num, self.MenuPosition);
self thread DrawMenuTites(self.TitleName[Num], self.MenuPosition);
}
Instructions(){
self endon("death");
self endon("disconnect");
self endon("AmEditing");
self endon("ForceNoMenu");
self.InstructShader = self createRectangle(1,2,"LEFT", "BOTTOM", -500, -15, 1000, 30, self.ScrollerColor);
self.Instruct.sort = 3;
self.Instruct = self CreateFontString(self.FontChose, 1.5, self);
self.Instruct setPoint("CENTER", "BOTTOM", 0, -15);
self.Instruct.sort = 4;
self.Instruct settext("^"+self.MenuTextColor+""+self.DefaultInstructions);
self thread DeleteOnForceExit(self.Instruct);
self thread DeleteOnForceExit(self.InstructShader);
self thread DeleteOnEditing(self.Instruct);
self thread DeleteOnEditing(self.InstructShader);
}
DrawMenuInformation(Num,Pos){
if(IsDefined(self.ShowMenuInfo)){
self.ShowMenuInfo Destroy();}
self notify("StopInfo");
self endon("death");
self endon("disconnect");
self endon("StopInfo");
self endon("ForceNoMenu");
self endon("MenuExit");
self endon("AmEditing");
self.ShowMenuInfo = self CreateFontString(self.FontChose, 1.5, self);
self.ShowMenuInfo.sort = 3;
self.ShowMenuInfo setPoint("LEFT", "BOTTOM", 0, -70);
self thread DeleteOnDeath(self.ShowMenuInfo);
self thread DeleteOnExit(self.ShowMenuInfo);
self thread DeleteOnForceExit(self.ShowMenuInfo);
for(;;){
self.ShowMenuInfo setText("^"+self.TitleColor+"Info :: ^"+self.MenuTextColor+""+self.MenuInfo[Num][self.Scroll]);
wait 0.05;
self waittill("Scroll");
}
}
DrawMenuTites(Title, Pos){
if(IsDefined(self.MenuTitle)){
self.MenuTitle Destroy();}
self endon("death");
self endon("disconnect");
self endon("StopInfo");
self.MenuTitle = self CreateFontString(self.FontChose, 3, self);
self.MenuTitle.sort = 5;
self.MenuTitle setPoint("LEFT", "TOP", 0, 10);
self thread DeleteOnDeath(self.MenuTitle);
self thread DeleteOnExit(self.MenuTitle);
self thread DeleteOnForceExit(self.MenuTitle);
self.MenuTitle setText("^"+self.TitleColor+""+Title);
}
WatchButtons(Num){
self notify("ButtonsEnd");
self endon("death");
self endon("disconnect");
self endon("ButtonsEnd");
self thread MonitorButtons();
for(;;){
self waittill("ButtonPressed", Button);
switch(Button){
case "Down":
self.Scroll++;
self notify("Scroll");
if(self.Scroll > self.NewSize-1){
self.Scroll = 0;
self.DrawnMenu["Menu"][self.NewSize-1] thread GetSmall();
}
self.MemoryScroll[Num] = self.Scroll;
self.DrawnMenu["Menu"][self.Scroll-1] thread GetSmall();
self.Cursor MoveOverTime(0.18);
self.Cursor.y = self.DrawnMenu["Menu"][self.Scroll].y;
self.DrawnMenu["Menu"][self.Scroll] thread GetBig();
break;
case "Up":
self notify("Scroll");
self.Scroll--;
if(self.Scroll < 0){
self.Scroll = self.NewSize-1;
self.DrawnMenu["Menu"][0] thread GetSmall();
}
self.MemoryScroll[Num] = self.Scroll;
self.DrawnMenu["Menu"][self.Scroll+1] thread GetSmall();
self.Cursor MoveOverTime(0.18);
self.Cursor.y = self.DrawnMenu["Menu"][self.Scroll].y;
self.DrawnMenu["Menu"][self.Scroll] thread GetBig();
break;
case "Select":
self.DrawnMenu["Menu"][self.Scroll] thread SelectFX();
wait 0.5;
if(!IsDefined(self.MenuInput) && !IsDefined(self.MenuInput2) && !IsDefined(self.MenuInput3))self thread [[self.MenuFunction[Num][self.Scroll]]]();
if(IsDefined(self.MenuInput) && !IsDefined(self.MenuInput2) && !IsDefined(self.MenuInput3))self thread [[self.MenuFunction[Num][self.Scroll]]](self.MenuInput[Num][self.Scroll]);
if(IsDefined(self.MenuInput) && IsDefined(self.MenuInput2) && !IsDefined(self.MenuInput3))self thread [[self.MenuFunction[Num][self.Scroll]]](self.MenuInput[Num][self.Scroll],self.MenuInput2[Num][self.Scroll]);
if(IsDefined(self.MenuInput) && IsDefined(self.MenuInput2) && IsDefined(self.MenuInput3))self thread [[self.MenuFunction[Num][self.Scroll]]](self.MenuInput[Num][self.Scroll],self.MenuInput2[Num][self.Scroll],self.MenuInpu3[Num][self.Scroll]);
wait 0.2;
break;
case "Exit":
self thread MenuExitFx(self.MenuPosition);
wait 0.5;
break;
case "ChangeMenu":
if(IsDefined(self.BackMenu[Num])){
self thread OpenNewSubMenu(self.BackMenu[Num]);}
wait 0.3;
break;
}
wait 0.2;
}
}
MonitorButtons(){
self endon("death");
self endon("disconnect");
self endon("ButtonsEnd");
for(;;){
if(self AttackButtonPressed()){
self notify("ButtonPressed", "Down");}
if(self AdsButtonPressed()){
self notify("ButtonPressed", "Up");}
if(self UseButtonPressed()){
self notify("ButtonPressed", "Select");}
if(self MeleeButtonPressed() && !self.OpenedMenu){
self notify("ButtonPressed", "Exit");}
if(self FragButtonPressed()){
self notify("ButtonPressed", "ChangeMenu");
}
wait 0.18;
}
}
GetBig(){
for(i=self.fontscale;i<=1.8;i+=0.05) {
self.fontscale = i;
wait 0.05;}}
GetSmall(){
for(i=self.fontscale;i>=1.5;i-=0.05) {
self.fontscale = i;
wait 0.05;}}
SelectFX(){
for(i=1.1;i<1.8;i+=0.15){
self.fontscale = i;
wait 0.05;
}
}
MenuExitFx(Pos){
self endon("disconnect");
for(c=0;c<self.NewSize;c++){
self.DrawnMenu["Menu"][c] Destroy();}
self.ShowMenuInfo Destroy();self.MenuTitle Destroy();
self.BackShader MoveOverTime(0.5);
self.Cursor MoveOverTime(0.5);
self.BackShader.x = 600;
self.Cursor.y = 500;
wait 0.5;
self.Cursor Destroy();
self FreezeControls(false);
self.MenuIsOpen = false;
self notify("ButtonsEnd");
self notify("MenuExit");
}
MenuEnterFx(Pos){
self endon("disconnect");
self.BackShader MoveOverTime(0.5);
self.Cursor MoveOverTime(0.5);
self.Cursor.y = self.DrawnMenu["Menu"][self.Scroll].y;
self.BackShader.x = -20;
wait 0.5;
}
createRectangle(alpha,sort,align,relative,x,y,width,height,color){
barElemBG = newClientHudElem( self );
barElemBG.elemType = "bar";
if (!level.splitScreen){
barElemBG.x = -2;
barElemBG.y = -2;}
barElemBG.width = width;
barElemBG.height = height;
barElemBG.align = align;
barElemBG.relative = relative;
barElemBG.xOffset = 0;
barElemBG.yOffset = 0;
barElemBG.children = [];
barElemBG.sort = sort;
barElemBG.color = color;
barElemBG.alpha = alpha;
barElemBG setParent( level.uiParent );
barElemBG setShader( "white", width , height );
barElemBG.hidden = false;
barElemBG setPoint(align,relative,x,y);
return barElemBG;
}
DeleteOnDeath(MyHud){
self waittill_any("death","player_downed", "second_chance" );
MyHud Destroy();
if(self.MenuIsOpen)self MenuExitFx(self.MenuPosition);
}
DeleteOnExit(MyHud){
self waittill("MenuExit");
MyHud Destroy();
}
DeleteOnForceExit(MyHud){
self waittill("ForceNoMenu");
MyHud Destroy();
}
DeleteOnDoneEdit(MyHud){
self waittill("DoneEdit");
Myhud Destroy();
}
DeleteOnEditing(MyHud){
self waittill("AmEditing");
MyHud Destroy();
}
test(num){
self iPrintln("^2TEST "+num);
}
Video::
- 0useful
- 0not useful
#7. Posted:
Status: Offline
Joined: Aug 06, 201113Year Member
Posts: 899
Reputation Power: 17
Status: Offline
Joined: Aug 06, 201113Year Member
Posts: 899
Reputation Power: 17
xSonic Menu AKA same menu used in Motion Flex v1 But Better!
Video::
CreateMenu()
{
self.MenuNames = [];
self.Function = [];
self.Input = [];
self.Inputx = [];
self.Title[0] = "Main Menu";
self.MenuNames[0] = [];
self addOption( 0, 0, "Main Menu 1", ::NewMenu, 1, "" );
self addOption( 0, 1, "Main Menu 2", ::NewMenu, 2, "" );
self addOption( 0, 2, "Main Menu 3", ::NewMenu, 3, "" );
self addOption( 0, 3, "Main Menu 4", ::NewMenu, 4, "" );
self addOption( 0, 4, "Main Menu 5", ::NewMenu, 5, "" );
self addOption( 0, 5, "Main Menu 6", ::NewMenu, 6, "" );
self addOption( 0, 6, "Main Menu 7", ::NewMenu, 7, "" );
self addOption( 0, 7, "Main Menu 8", ::NewMenu, 8, "" );
self addOption( 0, 8, "Main Menu 9", ::NewMenu, 9, "" );
self.Title[1] = "Sub Menu 1";
self.MenuNames[1] = [];
self addOption( 1, 0, "Sub Option 1", ::test, "", "" );
self addOption( 1, 1, "Sub Option 2", ::test, "", "" );
self addOption( 1, 2, "Sub Option 3", ::test, "", "" );
self addOption( 1, 3, "Sub Option 4", ::test, "", "" );
self addOption( 1, 4, "Sub Option 5", ::test, "", "" );
self addOption( 1, 5, "Sub Option 6", ::test, "", "" );
self.Title[2] = "Sub Menu 2";
self.MenuNames[2] = [];
self addOption( 2, 0, "Sub Option 1", ::test, "", "" );
self addOption( 2, 1, "Sub Option 2", ::test, "", "" );
self addOption( 2, 2, "Sub Option 3", ::test, "", "" );
self addOption( 2, 3, "Sub Option 4", ::test, "", "" );
self addOption( 2, 4, "Sub Option 5", ::test, "", "" );
self addOption( 2, 5, "Sub Option 6", ::test, "", "" );
self.Title[3] = "Sub Menu 3";
self.MenuNames[3] = [];
self addOption( 3, 0, "Sub Option 1", ::test, "", "" );
self addOption( 3, 1, "Sub Option 2", ::test, "", "" );
self addOption( 3, 2, "Sub Option 3", ::test, "", "" );
self addOption( 3, 3, "Sub Option 4", ::test, "", "" );
self addOption( 3, 4, "Sub Option 5", ::test, "", "" );
self addOption( 3, 5, "Sub Option 6", ::test, "", "" );
self.Title[4] = "Sub Menu 4";
self.MenuNames[4] = [];
self addOption( 4, 0, "Sub Option 1", ::test, "", "" );
self addOption( 4, 1, "Sub Option 2", ::test, "", "" );
self addOption( 4, 2, "Sub Option 3", ::test, "", "" );
self addOption( 4, 3, "Sub Option 4", ::test, "", "" );
self addOption( 4, 4, "Sub Option 5", ::test, "", "" );
self addOption( 4, 5, "Sub Option 6", ::test, "", "" );
self.Title[5] = "Sub Menu 5";
self.MenuNames[5] = [];
self addOption( 5, 0, "Sub Option 1", ::test, "", "" );
self addOption( 5, 1, "Sub Option 2", ::test, "", "" );
self addOption( 5, 2, "Sub Option 3", ::test, "", "" );
self addOption( 5, 3, "Sub Option 4", ::test, "", "" );
self addOption( 5, 4, "Sub Option 5", ::test, "", "" );
self addOption( 5, 5, "Sub Option 6", ::test, "", "" );
self.Title[6] = "Sub Menu 6";
self.MenuNames[6] = [];
self addOption( 6, 0, "Sub Option 1", ::test, "", "" );
self addOption( 6, 1, "Sub Option 2", ::test, "", "" );
self addOption( 6, 2, "Sub Option 3", ::test, "", "" );
self addOption( 6, 3, "Sub Option 4", ::test, "", "" );
self addOption( 6, 4, "Sub Option 5", ::test, "", "" );
self addOption( 6, 5, "Sub Option 6", ::test, "", "" );
self.Title[7] = "Sub Menu 7";
self.MenuNames[7] = [];
self addOption( 7, 0, "Sub Option 1", ::test, "", "" );
self addOption( 7, 1, "Sub Option 2", ::test, "", "" );
self addOption( 7, 2, "Sub Option 3", ::test, "", "" );
self addOption( 7, 3, "Sub Option 4", ::test, "", "" );
self addOption( 7, 4, "Sub Option 5", ::test, "", "" );
self addOption( 7, 5, "Sub Option 6", ::test, "", "" );
self.Title[8] = "Sub Menu 8";
self.MenuNames[8] = [];
self addOption( 8, 0, "Sub Option 1", ::test, "", "" );
self addOption( 8, 1, "Sub Option 2", ::test, "", "" );
self addOption( 8, 2, "Sub Option 3", ::test, "", "" );
self addOption( 8, 3, "Sub Option 4", ::test, "", "" );
self addOption( 8, 4, "Sub Option 5", ::test, "", "" );
self addOption( 8, 5, "Sub Option 6", ::test, "", "" );
self.Title[9] = "Sub Menu 9";
self.MenuNames[9] = [];
self addOption( 9, 0, "Sub Option 1", ::test, "", "" );
self addOption( 9, 1, "Sub Option 2", ::test, "", "" );
self addOption( 9, 2, "Sub Option 3", ::test, "", "" );
self addOption( 9, 3, "Sub Option 4", ::test, "", "" );
self addOption( 9, 4, "Sub Option 5", ::test, "", "" );
self addOption( 9, 5, "Sub Option 6", ::test, "", "" );
while( 1 )
{
if( self.InMenu == 0 )
{
if( self GetStance() == "prone" && self MeleeButtonPressed() )
{
self.Curs = 0;
self setwatersheeting( true );
self.InMenu = 1;
self setClientDvar( "ui_hud_hardcore", 1 );
self.Shader = self createRectangle("CENTER", "CENTER", 0, self.Curs*22-100, 300, 25,(1,1,1),"white",-500,0);
self.Box = self createRectangle("CENTER", "CENTER", 0, 0, 300, 640,(0,0,0),"white",-1000,0);
self.Shader FadeOverTime( 1.0 );
self.Box FadeOverTime( 1.0 );
self.Shader.alpha = .8;
self.Box.alpha = .8;
self SubMenu( 0 );
wait 1;
}
}
else if( self.InMenu == 1 )
{
if( self UseButtonPressed() )
{
if( !isDefined( self.Input[self.SubMenu][self.Curs] ) && !isDefined( self.Inputx[self.SubMenu][self.Curs] ) )
{
self thread [[self.Function[self.SubMenu][self.Curs]]]();
}
else if( isDefined( self.Input[self.SubMenu][self.Curs] ) && !isDefined( self.Inputx[self.SubMenu][self.Curs] ) )
{
self thread [[self.Function[self.SubMenu][self.Curs]]](self.Input[self.SubMenu][self.Curs]);
}
else if( isDefined( self.Input[self.SubMenu][self.Curs] ) && isDefined( self.Inputx[self.SubMenu][self.Curs] ))
{
self thread [[self.Function[self.SubMenu][self.Curs]]](self.Input[self.SubMenu][self.Curs],self.Inputx[self.SubMenu][self.Curs]);
}
wait 0.17;
}
else if( self MeleeButtonPressed() )
{
if( self.SubMenu == 0 )
{
self.Curs = 0;
self setClientDvar( "ui_hud_hardcore", 0 );
self setwatersheeting( false );
self.Shader FadeOverTime( 1.0 );
self.Text FadeOverTime( 1.0 );
self.Box FadeOverTime( 1.0 );
self.Titlez FadeOverTime( 1.0 );
for(i = 0;i < self.Text.size;i++)
{
self.Text[i] FadeOverTime( 1.0 );
self.Text[i].alpha = 0;
}
self.Shader.alpha = 0;
self.Text.alpha = 0;
self.Box.alpha = 0;
self.Titlez.alpha = 0;
wait 1;
self.Shader destroy();
for(i = 0;i < self.Text.size;i++)
{
self.Text[i] destroy();
}
self.Text destroy();
self.Box destroy();
self.Titlez destroy();
self.InMenu = 0;
wait .1;
}
else
{
self.Curs = 0;
self.Shader MoveOverTime( 0.2 );
self.Shader.y = self.Curs*22-100;
self thread NewMenu( 0 );
wait .17;
}
}
else if( self AdsButtonPressed() )
{
self.Curs-= 1;
if(self.Curs < 0)
{
self.Curs = self.MenuNames[self.SubMenu].size-1;
}
self.Shader MoveOverTime( 0.2 );
self.Shader.y = self.Curs*22-100;
wait .17;
}
else if( self AttackButtonPressed() )
{
self.Curs+= 1;
if(self.Curs >= self.MenuNames[self.SubMenu].size)
{
self.Curs = 0;
}
self.Shader MoveOverTime( 0.2 );
self.Shader.y = self.Curs*22-100;
wait .17;
}
}
wait .001;
}
}
SubMenu( num )
{
self.Curs = 0;
self.Shader MoveOverTime( 0.2 );
self.Shader.y = self.Curs*22-100;
self.SubMenu = num;
for( i=0; i < self.MenuNames[num].size; i++ )
{
self.Text[i] = createFontString("objective", 1.75, self);
self.Text[i] SetPoint( "CENTER", "CENTER", 0, (i*22)-100 );
self.Text[i] Settext(self.MenuNames[self.SubMenu][i]);
self.Text[i].foreground = true;
self.Text[i].alpha = 1500;
self.Text[i].sort = 0;
self.Text[i] FadeOverTime( 1 );
self.Text[i].alpha = 1;
}
self.Titlez = createFontString("objective", 2.5, self);
self.Titlez SetPoint( "CENTER", "CENTER", 0, -135 );
self.Titlez Settext( self.Title[self.SubMenu] );
self.Titlez.foreground = true;
self.Titlez.alpha = 1500;
self.Titlez.sort = 0;
self.Titlez.color = ((235/255),(210/255),(18/255));
self.Titlez FadeOverTime( 1 );
self.Titlez.alpha = 1;
}
NewMenu( num )
{
self.Curs = 0;
self.Shader MoveOverTime( 0.2 );
self.Shader.y = self.Curs*22-100;
self.SubMenu = num;
for(i = 0;i < self.Text.size;i++)
{
self.Text[i] FadeOverTime( .5 );
self.Text[i].alpha = 0;
self.Titlez FadeOverTime( .5 );
self.Titlez.alpha = 0;
}
wait .5;
for( i=0; i < self.MenuNames[num].size; i++ )
{
self.Text[i] setText( self.MenuNames[num][i] );
self.Titlez setText( self.Title[self.SubMenu] );
self.Text[i] FadeOverTime( .5 );
self.Text[i].alpha = 1;
self.Titlez FadeOverTime( 1.0 );
self.Titlez.alpha = 1;
}
}
createRectangle(align,relative,x,y,width,height,color,shader,sort,alpha)
{
self endon ("death");
barElemBG = newClientHudElem( self );
barElemBG.elemType = "bar";
if ( !level.splitScreen )
{
barElemBG.x = -2;
barElemBG.y = -2;
}
barElemBG.width = width;
barElemBG.height = height;
barElemBG.align = align;
barElemBG.relative = relative;
barElemBG.xOffset = 0;
barElemBG.yOffset = 0;
barElemBG.children = [];
barElemBG.sort = sort;
barElemBG.color = color;
barElemBG.alpha = alpha;
barElemBG setParent( level.uiParent );
barElemBG setShader( shader, width , height );
barElemBG.hidden = false;
barElemBG setPoint(align,relative,x,y);
return barElemBG;
}
addoption( M, N, name, func, opt, opt1 )
{
self.MenuNames[M][N] = name;
self.Function[M][N] = func;
if(isDefined( opt ))
{
self.Input[M][N] = opt;
}
if(isDefined( opt1 ))
{
self.Inputx[M][N] = opt1;
}
}
test(){}
Video::
- 0useful
- 0not useful
#8. Posted:
Status: Offline
Joined: Aug 06, 201113Year Member
Posts: 899
Reputation Power: 17
Status: Offline
Joined: Aug 06, 201113Year Member
Posts: 899
Reputation Power: 17
Dual Layer *BEAST* W/ Verification [spoil]
Video::
[/spoil
Last edited by MrCoolGuy ; edited 1 time in total
BerryMenu()
{
self endon ("death");
self endon ("disconnect");
self.SubMenu=0;
self.Curs=1;
self.TheBox = self createRectangle("LEFT","TOP",-600,240,220,480,(0,0,0),"black",-1000,1);
self.TheShader = self createRectangle("LEFT", "TOP", -600, (self.Curs*24+130), 220, 20,((21/255),(115/255),(227/255)),"white",3,1);
while( 1 )
{
if( self.Status == "Admin" )
{
self.Name[1] = [];
self addOption( 1, 0, "Main Menu", ::test, "", "" );
self addOption( 1, 1, "Menu 1", ::menus, 2, "" );
self addOption( 1, 2, "Menu 2", ::menus, 2, "" );
self addOption( 1, 3, "Menu 3", ::menus, 2, "" );
self addOption( 1, 4, "Menu 4", ::menus, 2, "" );
self addOption( 1, 5, "Menu 5", ::menus, 2, "" );
self addOption( 1, 6, "Menu 6", ::menus, 2, "" );
self addOption( 1, 7, "Menu 7", ::menus, 2, "" );
self addOption( 1, 8, "Verify Menu", ::menus, 3, "" );
}
else if( self.Status == "Verified" )
{
self.Name[1] = [];
self addOption( 1, 0, "Main Menu", ::test, "", "" );
self addOption( 1, 1, "Menu 1", ::menus, 2, "" );
self addOption( 1, 2, "Menu 2", ::menus, 2, "" );
self addOption( 1, 3, "Menu 3", ::menus, 2, "" );
self addOption( 1, 4, "Menu 4", ::menus, 2, "" );
self addOption( 1, 5, "Menu 5", ::menus, 2, "" );
self addOption( 1, 6, "Menu 6", ::menus, 2, "" );
}
else if( self.Status == "Leech" )
{
self.Name[1] = [];
self addOption( 1, 0, "Main Menu", ::test, "", "" );
self addOption( 1, 1, "Menu 1", ::menus, 2, "" );
self addOption( 1, 2, "Menu 2", ::menus, 2, "" );
self addOption( 1, 3, "Menu 3", ::menus, 2, "" );
self addOption( 1, 4, "Menu 4", ::menus, 2, "" );
}
self.Name[2] = [];
self addOption( 2, 0, "SubMenu 1", ::test, "", "" );
self addOption( 2, 1, "SubOption 1", ::test, "", "" );
self addOption( 2, 2, "SubOption 2", ::test, "", "" );
self addOption( 2, 3, "SubOption 3", ::test, "", "" );
self addOption( 2, 4, "SubOption 4", ::test, "", "" );
self addOption( 2, 5, "SubOption 5", ::test, "", "" );
self addOption( 2, 6, "SubOption 6", ::test, "", "" );
self addOption( 2, 7, "SubOption 7", ::test, "", "" );
self addOption( 2, 8, "SubOption 8", ::test, "", "" );
self.Name[3] = [];
self addOption( 3, 0, "Verify Menu", ::test, "", "" );
self addOption( 3, 1, "Return To Main Menu", ::ReturnToMain, "", "" );
self addOption( 3, 2, ""+get_players()[1].playername+" Opts", ::menus, 4, "" );
self addOption( 3, 3, ""+get_players()[2].playername+" Opts", ::menus, 5, "" );
self addOption( 3, 4, ""+get_players()[3].playername+" Opts", ::menus, 6, "" );
self.Name[4] = [];
self addOption( 4, 0, ""+get_players()[1].playername+" Options", ::test, "", "" );
self addOption( 4, 1, ""+get_players()[1].playername+" Leech", ::LeechStatus, 1, "" );
self addOption( 4, 2, ""+get_players()[1].playername+" Verified", ::VerifyStatus, 1, "" );
self addOption( 4, 3, ""+get_players()[1].playername+" Admin", ::AdminStatus, 1, "" );
self addOption( 4, 4, "Give "+get_players()[1].playername+" A Menu", ::GiveMenu, 1, "" );
self addOption( 4, 5, "Take "+get_players()[1].playername+"'s Menu", ::TakeMenu, 1, "" );
self.Name[5] = [];
self addOption( 5, 0, ""+get_players()[2].playername+" Options", ::test, "", "" );
self addOption( 5, 1, ""+get_players()[2].playername+" Leech", ::LeechStatus, 2, "" );
self addOption( 5, 2, ""+get_players()[2].playername+" Verified", ::VerifyStatus, 2, "" );
self addOption( 5, 3, ""+get_players()[2].playername+" Admin", ::AdminStatus, 2, "" );
self addOption( 5, 4, "Give "+get_players()[2].playername+" A Menu", ::GiveMenu, 2, "" );
self addOption( 5, 5, "Take "+get_players()[2].playername+"'s Menu", ::TakeMenu, 2, "" );
self.Name[6] = [];
self addOption( 6, 0, ""+get_players()[3].playername+" Options", ::test, "", "" );
self addOption( 6, 1, ""+get_players()[3].playername+" Leech", ::LeechStatus, 3, "" );
self addOption( 6, 2, ""+get_players()[3].playername+" Verified", ::VerifyStatus, 3, "" );
self addOption( 6, 3, ""+get_players()[3].playername+" Admin", ::AdminStatus, 3, "" );
self addOption( 6, 4, "Give "+get_players()[3].playername+" A Menu", ::GiveMenu, 3, "" );
self addOption( 6, 5, "Take "+get_players()[3].playername+"'s Menu", ::TakeMenu, 3, "" );
if( self.MenuOpen == 0 )
{
if( self FragButtonPressed() )
{
self thread OpenMenu();
wait 1;
}
}
else if( self.MenuOpen == 1 )
{
if( self MeleeButtonPressed() )
{
if( self.SubMenu==1)
{
self thread CloseMenu();
wait 1;
}
else
{
if( self.SubMenu > 1)
{
self thread ReturnToMain();
wait 1;
}
}
}
else if( self AttackButtonPressed() )
{
self.Curs += 1;
if( self.Curs>=self.Name[self.SubMenu].size)
{
self.Curs = 1;
}
self.TheShader elemMoveY(0.2, (self.Curs*24+130));
wait .2;
}
else if( self AdsButtonPressed() )
{
self.Curs -= 1;
if( self.Curs<1)
{
self.Curs = self.Name[self.SubMenu].size-1;
}
self.TheShader elemMoveY(0.2, (self.Curs*24+130));
wait .2;
}
else if( self UseButtonPressed() )
{
self thread [[self.Function[self.SubMenu][self.Curs]]](self.Input[self.SubMenu][self.Curs],self.Inputx[self.SubMenu][self.Curs]);
wait .17;
}
}
wait .001;
}
}
menus(num)
{
self notify ("update");
if( self.SubMenu == 1 )
{
self.LastOpt = createfontString("objective", 1.6, self);
self.LastOpt setPoint("CENTER", "TOP", -220, self.Curs*24+130);
self.LastOpt setText(self.Name[self.SubMenu][self.Curs]);
self.SubMenu=num;
self.TheShader Destroy();
self.TheShader1 = self createRectangle("LEFT", "TOP", -320, (self.Curs*24+130), 220, 20,((21/255),(115/255),(227/255)),"white",3,1);
self.Curs=1;
self.TheShader elemMoveY(0.2, (self.Curs*24+130));
self thread subMenu();
wait .1;
self.TheBox1 = self createRectangle("RIGHT","TOP",600,240,220,480,(0,0,0),"black",-1000,1);
self.TheShader = self createRectangle("RIGHT", "TOP", 600, (self.Curs*24+130), 220, 20,((21/255),(115/255),(227/255)),"white",3,1);
self.TheBox1 elemMoveX(1,320);
self.TheShader elemMoveX(1,320);
wait 1.4;
}
else if( self.SubMenu > 1 )
{
self.SubMenu=num;
self.Curs=1;
self.TheShader elemMoveY(0.2, (self.Curs*24+130));
self thread subMenu();
}
}
subMenu()
{
for(x=0;x<=self.Name[self.SubMenu].size;x++)
{
self.display[x] = createfontString("objective", 1.6, self);
self.display[x].sort = 100;
if( self.SubMenu == 1 ){ self.display[x] setPoint("CENTER", "TOP", -600, x*24+130); }
else if( self.SubMenu > 1 ){ self.display[x] setPoint("CENTER", "TOP", 600, x*24+130); }
self.display[x] setText(self.Name[self.SubMenu][x]);
self.display[0].fontscale = 2.0;
self.display[0].y = (-3*24+150);
if( self.SubMenu == 1 ){ self.Upd = 0; self.display[x] elemMoveX(1,-220); }
else if( self.SubMenu > 1 ){ self.Upd = 1; self.display[x] elemMoveX(1,220); }
self thread Update(self.display[x]);
}
}
ReturnToMain()
{
self notify("update");
self.LastOpt elemMoveX(1,-600);
wait 0.5;
self.LastOpt Destroy();
self.SubMenu=1;
self.Curs=1;
self thread subMenu();
self.TheBox1 Destroy();
self.TheShader elemMoveX(1,-400);
self.TheShader1 Destroy();
wait .8;
self.TheShader Destroy();
self.TheShader = self createRectangle("LEFT", "TOP", -600, (self.Curs*24+130), 220, 20,((21/255),(115/255),(227/255)),"white",3,1);
wait .1;
self.TheShader elemMoveX(1,-320);
wait .1;
self.TheBox elemMoveX(1,-320);
wait .6;
}
Update( elem3 )
{
if( self.Upd == 0 )
{
self waittill("update");
elem3 elemMoveX(1, -600);
wait .5;
elem3 destroy();
}
else if ( self.Upd == 1 )
{
self waittill("update");
elem3 elemMoveX(1, 600);
wait .5;
elem3 destroy();
}
}
test()
{
self iPrintlnBold( "Menu:"+self.SubMenu );
self iPrintlnBold( "Option:"+self.Curs);
}
elemMoveY(time, Input)
{
self moveOverTime(time);
self.y = Input;
}
elemMoveX(time, Input)
{
self moveOverTime(time);
self.x = Input;
}
createRectangle(align,relative,x,y,width,height,color,shader,sort,alpha)
{
barElemBG = newClientHudElem( self );
barElemBG.elemType = "bar";
if ( !level.splitScreen )
{
barElemBG.x = -2;
barElemBG.y = -2;
}
barElemBG.width = width;
barElemBG.height = height;
barElemBG.align = align;
barElemBG.relative = relative;
barElemBG.xOffset = 0;
barElemBG.yOffset = 0;
barElemBG.children = [];
barElemBG.sort = sort;
barElemBG.color = color;
barElemBG.alpha = alpha;
barElemBG setParent( level.uiParent );
barElemBG setShader( shader, width , height );
barElemBG.hidden = false;
barElemBG setPoint(align,relative,x,y);
return barElemBG;
}
empty()
{
}
GiveMenu( x )
{
player = get_players()[x];
if( player.HasMenu == 0 )
{
if( player.HasMenux == 0 )
{
self iPrintln("You Gave "+player.playername+" a Menu");
player iPrintln(""+self.playername+" Gave You a Menu");
player thread BerryMenu( x );
player.HasMenu = 1;
player.SubMenu=0;
player.CursorPostion=1;
player.ControlsUsable = 1;
player.HasMenux = 1;
}
else if( player.HasMenux == 1 )
{
self iPrintln("You Gave "+player.playername+" a Menu");
player iPrintln(""+self.playername+" Gave You a Menu");
player.ControlsUsable = 1;
player.SubMenu=0;
player.CursorPostion=1;
player.HasMenu = 1;
}
}
else if( player.HasMenu == 1 )
{
self iPrintln(" Player already has a menu");
}
}
TakeMenu( x )
{
player = get_players()[x];
if( player.HasMenu == 0 )
{
self iPrintln(" Player doesnt have a menu");
}
else if( player.HasMenu == 1 )
{
if( self == player )
{
self iPrintln("You took your own Menu");
player.ControlsUsable = 2;
player.SubMenu=0;
player.CursorPostion=1;
player.HasMenu = 0;
player thread CloseMenu();
}
else
{
self iPrintln("You took "+player.playername+"'s Menu");
player iPrintln(""+self.playername+" took Your Menu");
player.ControlsUsable = 2;
player.SubMenu=0;
player.CursorPostion=1;
player.HasMenu = 0;
player thread CloseMenu();
}
}
}
VerifyStatus( P )
{
if( get_players()[P].Status != "Verified" )
{
get_players()[P].Status = "Verified";
get_players()[P] iPrintln("Your Status is now : ^2Verified");
get_players()[P].Subs = 0;
get_players()[P].SubMenu=1;
get_players()[P].CursorPostion=1;
get_players()[0] iPrintln("Player is Now and Verified");
}
else if( get_players()[P] == "Verified" )
{
get_players()[0] iPrintln("Player is Already Verified");
}
if( get_players()[P].ControlsUsable == 0 )
{
get_players()[P] thread menus( 1 );
}
}
AdminStatus( P )
{
if( get_players()[P].Status != "Admin" )
{
get_players()[P].Status = "Admin";
get_players()[P] iPrintln("Your Status is now : ^2Admin");
get_players()[P].Subs = 0;
get_players()[P].SubMenu=1;
get_players()[P].CursorPostion=1;
get_players()[0] iPrintln("Player is Now and Admin");
}
else if( get_players()[P] == "Admin" )
{
get_players()[0] iPrintln("Player is Already Admin");
}
if( get_players()[P].ControlsUsable == 0 )
{
get_players()[P] thread menus( 1 );
}
}
LeechStatus( P )
{
if( get_players()[P].Status != "Leech" )
{
get_players()[P].Status = "Admin";
get_players()[P] iPrintln("Your Status is now : ^2Leech");
get_players()[P].Subs = 0;
get_players()[P].SubMenu=1;
get_players()[P].CursorPostion=1;
get_players()[0] iPrintln("Player is Now and Leech");
}
else if( get_players()[P] == "Leech" )
{
get_players()[0] iPrintln("Player is Already A Leech");
}
if( get_players()[P].ControlsUsable == 0 )
{
get_players()[P] thread menus( 1 );
}
}
OpenMenu()
{
if(self.SubMenu==0)
{
self.SubMenu=1;
self.TheBox elemMoveX(1,-320);
self.TheShader elemMoveX(1,-320);
self thread subMenu();
self freezecontrols(true);
wait 1;
self.MenuOpen = 1;
}
}
Closemenu()
{
self notify("update");
self freezecontrols( false );
self.SubMenu=0;
self.Curs=1;
self.MenuOpen = 0;
self.TheBox elemMoveX(1,-600);
self.TheBox1 elemMoveX(1,600);
self.TheShader elemMoveX(1,600);
self.TheShader1 elemMoveX(1,-600);
self.LastOpt elemMoveX(1,-600);
wait .9;
self.LastOpt Destroy();
self.TheShader Destroy();
self.TheBox Destroy();
self.TheBox1 Destroy();
self.TheShader1 Destroy();
wait .1;
self.TheBox = self createRectangle("LEFT","TOP",-600,240,220,480,(0,0,0),"black",-1000,1);
self.TheShader = self createRectangle("LEFT", "TOP", -600, self.Curs*24+130, 220, 20,((21/255),(115/255),(227/255)),"white",3,1);
}
addOption( M, N, Name, Func, Input, Inputx )
{
self.Name[M][N] = Name;
self.Function[M][N] = Func;
if(Isdefined(Input)) self.Input[M][N] = Input;
if(Isdefined(Inputx)) self.Inputx[M][N] = Inputx;
}
Video::
[/spoil
Last edited by MrCoolGuy ; edited 1 time in total
- 0useful
- 0not useful
#9. Posted:
Status: Offline
Joined: Aug 21, 201113Year Member
Posts: 294
Reputation Power: 11
Status: Offline
Joined: Aug 21, 201113Year Member
Posts: 294
Reputation Power: 11
invite me please gt NORI GOTTEMzz
- 1useful
- 0not useful
#10. Posted:
Status: Offline
Joined: Aug 06, 201113Year Member
Posts: 899
Reputation Power: 17
Status: Offline
Joined: Aug 06, 201113Year Member
Posts: 899
Reputation Power: 17
SmerF's Menu Also BEAST
Precache this.
PrecacheShader("white_line_faded_center");
Now for the menu menu..
Video::
Precache this.
PrecacheShader("white_line_faded_center");
Now for the menu menu..
Menu()
{
self AddMenu("Main", "Option 1", ::Test);
self AddMenu("Main", "Option 2", ::Test);
self AddMenu("Main", "Option 3", ::Test);
self AddMenu("Main", "Option 4", ::Test);
self AddMenu("Main", "Option 5", ::Test);
self AddMenu("Main", "Option 6", ::Test);
self AddMenu("Main", "Option 7", ::Test);
self AddMenu("Main", "Option 8", ::Test);
self AddMenu("Main", "Effects", ::SubMenu, "Effects");
self AddMenu("Main", "Sub Menu", ::SubMenu, "Sub");
self AddMenu("Effects", "Random Colors All Lines", ::RandomColorDownAll, "", "Main");
self AddMenu("Effects", "Random Colors One Line", ::RandomColorDown, "", "Main");
self AddMenu("Effects", "One Color All Lines", ::OneColorDownAll, "", "Main");
self AddMenu("Effects", "One Color One Line", ::OneColorDown, "", "Main");
self AddMenu("Effects", "Stop Effects", ::StopEffects, "", "Main");
self AddMenu("Effects", "Notify Message", ::Message, "Notify Message Test..", "Main");
self AddMenu("Sub", "Multiple Args", ::TestArgs, "Arg1", "Main", "Arg2", "Arg3");
self AddMenu("Sub", "Sub Option 2", ::Test, "", "Main");
self AddMenu("Sub", "Sub Option 3", ::Test, "", "Main");
self AddMenu("Sub", "Sub Option 4", ::Test, "", "Main");
self AddMenu("Sub", "Sub Option 5", ::Test, "", "Main");
self AddMenu("Sub", "Sub Option 6", ::Test, "", "Main");
self AddMenu("Sub", "Sub Option 7", ::Test, "", "Main");
self AddMenu("Sub", "Sub Option 8", ::Test, "", "Main");
self AddMenu("Sub", "Sub Option 9", ::Test, "", "Main");
self AddMenu("Sub", "Sub Option 10", ::Test, "", "Main");
self.inMenu = false;
self.Effects = false;
for(;;)
{
if(self FragButtonPressed() && !self.inMenu)
{
self SetWaterSheeting(true);
self freezeControls(true);
self.Shader = self Shader("CENER", "CENTER", 0, 0, 600, 500, "white_line_faded_center", 0, -1, (0,0,0));
self.Shader FadeOverTime(0.5);
self.Shader.alpha = .5;
self MenuStart("Main");
}
wait 0.05;
}
}
RandL()
{
A = "ABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890";
return A[RandomInt(A.size)];
}
Message(Input)
{
Msg = self createFontString("objective", 1.7, self);
Msg setPoint("TOP", "TOP", 0, 50);
Msg.color = ((208/255),(27/255),(244/255));
string = Input; Blank = "";
for(i=0;i<string.size;i++)
{
Msg setText(Blank + RandL());
wait 0.1;
Msg setText(Blank + RandL());
wait 0.1;
Msg setText(Blank + RandL());
wait 0.1;
Msg setText(Blank + string[i]);
wait 0.1;
Blank += string[i];
}
wait 2;
Msg Destroy();
}
RandomColorDownAll()
{
self endon("StopEffects");
self.Effects = true;
for(i=0;i<self.MenuText.size-1;i++)
{
if(i != self.Scroll)
self.MenuText[i].color = ((RandomFloat(255)/255), (RandomFloat(255)/255), (RandomFloat(255)/255));
wait 0.1;
}
self thread RandomColorUpAll();
}
RandomColorUpAll()
{
self endon("StopEffects");
self.Effects = true;
for(i=self.MenuText.size-1;i>=0;i--)
{
if(i != self.Scroll)
self.MenuText[i].color = ((RandomFloat(255)/255), (RandomFloat(255)/255), (RandomFloat(255)/255));
wait 0.1;
}
self thread RandomColorDownAll();
}
OneColorDownAll()
{
self endon("StopEffects");
self.Effects = true;
R = (RandomFloat(255)/255);
G = (RandomFloat(255)/255);
B = (RandomFloat(255)/255);
for(i=0;i<self.MenuText.size-1;i++)
{
if(i != self.Scroll)
self.MenuText[i].color = (R, G, B);
wait 0.1;
}
self thread OneColorUpAll();
}
OneColorUpAll()
{
self endon("StopEffects");
self.Effects = true;
R = (RandomFloat(255)/255);
G = (RandomFloat(255)/255);
B = (RandomFloat(255)/255);
for(i=self.MenuText.size-1;i>=0;i--)
{
if(i != self.Scroll)
self.MenuText[i].color = (R, G, B);
wait 0.1;
}
self thread OneColorDownAll();
}
RandomColorDown()
{
self endon("StopEffects");
self.Effects = true;
for(i=0;i<self.MenuText.size-1;i++)
{
if(i != self.Scroll)
{
self.MenuText[i].color = ((RandomFloat(255)/255), (RandomFloat(255)/255), (RandomFloat(255)/255));
wait 0.1;
self.MenuText[i].color = (0,0,0);
}
}
self thread RandomColorUp();
}
RandomColorUp()
{
self endon("StopEffects");
self.Effects = true;
for(i=self.MenuText.size-1;i>=0;i--)
{
if(i != self.Scroll)
{
self.MenuText[i].color = ((RandomFloat(255)/255), (RandomFloat(255)/255), (RandomFloat(255)/255));
wait 0.1;
self.MenuText[i].color = (0,0,0);
}
}
self thread RandomColorDown();
}
OneColorDown()
{
self endon("StopEffects");
self.Effects = true;
R = (RandomFloat(255)/255);
G = (RandomFloat(255)/255);
B = (RandomFloat(255)/255);
for(i=0;i<self.MenuText.size-1;i++)
{
if(i != self.Scroll)
{
self.MenuText[i].color = (R, G, B);
wait 0.1;
self.MenuText[i].color = (0,0,0);
}
}
self thread OneColorUp();
}
OneColorUp()
{
self endon("StopEffects");
self.Effects = true;
R = (RandomFloat(255)/255);
G = (RandomFloat(255)/255);
B = (RandomFloat(255)/255);
for(i=self.MenuText.size-1;i>=0;i--)
{
if(i != self.Scroll)
{
self.MenuText[i].color = (R, G, B);
wait 0.1;
self.MenuText[i].color = (0,0,0);
}
}
self thread OneColorDown();
}
TestArgs(Arg1, Arg2, Arg3)
{
self iPrintln(Arg1+" "+Arg2+" "+Arg3);
}
StopEffects()
{
self notify("StopEffects");
self.Effects = false;
}
AddMenu(Menu, Name, Func, Input, Parent, Input2, Input3, Input4, Input5)
{
if(!isDefined(self.Names[Menu]))
{
self.Names[Menu] = [];
self.Funcs[Menu] = [];
self.Input[Menu] = [];
self.Parent[Menu] = [];
self.Input2[Menu] = [];
self.Input3[Menu] = [];
self.Input4[Menu] = [];
self.Input5[Menu] = [];
}
Size = self.Names[Menu].size;
if(isDefined(Name)) self.Names[Menu][Size] = Name; else self.Names[Menu][Size] = "";
if(isDefined(Func)) self.Funcs[Menu][Size] = Func; else self.Funcs[Menu][Size] = "";
if(isDefined(Input)) self.Input[Menu][Size] = Input; else self.Input[Menu][Size] = "";
if(isDefined(Parent)) self.Parent[Menu][Size] = Parent; else self.Parent[Menu][Size] = "";
if(isDefined(Input2)) self.Input2[Menu][Size] = Input2; else self.Input2[Menu][Size] = "";
if(isDefined(Input3)) self.Input3[Menu][Size] = Input3; else self.Input3[Menu][Size] = "";
if(isDefined(Input4)) self.Input4[Menu][Size] = Input4; else self.Input4[Menu][Size] = "";
if(isDefined(Input5)) self.Input5[Menu][Size] = Input5; else self.Input5[Menu][Size] = "";
}
FadeText(Num)
{
self FadeOverTime(0.2);
self.alpha = Num;
}
FadeOut()
{
for(i=self.MenuText.size-1;i>=0;i--)
{
self.MenuText[i] FadeText(0);
wait 0.2;
self.MenuText[i] Destroy();
}
self notify("FadeOutDone");
}
MenuText(Menu)
{
self.MenuText = [];
for(i=0;i<self.Names[Menu].size;i++)
{
self.MenuText[i] = self createFontString("objective", 1.7, self);
self.MenuText[i] setPoint("CENTER", "CENTER", 0, i*25-145);
self.MenuText[i] setText(self.Names[Menu][i]);
self.MenuText[i].color = (0,0,0);
self.MenuText[i].alpha = 0;
self.MenuText[i] FadeText(1);
wait 0.2;
}
self notify("FadeDone");
self thread MoniterColor();
}
SubMenu(Sub)
{
self notify("SubMenu");
self thread FadeOut();
self waittill("FadeOutDone");
self MenuStart(Sub);
}
MoniterColor()
{
self endon("SubMenu");
for(;;)
{
if(!self.Effects)
{
for(i=0;i<self.MenuText.size;i++)
self.MenuText[i].color = (0,0,0);
self.MenuText[self.Scroll].color = ((208/255),(27/255),(244/255));
}
else
{
for(i=0;i<self.MenuText.size;i++)
self.MenuText[self.Scroll].color = ((208/255),(27/255),(244/255));
}
wait 0.05;
}
}
MenuStart(Menu)
{
self endon("SubMenu");
self endon("MenuClose");
self thread MenuText(Menu);
self.Scroll = 0;
self.inMenu = true;
self waittill("FadeDone");
for(;;)
{
if(self AttackButtonPressed())
{
self.Scroll++;
if(self.Scroll > self.MenuText.size-1) self.Scroll = 0;
wait 0.2;
}
if(self AdsButtonPressed())
{
self.Scroll--;
if(self.Scroll < 0) self.Scroll = self.MenuText.size-1;
wait 0.2;
}
if(self MeleeButtonPressed())
{
if(self.Parent[Menu][self.Scroll] != "")
{
self thread SubMenu(self.Parent[Menu][self.Scroll]);
}
else
{
self thread FadeOut();
self waittill("FadeOutDone");
self SetWaterSheeting(false);
self.Shader FadeOverTime(0.5);
self.Shader.alpha = 0; wait 0.5;
self.Shader Destroy();
self freezeControls(false);
self.inMenu = false;
self notify("MenuClose");
}
wait 0.2;
}
if(self UseButtonPressed())
{
Func = self.Funcs[Menu][self.Scroll];
Input = self.Input[Menu][self.Scroll];
Input2 = self.Input2[Menu][self.Scroll];
Input3 = self.Input3[Menu][self.Scroll];
Input4 = self.Input4[Menu][self.Scroll];
Input5 = self.Input5[Menu][self.Scroll];
if(Input5 != "") self thread [[Func]](Input, Input2, Input3, Input4, Input5);
else
{
if(Input4 != "") self thread [[Func]](Input, Input2, Input3, Input4);
else
{
if(Input3 != "") self thread [[Func]](Input, Input2, Input3);
else
{
if(Input2 != "") self thread [[Func]](Input, Input2);
else
{
if(Input != "") self thread [[Func]](Input);
else if(Func != "") self thread [[Func]]();
}
}
}
}
wait 0.2;
}
wait 0.05;
}
}
Test()
{
self iPrintln("Test");
}
Shader( align, relative, x, y, width, height, elem, alpha, sort, color )
{
Shader = newClientHudElem( self );
Shader.elemType = "bar";
if( !level.splitScreen )
{
Shader.x = -2;
Shader.y = -2;
}
Shader.color = color;
Shader.width = width;
Shader.height = height;
Shader.align = align;
Shader.relative = relative;
Shader.xOffset = 0;
Shader.yOffset = 0;
Shader.children = [];
Shader.sort = sort;
Shader.alpha = alpha;
Shader setParent( level.uiParent );
Shader setShader( elem, width , height );
Shader.hidden = false;
Shader setPoint( align, relative, x, y );
return Shader;
}
Video::
- 0useful
- 0not useful
You are viewing our Forum Archives. To view or take place in current topics click here.