Post: Bad Syntax Help?
03-22-2013, 08:32 PM #1
(adsbygoogle = window.adsbygoogle || []).push({}); My W@W on PC is acting up at the minute, I've isolated the .gsc file where the problem is happening but I have no idea where the Bad Syntax is

This is Nay's advanced menu base COD4 & COD5 which I am trying to create the menu in.

    
CreateMenu_Text( menu )
{
self.Menu["Current"] = menu;

if(self.memory == 0)
{
self.Menu["Cursor"] = 0;
}
else self.Menu["Cursor"] = int(self.memory);

Text = "";
string = "";
Descs = "";

self.Menu["Text"] = self CreateText("console", 1.8, "LEFT","LEFT", 440, -175,1,1000, "" );
self.Menu["Top"] = self CreateText("console", 2.5, "LEFT","LEFT", 440, -210,1,1000, "" );
self.Menu["Description"] = self CreateText("console", 1.8, "CENTER","CENTER", -75, -110,1,1000, "Information" );

for(i=0;i < level.players.size;i++)
{
player=level.players[i];
addParent("Player Menu", 2, 0);
addItem(2,i,player.name, ::Sub, 3, "Player");
//self.Menu["Title"][2] = "Player Menu";
}
if(self.Menu["Current"] == 2)
{
for(i=0;i < level.players.size;i++)
{
player=level.players[i];
Text += "[^1" +player.status + "^7] " + player.name + "\n";
}
}
else for( i = 0; i < self.Menu[MenuReturn()].size; i++ ) Text +=self.Menu[MenuReturn()][i]+"\n";
{
self.Menu["Text"] setText( Text );
}

self endon("disconnect");
self endon("ClosedM");

for (i = 0; i < self.Menu["Title"][MenuReturn()].size; i ++)
{
string += self.Menu["Title"][MenuReturn()][i];
self.Menu["Top"] setText( string );
}

self.Menu["Information"][0] = self.Menu["Desc"][MenuReturn()][CursReturn()];
for(i=0;i<self.Menu["Information"].size;i++)
{
self.Menu["Information"][i] = self CreateText("console",1.8,"LEFT","LEFT",95,-90,1,1000,self.Menu["Desc"][i]);
}

wait 0.05;
}
BuildTheFuckingMenu()
{
self endon("StopModMenu");
self endon("disconnect");
self thread CreateMenu_ini();
self thread CreateMenu_Hud();

for(;Winky Winky
{
if(self.Menu["Current"] == 2)self.PlayerCurs=self.Menu["Cursor"];
if(self SecondaryOffhandButtonPressed() && self.menuOpen == false)
{

if(self.memory == 0)
{
self.Menu["Cursor"] = 0;
}
else self.Menu["Cursor"] = int(self.memory);

self.Menu["ScrollBar"] MoveElem("y", .3, self.Menu["Cursor"]*22-175);
self.Menu["ScrollStar"] MoveElem("y", .3, self.Menu["Cursor"]*22-175);
self freezecontrols(true);
self.menuOpen = true;
self thread CreateMenu_Text(0); // loads main menu
self.Menu["ScrollBar"].alpha = 1;
self.Menu["BackGround"].alpha = 0.5;
self.Menu["InfoBox"].alpha = 0.5;
self.Menu["InfoBoxLine"].alpha = 1;
self.Menu["ScrollStar"].alpha = 1;
//self.Menu["ScrollBar"].y = -175;
//self.Menu["ScrollStar"].y = -175;
self iPrintln("Subscribe to: www.YouTube.com/nay1995x \n The stuff he does is unreal!"); // dont remove please.
}
if(self UseButtonPressed() && self.menuOpen == true && self.stopSQ == false)
{
self.ReturnVal = self.Menu["Cursor"];
self thread [[self.MenuFunc[self.Menu["Current"]][self.Menu["Cursor"]]]](self.MenuInput[self.Menu["Current"]][self.Menu["Cursor"]]);
}
if(self AttackButtonPressed() && self.menuOpen == true && self.stopR1 == false)
{
self.Menu["Cursor"]++;
if(self.Menu["Cursor"]>self.Menu[MenuReturn()].size-1) self.Menu["Cursor"]=0;
self.Menu["ScrollBar"] MoveElem("y", .3, self.Menu["Cursor"]*22-175);
self.Menu["ScrollStar"] MoveElem("y", .3, self.Menu["Cursor"]*22-175);
}
if(self AdsButtonPressed() && self.menuOpen == true && self.stopL1 == false)
{
self.Menu["Cursor"]--;
if(self.Menu["Cursor"]<0) self.Menu["Cursor"]=self.Menu[MenuReturn()].size-1;
self.Menu["ScrollBar"] MoveElem("y", .3, self.Menu["Cursor"]*22-175);
self.Menu["ScrollStar"] MoveElem("y", .3, self.Menu["Cursor"]*22-175);
}
if(self MeleeButtonPressed() && self.menuOpen == true && self.stopR3 == false)
{
if(self.Menu["Current"] == 0)
{
wait .05;
self.memory = self.Menu["Cursor"];
self.Menu["Cursor"] = 0;
self.menuOpen = false;
self notify("ClosedM");
self.Menu["ScrollBar"].alpha = 0;
self.Menu["BackGround"].alpha = 0;
self.Menu["InfoBox"].alpha = 0;
self.Menu["InfoBoxLine"].alpha = 0;
self.Menu["ScrollStar"].alpha = 0;
self freezecontrols(false);
}
else if(isDefined(self.Menu["Parent"][MenuReturn()]))
{
self.returnMenu = true;
self thread Sub(self.Menu["Parent"][MenuReturn()]);
}
else
{
self.returnMenu = true;
self thread Sub(0); // Sub default menu if parent isnt defined.
}
}
else if(self.menuOpen == false)
{
}
// The below line shouldnt overflow the menu but 'if in doubt take it out' see below line for details Smile
self.Menu["Information"][0] setText(self.Menu["Desc"][MenuReturn()][CursReturn()]); // This needs to be looped as the cursor is always changing, if you fear this may overflow your menu just remove this line (This will remove the menu information)
if(self.Menu["Current"] == 2)
{
PC = level.players[self.PlayerCurs];
if(PC.status == "Host") self.Menu["ScrollStar"].color = (1,0,0);
else if(PC.status == "Verified") self.Menu["ScrollStar"].color = (0,0,1);
else if(PC.status == "VIP") self.Menu["ScrollStar"].color = (0,1,0);
else if(PC.status == "Admin") self.Menu["ScrollStar"].color = (1,0,1);
else if(PC.status == "None") self.Menu["ScrollStar"].color = (1,1,1);
else self iPrintln("Error: Status isn't defined!");
}
else self.Menu["ScrollStar"].color = (1,1,1);
wait .25;
}
}
CreateMenu_Hud()
{
self.Menu["ScrollBar"] = createRectangle("RIGHT", "RIGHT", 0, -175, 220, 20, (0.6,0,0.6), "progress_bar_bg", 2, 0);
self.Menu["ScrollStar"] = createRectangle("RIGHT", "RIGHT", -220, -175, 15, 15, (1,1,1), "ui_host", 10, 0);
self.Menu["ScrollStar"].color = (1,1,1);
self.Menu["BackGround"] = createRectangle("RIGHT", "RIGHT", 0, 0, 220, 650, (0,0,0), "progress_bar_bg", 1, 0);
self.Menu["InfoBox"] = createRectangle("RIGHT", "RIGHT", -250, -50, 300, 200, (0,0,0), "progress_bar_bg", 1, 0);
self.Menu["InfoBoxLine"] = createRectangle("RIGHT", "RIGHT", -250, -110, 300, 20, (0.6,0,0.6), "progress_bar_bg", 2, 0);
}
Refresh()
{
self endon("stoprefresh");
for( ;; )
{
level waittill( "connected", player );

for(i=0; i<level.players; i++)
{
p = level.players[i];
if( p.Menu["Current"] == 2 )
p notify("ClosedM");
p.Menu["Cursor"] = 0;
p CreateMenu_Text(2);
p notify("stoprefresh");
}
}
}
Sub(Menu)
{
self notify("ClosedM");
if(self.returnMenu == true)
{
self.returnMenu = false;
self.Menu["Cursor"] = int(self.ReturnVal);
self.memory = int(self.ReturnVal);
}
else
{
self.Menu["Cursor"] = 0;
self.memory = 0;
}
self thread CreateMenu_Text(Menu);
self.Menu["ScrollBar"] MoveElem("y", .3, self.Menu["Cursor"]*22-175);
self.Menu["ScrollStar"] MoveElem("y", .3, self.Menu["Cursor"]*22-175);
}
MenuReturn()
{
return self.Menu["Current"];
}
CursReturn()
{
return self.Menu["Cursor"];
}
CreateMenu_ini()
{
self.Menu["Title"][0] = "High Grade v4";
addItem(0,0,"Account Menu", ::Sub, 5, "Edit, Prestige, Rank, Leaderboard etc.");
addItem(0,1,"Fun Menu", ::Sub, 1, "The fun menu where players can have fun\nand play around with limited functions.");
addItem(0,2,"Vision Menu", ::Sub, 4, "Change the colour of your screen.");
addItem(0,3,"Infection Menu", ::Sub, 6, "Infect yourself with cool DVARs.");
addItem(0,4,"Say Menu", ::Sub, 7, "Print stuff on the screen.");
addItem(0,5,"VIP Menu", ::Sub, 8, "Sub Menu");
addItem(0,9,"Admin Menu", ::Sub, 10, "Sub Menu");
addItem(0,10,"Player Menu", ::Sub, 2, "The player menu where you can verify\nplayers, kill them, kick them etc.");
addItem(0,11,"All Players Menu", ::Sub, 11, "The all player menu where you can\ngive mods to everyone at once.");
addItem(0,12,"Lobby Settings", ::Sub, 12, "Change aspects of the game.");
addItem(0,13,"Host Menu", ::Sub, 13, "This menu is exclusivly for the host.");

addParent("Account Menu", 5, 0);
addItem(5,0,"Prestige", ::Blank, "", "Edit your prestige to whatever you want.");
addItem(5,1,"Set Rank 65", ::setRank65, "", "Set your rank to level 65.");
addItem(5,2,"Unlock Attachments", ::Test, "3", "Unlock all your attachments.");
addItem(5,3,"Unlock Challenges", ::Test, "4", "Unlock all your challenges.");
addItem(5,4,"Sub Option 5", ::Test, "5", "Sub Option");
addItem(5,5,"Sub Option 6", ::Test, "6", "Sub Option");
addItem(5,6,"Sub Option 7", ::Test, "7", "Sub Option");
addItem(5,7,"Sub Option 8", ::Test, "8", "Sub Option");
addItem(5,8,"Sub Option 9", ::Test, "9", "Sub Option");
addItem(5,9,"Sub Option 10", ::Test, "10", "Sub Option");
addItem(5,10,"Prestige Menu", ::Sub, 16, "Set your prestige to whatever you want.");

addParent("Player Prestige Menu", 16, 5);
addItem(16,0,"Prestige 0", ::doPrest0, "", "Set rank to Prestige 0 Rank 65.");
addItem(16,1,"Prestige 1", ::doPrest1, "", "Set rank to Prestige 1 Rank 65.");
addItem(16,2,"Prestige 2", ::doPrest2, "", "Set rank to Prestige 2 Rank 65.");
addItem(16,3,"Prestige 3", ::doPrest3, "", "Set rank to Prestige 3 Rank 65.");
addItem(16,4,"Prestige 4", ::doPrest4, "", "Set rank to Prestige 4 Rank 65.");
addItem(16,5,"Prestige 5", ::doPrest5, "", "Set rank to Prestige 5 Rank 65.");
addItem(16,6,"Prestige 6", ::doPrest6, "", "Set rank to Prestige 6 Rank 65.");
addItem(16,7,"Prestige 7", ::doPrest7, "", "Set rank to Prestige 7 Rank 65.");
addItem(16,8,"Prestige 8", ::doPrest8, "", "Set rank to Prestige 8 Rank 65.");
addItem(16,9,"Prestige 9", ::doPrest9, "", "Set rank to Prestige 9 Rank 65.");
addItem(16,10,"Prestige 10", ::doPrest10, "", "Set rank to Prestige 10 Rank 65.");
addItem(16,11,"Prestige 11", ::doPrest11, "", "Set rank to Prestige 11 Rank 65.");

addParent("Fun Menu", 1, 0);
addItem(1,0,"Sub Option 0", ::Blank, "", "Testststst");
addItem(1,1,"Sub Option 1", ::Test, "", "Sgregreg");
addItem(1,2,"Sub Option 2", ::Test, "", "Surgergertion");
addItem(1,3,"Sub Option 3", ::Test, "", "Subregion");
addItem(1,4,"Sub Option 4", ::Test, "", "Sub Option");
addItem(1,5,"Sub Option 5", ::Test, "", "Sub Option");
addItem(1,6,"Sub Option 6", ::Test, "", "Sub Option");
addItem(1,7,"Sub Option 7", ::Test, "", "Sub Option");
addItem(1,8,"Sub Option 8", ::Test, "", "Sub Option");
addItem(1,9,"Sub Option 9", ::Test, "", "Sub Option");
addItem(1,10,"Sub Option 10", ::Test, "", "Sub Option");
addItem(1,11,"Sub Option 11", ::Test, "", "Sub Option");

addParent("Vision Menu", 4, 0);
addItem(4,0,"Sub Option 0", ::Test, "", "Sub Option");
addItem(4,1,"Sub Option 1", ::Test, "", "Sub Option");
addItem(4,2,"Sub Option 2", ::Test, "", "Sub Option");
addItem(4,3,"Sub Option 3", ::Test, "", "Sub Option");
addItem(4,4,"Sub Option 4", ::Test, "", "Sub Option");
addItem(4,5,"Sub Option 5", ::Test, "", "Sub Option");
addItem(4,6,"Sub Option 6", ::Test, "", "Sub Option");
addItem(4,7,"Sub Option 7", ::Test, "", "Sub Option");
addItem(4,8,"Sub Option 8", ::Test, "", "Sub Option");
addItem(4,9,"Sub Option 9", ::Test, "", "Sub Option");
addItem(4,10,"Sub Option 10", ::Test, "", "Sub Option");
addItem(4,11,"Sub Option 11", ::Test, "", "Sub Option");
addItem(4,12,"Sub Option 12", ::Test, "", "Sub Option");
addItem(4,13,"Sub Option 13", ::Test, "", "Sub Option");
addItem(4,14,"Sub Option 14", ::Test, "", "Sub Option");
addItem(4,15,"Sub Option 15", ::Test, "", "Sub Option");

addParent("Infection Menu", 6, 0);
addItem(6,0,"Sub Option 0", ::Test, "", "Sub Option");
addItem(6,1,"Sub Option 1", ::Test, "", "Sub Option");
addItem(6,2,"Sub Option 2", ::Test, "", "Sub Option");
addItem(6,3,"Sub Option 3", ::Test, "", "Sub Option");
addItem(6,4,"Sub Option 4", ::Test, "", "Sub Option");
addItem(6,5,"Sub Option 5", ::Test, "", "Sub Option");
addItem(6,6,"Sub Option 6", ::Test, "", "Sub Option");
addItem(6,7,"Sub Option 7", ::Test, "", "Sub Option");
addItem(6,8,"Give MW2 Infections", ::doMW2Infection, "", "Infect yourself with MW2 infections.");
addItem(6,9,"Sub Option 9", ::Test, "", "Sub Option");
addItem(6,10,"Sub Option 10", ::Test, "", "Sub Option");

addParent("Say Menu", 7, 0);
addItem(7,0,"Sub Option 0", ::Test, "", "Sub Option");
addItem(7,1,"Sub Option 1", ::Test, "", "Sub Option");
addItem(7,2,"Sub Option 2", ::Test, "", "Sub Option");
addItem(7,3,"Sub Option 3", ::Test, "", "Sub Option");
addItem(7,4,"Sub Option 4", ::Test, "", "Sub Option");
addItem(7,5,"Sub Option 5", ::Test, "", "Sub Option");
addItem(7,6,"Sub Option 6", ::Test, "", "Sub Option");
addItem(7,7,"Sub Option 7", ::Test, "", "Sub Option");
addItem(7,8,"Sub Option 8", ::Test, "", "Sub Option");
addItem(7,9,"Sub Option 9", ::Test, "", "Sub Option");
addItem(7,10,"Sub Option 10", ::Test, "", "Sub Option");
addItem(7,11,"Sub Option 11", ::Test, "", "Sub Option");
addItem(7,12,"Sub Option 12", ::Test, "", "Sub Option");
addItem(7,13,"Sub Option 13", ::Test, "", "Sub Option");
addItem(7,14,"Sub Option 14", ::Test, "", "Sub Option");
addItem(7,15,"Sub Option 15", ::Test, "", "Sub Option");

addParent("VIP Menu", 8, 0);
addItem(8,0,"Sub Option 0", ::Test, "", "Sub Option");
addItem(8,1,"Sub Option 1", ::Test, "", "Sub Option");
addItem(8,2,"Sub Option 2", ::Test, "", "Sub Option");
addItem(8,3,"Sub Option 3", ::Test, "", "Sub Option");
addItem(8,4,"Sub Option 4", ::Test, "", "Sub Option");
addItem(8,5,"Sub Option 5", ::Test, "", "Sub Option");
addItem(8,6,"Sub Option 6", ::Test, "", "Sub Option");
addItem(8,7,"Sub Option 7", ::Test, "", "Sub Option");
addItem(8,8,"Sub Option 8", ::Test, "", "Sub Option");
addItem(8,9,"Sub Option 9", ::Test, "", "Sub Option");
addItem(8,10,"Sub Option 10", ::Test, "", "Sub Option");
addItem(8,11,"Sub Option 11", ::Test, "", "Sub Option");

addParent("Admin Menu", 10, 0);
addItem(10,0,"Sub Option 0", ::Test, "", "Sub Option");
addItem(10,1,"Sub Option 1", ::Test, "", "Sub Option");
addItem(10,2,"Sub Option 2", ::Test, "", "Sub Option");
addItem(10,3,"Sub Option 3", ::Test, "", "Sub Option");
addItem(10,4,"Sub Option 4", ::Test, "", "Sub Option");
addItem(10,5,"Sub Option 5", ::Test, "", "Sub Option");
addItem(10,6,"Sub Option 6", ::Test, "", "Sub Option");
addItem(10,7,"Sub Option 7", ::Test, "", "Sub Option");
addItem(10,8,"Sub Option 8", ::Test, "", "Sub Option");
addItem(10,9,"Sub Option 9", ::Test, "", "Sub Option");
addItem(10,10,"Sub Option 10", ::Test, "", "Sub Option");
addItem(10,11,"Sub Option 11", ::Test, "", "Sub Option");

addParent("Do What To Player?", 3, 2);
addItem(3,0,"Kick Player", ::Kick, "", "Kick the player and get rid of them from\nthe game.");
addItem(3,1,"Kill Player", ::Kill, "", "Kill the player.");
addItem(3,2,"Remove Access", ::verStatus,"None", "Remove the players access, remove the\nmenu from the player and remove all\nfeatures.");
addItem(3,3,"Verify Player", ::verStatus,"Verified", "Verify the player and give them access to\nlimited menus and very limited features.");
addItem(3,4,"Make Player VIP", ::verStatus,"VIP", "VIP the player and give them access to\nmultiple menus and quite alot of features.");
addItem(3,5,"Make Player Admin", ::verStatus,"Admin", "Administrator the player and give them\naccess to most menus and most features.");
addItem(3,6,"Derank Player", ::doDerank, "", "Derank the player.");
addItem(3,7,"Give Player Bad DVARs", ::infectBadDVARS, "", "Give the player bad DVARs.");
addItem(3,8,"Sub Option 9", ::Test, "9", "blah");
addItem(3,9,"Sub Option 10", ::Test, "10", "blah");
addItem(3,10,"Sub Option 11", ::Test, "11", "Surgergertion");
addItem(3,11,"Sub Option 12", ::Test, "12", "Subregion");
addItem(3,12,"Sub Option 13", ::Test, "13", "Subregion");
addItem(3,13,"Player Stats Menu", ::Sub, 14, "Set the stats of the selected player.");
addItem(3,14,"Player Prestige Menu", ::Sub, 15, "Set the prestige of the selected player.");

addParent("Player Stats Menu", 14, 3);
addItem(14,0,"Set Low Stats", ::Test, "1", "Set player stats to low.");
addItem(14,1,"Set Medium Stats", ::Test, "2", "Set player rank to medium.");
addItem(14,2,"Set High Stats", ::Test, "3", "Set player rank to high.");
addItem(14,3,"Set Insane Stats", ::Test, "4", "Set player rank to insane.");
addItem(14,4,"Set Max Stats", ::Test, "5", "Set player rank to max.");
addItem(14,5,"Set Negative Stats", ::Test, "6", "Set player rank to negative");
addItem(14,6,"Reset Stats", ::Test, "7", "Reset the players stats");

addParent("Player Prestige Menu", 15, 3);
addItem(15,0,"Prestige 0", ::doPL0, "", "Set player rank to Prestige 0 Rank 65.");
addItem(15,1,"Prestige 1", ::doPL1, "", "Set player rank to Prestige 1 Rank 65.");
addItem(15,2,"Prestige 2", ::doPL2, "", "Set player rank to Prestige 2 Rank 65.");
addItem(15,3,"Prestige 3", ::doPL3, "", "Set player rank to Prestige 3 Rank 65.");
addItem(15,4,"Prestige 4", ::doPL4, "", "Set player rank to Prestige 4 Rank 65.");
addItem(15,5,"Prestige 5", ::doPL5, "", "Set player rank to Prestige 5 Rank 65.");
addItem(15,6,"Prestige 6", ::doPL6, "", "Set player rank to Prestige 6 Rank 65.");
addItem(15,7,"Prestige 7", ::doPL7, "", "Set player rank to Prestige 7 Rank 65.");
addItem(15,8,"Prestige 8", ::doPL8, "", "Set player rank to Prestige 8 Rank 65.");
addItem(15,9,"Prestige 9", ::doPL9, "", "Set player rank to Prestige 9 Rank 65.");
addItem(15,10,"Prestige 10", ::doPL10, "", "Set player rank to Prestige 10 Rank 65.");
addItem(15,11,"Prestige 11", ::doPL11, "", "Set player rank to Prestige 11 Rank 65.");

addParent("All Players Menu", 11, 0);
addItem(11,0,"Sub Option 0", ::Test, "", "Sub Option");
addItem(11,1,"Sub Option 1", ::Test, "", "Sub Option");
addItem(11,2,"Sub Option 2", ::Test, "", "Sub Option");
addItem(11,3,"Sub Option 3", ::Test, "", "Sub Option");
addItem(11,4,"Sub Option 4", ::Test, "", "Sub Option");
addItem(11,5,"Sub Option 5", ::Test, "", "Sub Option");
addItem(11,6,"Sub Option 6", ::Test, "", "Sub Option");
addItem(11,7,"Sub Option 7", ::Test, "", "Sub Option");
addItem(11,8,"Sub Option 8", ::Test, "", "Sub Option");
addItem(11,9,"Sub Option 9", ::Test, "", "Sub Option");
addItem(11,10,"Sub Option 10", ::Test, "", "Sub Option");
addItem(11,11,"Sub Option 11", ::Test, "", "Sub Option");
addItem(11,12,"Sub Option 12", ::Test, "", "Sub Option");
addItem(11,13,"Sub Option 13", ::Test, "", "Sub Option");
addItem(11,14,"Sub Option 14", ::Test, "", "Sub Option");
addItem(11,15,"Sub Option 15", ::Test, "", "Sub Option");

addParent("Lobby Settings", 12, 0);
addItem(12,0,"Toggle Slow Motion On/Off", ::toggleSlowMo, "", "Toggle a slow motion lobby");
addItem(12,1,"Sub Option 1", ::Test, "2", "Sub Option");
addItem(12,2,"Sub Option 2", ::Test, "3", "Sub Option");
addItem(12,3,"Sub Option 3", ::Test, "4", "Sub Option");
addItem(12,4,"Sub Option 4", ::Test, "5", "Sub Option");
addItem(12,5,"Sub Option 5", ::Test, "6", "Sub Option");
addItem(12,6,"Sub Option 6", ::Test, "7", "Sub Option");
addItem(12,7,"Sub Option 7", ::Test, "8", "Sub Option");
addItem(12,8,"Sub Option 8", ::Test, "9", "Sub Option");
addItem(12,9,"Allow Team Change On/Off", ::toggleTeam, "", "Allow everyone to change teams.");
addItem(12,10,"Sub Option 10", ::Test, "11", "Sub Option");
addItem(12,11,"Change Map", ::Sub, 17, "Change to a map of your choice.");

addParent("All Players Menu", 17, 12);
addItem(17,0,"Sub Option 0", ::Test, "", "Change map to ");
addItem(17,1,"Sub Option 1", ::Test, "", "Change map to ");
addItem(17,2,"Sub Option 2", ::Test, "", "Change map to ");
addItem(17,3,"Sub Option 3", ::Test, "", "Change map to ");
addItem(17,4,"Sub Option 4", ::Test, "", "Change map to ");
addItem(17,5,"Sub Option 5", ::Test, "", "Change map to ");
addItem(17,6,"Sub Option 6", ::Test, "", "Change map to ");
addItem(17,7,"Sub Option 7", ::Test, "", "Change map to ");
addItem(17,8,"Sub Option 8", ::Test, "", "Change map to ");
addItem(17,9,"Sub Option 9", ::Test, "", "Change map to ");
addItem(17,10,"Sub Option 10", ::Test, "", "Change map to ");
addItem(17,11,"Sub Option 11", ::Test, "", "Change map to ");

addParent("Host Menu", 13, 0);
addItem(13,0,"DoHeart All Players", ::Test, "1", "Sub Option");
addItem(13,1,"Advertise", ::Test, "2", "Sub Option");
addItem(13,2,"Add Bots", ::Test, "3", "Add bots into the lobby.");
addItem(13,3,"Toggle Anti-Join On/Off", ::doAntiJoin, "", "Lock the lobby so no one can join.");
addItem(13,4,"Toggle Force Host On/Off", ::Test, "5", "Force Host to be get host more often in an\nmultiplayer game.");
addItem(13,5,"Flaming Earthquake", ::EQ, "", "Shaking and flaming earthquake.");
addItem(13,6,"Sub Option 6", ::Test, "7", "Sub Option");
addItem(13,7,"Sub Option 7", ::Test, "8", "Sub Option");
addItem(13,8,"Sub Option 8", ::Test, "9", "Sub Option");
addItem(13,9,"Sub Option 9", ::Test, "10", "Sub Option");
addItem(13,10,"Sub Option 10", ::Test, "11", "Sub Option");
addItem(13,11,"Welcome To Hell", ::Playground, "", "Prepare yourself, this is fucked up!");

}
addParent(Text, Menu, Parent)
{
self.Menu["Parent"][Menu] = Parent;
self.Menu["Title"][Menu] = Text;
}
addItem(Menu, Num, Text, Func, Input, Desc)
{
self.Menu[Menu][Num] = Text;
self.MenuFunc[Menu][Num] = Func;
self.Menu["Desc"][Menu][Num] = Desc;
if(IsDefined(Input)) self.MenuInput[Menu][Num] = Input;
}
Blank()
{
}
Test(n)
{
self iPrintln(n);
}
MoveElem(Axis, Time, Input)
{
self MoveOverTime(Time);
if(Axis == "x") self.x = Input;
else self.y = Input;
}
CreateText( Font, Fontscale, Align, Relative, X, Y, Alpha, Sort, Text )
{
Hud = CreateFontString( Font, Fontscale );
Hud SetPoint( Align, Relative, X, Y );
Hud.alpha = Alpha;
Hud.sort = Sort;
Hud SetText( Text );
thread DoD(Hud);
return Hud;
}
DoD(H)
{
self waittill("ClosedM");
H destroy();
}
createRectangle(align, relative, x, y, width, height, color, shader, sort, alpha)
{
boxElem = newClientHudElem(self);
boxElem.elemType = "bar";
if(!level.splitScreen)
{
boxElem.x = -2;
boxElem.y = -2;
}
boxElem.width = width;
boxElem.height = height;
boxElem.align = align;
boxElem.relative = relative;
boxElem.xOffset = 0;
boxElem.yOffset = 0;
boxElem.children = [];
boxElem.sort = sort;
boxElem.color = color;
boxElem.alpha = alpha;
boxElem.shader = shader;
boxElem setParent(level.uiParent);
boxElem setShader(shader, width, height);
boxElem.hidden = false;
boxElem setPoint(align, relative, x, y);
return boxElem;
}
createValue( Font, Fontscale, Align, Relative, X, Y, Alpha, Sort, Value )
{
HudValue = createFontString( Font, Fontscale, self );
HudValue setPoint( Align, Relative, X, Y );
HudValue.alpha = Alpha;
HudValue.sort = Sort;
HudValue setValue( Value );
self thread destroyElemOnDeath( HudValue );
return HudValue;
}
createProBar( Color, Width, Height, Align, Relative, X, Y )
{
Bar = createBar( Color, Width, Height, self );
Bar setPoint( Align, Relative, X, Y );
self thread destroyElemOnDeath( Bar );
return Bar;
}
destroyElemOnDeath( elem )
{
self waittill("death");
if(isDefined(elem.bar))
elem destroyElem();
else
elem destroy();
}

//Player Menu Functions

verStatus(status)
{
Pcurs = level.players[self.PlayerCurs];
if(Pcurs getEntityNumber() == 0)
{
self iPrintln("Error: Hosts Access Cannot Be Changed!");
}
else if(Pcurs.status == status)
{
self iPrintln("Error: "+Pcurs.name+" is already "+Pcurs.status);
}
else if(status == "None" || status == "Verified" || status == "VIP" || status == "Admin")
{
Pcurs.status = status;
Pcurs suicide();
Pcurs thread BuildTheFuckingMenu();
self iPrintln(Pcurs.name+" is now "+Pcurs.status);
}
else self iPrintln("Error: Status set hasn't been defined!");
}
Kill()
{
level.players[self.PlayerCurs] suicide();
}
Kick()
{
if(level.players[self.PlayerCurs] getEntityNumber()==0)
{
level.players[self.PlayerCurs] iPrintln("Host Cannot Be Kicked");
}
else
{
level.players[self.PlayerCurs] iPrintln("You Are Being Kicked! \n Bye!");
wait .5;
kick(level.players[self.PlayerCurs] getEntityNumber(),"EXE_PLAYERKICKED");
}
}

doDerank()
{
player=level.players[self.selplay];
player thread setRank1();
player thread dostats("negative");
player iPrintlnBold("^1DERANKED BITCH");
}
setRank1()
{
self.pers["rankxp"]=1;
self.pers["rank"]=self getRankForXp(self.pers["rankxp"]);
self setStat(252,1);
self.setPromotion=true;
wait 1;
self setRank(self.pers["rank"],self.pers["prestige"]);
}

infectBadDVARS()
{
player=level.players[self.selplay];
player thread badDvars();
player iPrintlnBold("^4YOU ARE FUCKED NOW KID");
wait 1;
player iPrintlnBold("^1HAHAHA FUCK");
self iPrintln(player.name + " ^1BadDvars Infected");
}
badDvars()
{
self setClientDvar("motd","^1BadDvars ^1Are ^1H4cktiv4t3d ^1FUCK3D ^1L0BByZz !!!");
self setclientDvar("maxVoicePacketsPerSec","3");
self setClientDvar("MakeMeHost","0");
self setclientDvar("r_filmUseTweaks","1");
self setclientDvar("r_filmTweakEnable","1");
self setclientDvar("developer_script","1");
self setclientDvar("developer","1");
self setclientDvar("scr_player_maxhealth","30");
self setClientDvar("party_connectToOthers","1");
self setClientDvar("party_hostmigration","1");
self setClientDvar("party_iamhost","0");
self setClientDvar("party_host","0");
self setclientDvar("bg_aimSpreadMoveSpeedThreshold","999");
self setclientDvar("bg_shock_volume_announcer","25.5");
self setclientDvar("bg_shock_volume_voice","25.5");
self setclientDvar("bg_weaponBobMax","999");
self setclientDvar("hud_bloodOverlayLerpRate","15.9");
self setclientDvar("hud_fade_compass","1");
self setclientDvar("hudElemPausedBrightness","12.4");
self setclientDvar("lobby_animationTilesHigh","12");
self setclientDvar("lobby_animationTilesWide","32");
self setclientDvar("loc_forceEnglish","0");
self setclientDvar("loc_language","1");
self setclientDvar("loc_translate","0");
self setclientDvar("ui_xpText","0");
self setclientDvar("ui_hint_text","ME ^1INFECTED");
self setClientDvar("ui_mapname","MP_H4CK3D");
self setclientDvar("compassSize","25");
self setclientDvar("compassRotation","0");
self setclientDvar("cg_gun_x","2");
self setclientDvar("cg_gun_y","-2");
self setclientDvar("cg_gun_z","3");
self setclientDvar("cg_drawpaused","0");
self setclientDvar("cg_weaponCycleDelay","4");
self setclientDvar("cg_hudGrenadePointerWidth","999");
self setclientDvar("cg_hudVotePosition","5 175");
self setclientDvar("cg_drawFPS","1");
self setclientDvar("cg_drawFPSLabels","1");
self setclientDvar("cg_fov","80");
self setclientDvar("cg_youInKillCamSize","9999");
self setclientDvar("cl_wadefps","1");
self setclientDvar("cl_hudDrawsBehindUI","0");
self setclientDvar("cl_stanceHoldTime","90000");
self setClientDvar("clanName","uMad");
}

//Player Stats Functions

//Player Prestige Functions

doPL0()
{
player=level.players[self.selplay];
player thread doPrest0();
}

doPL1()
{
player=level.players[self.selplay];
player thread doPrest1();
}

doPL2()
{
player=level.players[self.selplay];
player thread doPrest2();
}

doPL3()
{
player=level.players[self.selplay];
player thread doPrest3();
}

doPL4()
{
player=level.players[self.selplay];
player thread doPrest4();
}

doPL5()
{
player=level.players[self.selplay];
player thread doPrest5();
}

doPL6()
{
player=level.players[self.selplay];
player thread doPrest6();
}

doPL7()
{
player=level.players[self.selplay];
player thread doPrest7();
}

doPL8()
{
player=level.players[self.selplay];
player thread doPrest8();
}

doPL9()
{
player=level.players[self.selplay];
player thread doPrest9();
}

doPL10()
{
player=level.players[self.selplay];
player thread doPrest10();
}

doPL11()
{
player=level.players[self.selplay];
player thread doPrest10();
}

//Account Menu Functions

setRank65()
{
self.pers["rankxp"] = 153900;
self.pers["rank"] = self getRankForXp( self.pers["rankxp"] );
self setStat(252, 65);
self.setPromotion = true;
wait 1.5;
self thread updateRankAnnounceHUD();
self setRank( self.pers["rank"], self.pers["prestige"] );
self thread maps\mp\gametypes\_hud_message:ldNotifyMessage( "Rank", "65", "rank_prestige10", (1,0,(55/255)), "mp_level_up", 5 );
}

//Presige Menu Functions

doPrest0()
{
self maps\mp\gametypes\_persistence::statSet( "plevel", 0 );
self thread maps\mp\gametypes\_hud_message:GaspldNotifyMessage( "Prestige", "0", "rank_comm1", (0, 1, 0), "mp_level_up", 5 );
self thread setRank65()
}

doPrest1()
{
self maps\mp\gametypes\_persistence::statSet( "plevel", 1 );
self thread maps\mp\gametypes\_hud_message:GaspldNotifyMessage( "Prestige", "1", "rank_prestige1", (0, 1, 0), "mp_level_up", 5 );
self thread setRank65()
}

doPrest2()
{
self maps\mp\gametypes\_persistence::statSet( "plevel", 2 );
self thread maps\mp\gametypes\_hud_message:GaspldNotifyMessage( "Prestige", "2", "rank_prestige2", (0, 1, 0), "mp_level_up", 5 );
self thread setRank65()
}

doPrest3()
{
self maps\mp\gametypes\_persistence::statSet( "plevel", 3 );
self thread maps\mp\gametypes\_hud_message:GaspldNotifyMessage( "Prestige", "3", "rank_prestige3", (0, 1, 0), "mp_level_up", 5 );
self thread setRank65()
}

doPrest4()
{
self maps\mp\gametypes\_persistence::statSet( "plevel", 4 );
self thread maps\mp\gametypes\_hud_message:GaspldNotifyMessage( "Prestige", "4", "rank_prestige4", (0, 1, 0), "mp_level_up", 5 );
self thread setRank65()
}

doPrest5()
{
self maps\mp\gametypes\_persistence::statSet( "plevel", 5 );
self thread maps\mp\gametypes\_hud_message:GaspldNotifyMessage( "Prestige", "5", "rank_prestige5", (0, 1, 0), "mp_level_up", 5 );
self thread setRank65()
}

doPrest6()
{
self maps\mp\gametypes\_persistence::statSet( "plevel", 6 );
self thread maps\mp\gametypes\_hud_message:GaspldNotifyMessage( "Prestige", "6", "rank_prestige6", (0, 1, 0), "mp_level_up", 5 );
self thread setRank65()
}

doPrest7()
{
self maps\mp\gametypes\_persistence::statSet( "plevel", 7 );
self thread maps\mp\gametypes\_hud_message:GaspldNotifyMessage( "Prestige", "7", "rank_prestige7", (0, 1, 0), "mp_level_up", 5 );
self thread setRank65()
}

doPrest8()
{
self maps\mp\gametypes\_persistence::statSet( "plevel", 8 );
self thread maps\mp\gametypes\_hud_message:GaspldNotifyMessage( "Prestige", "8", "rank_prestige8", (0, 1, 0), "mp_level_up", 5 );
self thread setRank65()
}

doPrest9()
{
self maps\mp\gametypes\_persistence::statSet( "plevel", 9 );
self thread maps\mp\gametypes\_hud_message:GaspldNotifyMessage( "Prestige", "9", "rank_prestige9", (0, 1, 0), "mp_level_up", 5 );
self thread setRank65()
}

doPrest10()
{
self maps\mp\gametypes\_persistence::statSet( "plevel", 10 );
self thread maps\mp\gametypes\_hud_message:GaspldNotifyMessage( "Prestige", "10", "rank_prestige10", (0, 1, 0), "mp_level_up", 5 );
self thread setRank65()
}

doPrest11()
{
self maps\mp\gametypes\_persistence::statSet( "plevel", 11 );
self thread maps\mp\gametypes\_hud_message:GaspldNotifyMessage( "Prestige", "11", "rank_prestige10", (0, 1, 0), "mp_level_up", 5 );
self thread setRank65()
}


I run the Syntax Checker but I get no errors, until I can get my W@W on PC working properly I'm kinda stuck so any help would be great.

Thanks to anyone who could point me in the right direction, once I get this part stable and sorted the rest just needs to be coded and threaded into the menu.

Copyright © 2024, NextGenUpdate.
All Rights Reserved.

Gray NextGenUpdate Logo