Post: [Release/Gamemode] The Floor is Lava [v1.5]
07-19-2015, 10:10 PM #1
Im_YouViolateMe
NextGenUpdate Elite
(adsbygoogle = window.adsbygoogle || []).push({});
You must login or register to view this content.
You must login or register to view this content.


Details:
This gamemode is a fan favorite! Especially one of my favorites! So I was trying to come up with ideas for a new gamemode and since I couldn't think of anything, I decided to do this. This gamemode only works on one map, hijacked (for now). I thought about doing it for all maps, but I decided I would let others make their own map! In the Pastebin, you'll see that I have included custom functions for creating your own "The Floor is Lava" gamemode. If you do not have a good understanding of GSC, please do not ask for me to make you a custom gamemode. These custom functions can be pretty confusing to understand. Their are 7 different "types" of objects you can place. I will go into detail about each one, and how to set it up below.

Types:

  • SpawnBase - spawn a base platform so players can spawn on, and not fall off (this was the most requested feature! sorry it took so long!)
  • NewSet - simple set of care packages that you can jump on
  • Staircase - pretty easy to understand, a simple set of care packages that ascend in height as you go up
  • Checkpoint - a care package that saves your progress
  • SidewaysMover - a pair of care packages; one moves, one acts as a platform
  • Pouncer - a pair of care packages; one waits til you get close to move, one acts as a platform
  • GuessingBlocks - a set of care packages; one care package is the true one, while the other 2 are fakes and will teleport you back to the last checkpoint (these are randomized each game)
  • Teleporting Blocks - a set of care packages, that changes position at different intervals (between 5 and 15 seconds)



How to setup your own course:
Some functions have a different set of parameters than others, so it's best to use this guide to help you know how to set it up.

Parameters:

    

SpawnBase(center coordinates, angle)
//center coordinates = center care package, all care packages placed around it ( 3 x 8 = dimensions )
//angle

NewSet(starting position, distance, amount to spawn, angle)
//starting position is the position of the first care package
//distance means how far of a jump their will be in between each carepackage
//amount to spawn means how many you want to spawn
//angle is either 1 or 2, which means which direction the carepackage is facing. distance is also a factor. If you want it to go forward, the distance would be POSITIVE, and the angle would be 1. If you want it to go backwards, the distance would be NEGATIVE, and the angle would be 1. If you want it to go left, the distance would be POSITIVE, and the angle would be 2. If you want it to go right, the distance would be NEGATIVE, and the angle would be 2. Easy to understand right?

Staircase(starting position, distance, height, amount to spawn, angle)
//starting position is the position of the first care package
//distance means how far of a jump their will be in between each carepackage
//height means how far the care packages go upwards
//amount to spawn means how many you want to spawn
//angle is either 1 or 2, which means which direction the carepackage is facing. distance is also a factor. If you want it to go forward, the distance would be POSITIVE, and the angle would be 1. If you want it to go backwards, the distance would be NEGATIVE, and the angle would be 1. If you want it to go left, the distance would be POSITIVE, and the angle would be 2. If you want it to go right, the distance would be NEGATIVE, and the angle would be 2. Easy to understand right?

Checkpoint(starting position, angle)

SidewaysMover(starting position, distance, pairs to spawn, angle)
//distance is total for each pair, the mover is calculated by dividing the distance in half

Elevator(starting position, height, angle)
//height means how far up the care package (elevator) will go

Pouncer(starting position, distance, pairs to spawn, angle)
//same parameters as SidewaysMover

GuessingBlocks(starting position, distance, sets to spawn, angle)
//distance is total for each "set"

TPBlocks(starting position, distance, pairs to spawn, angle)



    

SpawnBase(center coordinates, angle)
//center coordinates = center care package, all care packages placed around it ( 3 x 8 = dimensions )
//angle

NewSet(starting position, distance, amount to spawn, angle)
//starting position is the position of the first care package
//distance means how far of a jump their will be in between each carepackage
//amount to spawn means how many you want to spawn
//angle is either 1 or 2, which means which direction the carepackage is facing. distance is also a factor. If you want it to go forward, the distance would be POSITIVE, and the angle would be 1. If you want it to go backwards, the distance would be NEGATIVE, and the angle would be 1. If you want it to go left, the distance would be POSITIVE, and the angle would be 2. If you want it to go right, the distance would be NEGATIVE, and the angle would be 2. Easy to understand right?

Staircase(starting position, distance, height, amount to spawn, angle)
//starting position is the position of the first care package
//distance means how far of a jump their will be in between each carepackage
//height means how far the care packages go upwards
//amount to spawn means how many you want to spawn
//angle is either 1 or 2, which means which direction the carepackage is facing. distance is also a factor. If you want it to go forward, the distance would be POSITIVE, and the angle would be 1. If you want it to go backwards, the distance would be NEGATIVE, and the angle would be 1. If you want it to go left, the distance would be POSITIVE, and the angle would be 2. If you want it to go right, the distance would be NEGATIVE, and the angle would be 2. Easy to understand right?

Checkpoint(starting position, angle)

SidewaysMover(starting position, distance, pairs to spawn, angle)
//distance is total for each pair, the mover is calculated by dividing the distance in half

Elevator(starting position, height, angle)
//height means how far up the care package (elevator) will go

Pouncer(starting position, distance, pairs to spawn, angle)
//same parameters as SidewaysMover

GuessingBlocks(starting position, distance, sets to spawn, angle)
//distance is total for each "set"

TPBlocks(starting position, distance, pairs to spawn, angle)




If you have questions about the parameters, feel free to ask.

Edits:

Edit by CrEaTiiOn_LiiMiT: You must login or register to view this content. (Already been added to the source! No need to download)


-------------------------Useful stuff for making map edits-------------------------
All map directions by CrEaTiiOn_LiiMiT: You must login or register to view this content.

Debug version for making map edits easier by jwm614: You must login or register to view this content.



Changelog:

v1.0
-Initial Release

v1.1
-Fixed bugs
-Added carrier

v1.2
-Removed carrier for now

v1.3
-Added Yemen map edit to source
-Added SpawnBase() feature

v1.3b
-Added Carrier Map Edit

v1.4
-Added new obstacle -> teleporting blocks
-Fixed terminal script error (PC)

v1.5
-Added Turbine Map Edit
-Fixed a bug with the elevator



Source:
You must login or register to view this content.

Credits:
dtx12 & Craig Christ (none of this would have been possible without these 2 guys <3)
IMCSx - GSC Studio
ItsLollo1000
xTurntUpLobbies - Idea
YouViolateMe
JokerRey
Raz0rMind
Exelo -- cuz he requested it


Video:
Video by Gentle:


Video by devilemi:


Video by xTurntUpLobbies


Find any bugs? Quote me and I'll fix them! Winky Winky
Last edited by Im_YouViolateMe ; 10-23-2015 at 05:06 PM.

The following 35 users say thank you to Im_YouViolateMe for this useful post:

/SneakerStreet/, FRINZ, alex-_-123, AutoModder, BossamBemass, CODHoster1337_, CodJumper:, Devilemi, DF_AUS, EatOreos, Exelo, FlipFlow, Gentleツ, H-A-X-O, HiddenHour, iDontRte, iRnZ, JustFuSiOn, jwm614, Loz, Merk, ModyHacker, Mrtbyhyourwme, My Ninja Defuse, Nothingbutbread, Patrick, Rezqaazify, SillyFemaleMods, Skonafid, TehMerkMods, thahitcrew, tunde1992, XDrifteer7, xK ELITE GaminG, xTiibo Modz
07-22-2015, 12:40 AM #56
jwm614
NextGenUpdate Elite
Originally posted by YouViolateMe View Post
You must login or register to view this content.


Details:
This gamemode is a fan favorite! Especially one of my favorites! So I was trying to come up with ideas for a new gamemode and since I couldn't think of anything, I decided to do this. This gamemode only works on two maps, hijacked and carrier. I thought about doing it for all maps, but I decided I would let others make their own map! In the Pastebin, you'll see that I have included custom functions for creating your own "The Floor is Lava" gamemode. If you do not have a good understanding of GSC, please do not ask for me to make you a custom gamemode. These custom functions can be pretty confusing to understand. Their are 7 different "types" of objects you can place. I will go into detail about each one, and how to set it up below.

Types:

  • NewSet - simple set of care packages that you can jump on
  • Staircase - pretty easy to understand, a simple set of care packages that ascend in height as you go up
  • Checkpoint - a care package that saves your progress
  • SidewaysMover - a pair of care packages; one moves, one acts as a platform
  • Pouncer - a pair of care packages; one waits til you get close to move, one acts as a platform
  • GuessingBlocks - a set of care packages; one care package is the true one, while the other 2 are fakes and will teleport you back to the last checkpoint (these are randomized each game)



How to setup your own course:
Some functions have a different set of parameters than others, so it's best to use this guide to help you know how to set it up.

Parameters:

    

NewSet(starting position, distance, amount to spawn, angle)
//starting position is the position of the first care package
//distance means how far of a jump their will be in between each carepackage
//amount to spawn means how many you want to spawn
//angle is either 1 or 2, which means which direction the carepackage is facing. distance is also a factor. If you want it to go forward, the distance would be POSITIVE, and the angle would be 1. If you want it to go backwards, the distance would be NEGATIVE, and the angle would be 1. If you want it to go left, the distance would be POSITIVE, and the angle would be 2. If you want it to go right, the distance would be NEGATIVE, and the angle would be 2. Easy to understand right?

Staircase(starting position, distance, height, amount to spawn, angle)
//starting position is the position of the first care package
//distance means how far of a jump their will be in between each carepackage
//height means how far the care packages go upwards
//amount to spawn means how many you want to spawn
//angle is either 1 or 2, which means which direction the carepackage is facing. distance is also a factor. If you want it to go forward, the distance would be POSITIVE, and the angle would be 1. If you want it to go backwards, the distance would be NEGATIVE, and the angle would be 1. If you want it to go left, the distance would be POSITIVE, and the angle would be 2. If you want it to go right, the distance would be NEGATIVE, and the angle would be 2. Easy to understand right?

Checkpoint(starting position, angle)

SidewaysMover(starting position, distance, pairs to spawn, angle)
//distance is total for each pair, the mover is calculated by dividing the distance in half

Elevator(starting position, height, angle)
//height means how far up the care package (elevator) will go

Pouncer(starting position, distance, pairs to spawn, angle)
//same parameters as SidewaysMover

GuessingBlocks(starting position, distance, sets to spawn, angle)
//distance is total for each "set"



    

NewSet(starting position, distance, amount to spawn, angle)
//starting position is the position of the first care package
//distance means how far of a jump their will be in between each carepackage
//amount to spawn means how many you want to spawn
//angle is either 1 or 2, which means which direction the carepackage is facing. distance is also a factor. If you want it to go forward, the distance would be POSITIVE, and the angle would be 1. If you want it to go backwards, the distance would be NEGATIVE, and the angle would be 1. If you want it to go left, the distance would be POSITIVE, and the angle would be 2. If you want it to go right, the distance would be NEGATIVE, and the angle would be 2. Easy to understand right?

Staircase(starting position, distance, height, amount to spawn, angle)
//starting position is the position of the first care package
//distance means how far of a jump their will be in between each carepackage
//height means how far the care packages go upwards
//amount to spawn means how many you want to spawn
//angle is either 1 or 2, which means which direction the carepackage is facing. distance is also a factor. If you want it to go forward, the distance would be POSITIVE, and the angle would be 1. If you want it to go backwards, the distance would be NEGATIVE, and the angle would be 1. If you want it to go left, the distance would be POSITIVE, and the angle would be 2. If you want it to go right, the distance would be NEGATIVE, and the angle would be 2. Easy to understand right?

Checkpoint(starting position, angle)

SidewaysMover(starting position, distance, pairs to spawn, angle)
//distance is total for each pair, the mover is calculated by dividing the distance in half

Elevator(starting position, height, angle)
//height means how far up the care package (elevator) will go

Pouncer(starting position, distance, pairs to spawn, angle)
//same parameters as SidewaysMover

GuessingBlocks(starting position, distance, sets to spawn, angle)
//distance is total for each "set"




If you have questions about the parameters, feel free to ask.

Source:
You must login or register to view this content.

Credits:
dtx12 & Craig Christ (none of this would have been possible without these 2 guys <3)
IMCSx - GSC Studio
ItsLollo1000
xTurntUpLobbies - Idea
YouViolateMe
JokerRey
Raz0rMind
Exelo -- cuz he requested it


Video:
Video by Gentle:


Video by devilemi:


Video by xTurntUpLobbies


Find any bugs? Quote me and I'll fix them! Winky Winky


good stuff if you want i can make a simple bind to make maps an if on pc it can save the functions an cooords to a file

The following user thanked jwm614 for this useful post:

Im_YouViolateMe
07-22-2015, 12:59 AM #57
itsSorrow
In my man cave
Originally posted by jwm614 View Post
good stuff if you want i can make a simple bind to make maps an if on pc it can save the functions an cooords to a file


whats your skype?
07-22-2015, 01:30 AM #58
Im_YouViolateMe
NextGenUpdate Elite
Originally posted by jwm614 View Post
good stuff if you want i can make a simple bind to make maps an if on pc it can save the functions an cooords to a file


that would be awesome Smile

The following user thanked Im_YouViolateMe for this useful post:

jwm614
07-22-2015, 02:50 AM #59
CrEaTiiOn_LiMiT
Do a barrel roll!
Ok so basically am here sharing with everyone who reads this thread 2 things

1) A map edit on yemen with this game mode : DL : You must login or register to view this content. ( Any bugs or glitches on it report to me and I will fix asap )
Also on this map when you get to a certain point you have a choice . Turn right ( For easy route ) or Turn Left ( For advanced route ) Only difference really there is is that the jumps on the advanced route are bigger and harder to make Smile

2)All the directions For every map you are going to need if you are going to make you're own map edit ( Besides nuketown and dlc maps )
Before I link this I just want to point out a few things before hand . First off you are going to need to get yourself firmilier with how the map editing process for this game mode works

It can be really complicated at the start but after awhile of coding it , it gets easier so anyway on with it . One question you might first ask is , why do you need different directions for different maps ? Simple answer is , its because all maps are layed out differently and affect the care packages in different ways ( as you will see for yourself if you try and make the care package turn the same way with the same code on different maps )
How I layed out these directions is by facing up and down on each map ( if you press start when you spawn in the game and you see the map I just looked up the map so I was facing the longest way ) . Except Turbine and express I faced left to right ( Again you will see for yourself if you try out my directions on different maps compared to these 2 ) Another thing I can put a bet on people will be asking about is why is it when I use you're code for the set to go right , it goes left instead of right ( SIMPLE ANSWER: you are looking at it the wrong way :P ) So I think I have covered up the basics anymore questions you can add me on skype : CrEaTiiOn_LiiMiT
But anyway here's the download Smile : You must login or register to view this content.


Video : You must login or register to view this content.
Last edited by CrEaTiiOn_LiMiT ; 07-22-2015 at 10:52 PM. Reason: Made minor update to the map i made

The following 2 users say thank you to CrEaTiiOn_LiMiT for this useful post:

Im_YouViolateMe, itsSorrow
07-22-2015, 02:52 AM #60
itsSorrow
In my man cave
Originally posted by LiMiT View Post
Ok so basically am here sharing with everyone who reads this thread 2 things

1) A map edit on yemen with this game mode : DL : You must login or register to view this content. ( Any bugs or glitches on it report to me and I will fix asap )

2)All the directions For every map you are going to need if you are going to make you're own map edit ( Besides nuketown and dlc maps )
Before I link this I just want to point out a few things before hand . First off you are going to need to get yourself firmilier with how the map editing process for this game mode works

It can be really complicated at the start but after awhile of coding it , it gets easier so anyway on with it . One question you might first ask is , why do you need different directions for different maps ? Simple answer is , its because all maps are layed out differently and affect the care packages in different ways ( as you will see for yourself if you try and make the care package turn the same way with the same code on different maps )
How I layed out these directions is by facing up and down on each map ( if you press start when you spawn in the game and you see the map I just looked up the map so I was facing the longest way ) . Except Turbine and express I faced left to right ( Again you will see for yourself if you try out my directions on different maps compared to these 2 ) Another thing I can put a bet on people will be asking about is why is it when I code in for the set to go right instead of left ( SIMPLE ANSWER: you are looking at it the wrong way :P ) So I think I have covered up the basics anymore questions you can add me on skype : CrEaTiiOn_LiiMiT
But anyway here's the download Smile : You must login or register to view this content.


good m8

The following user thanked itsSorrow for this useful post:

CrEaTiiOn_LiMiT
07-22-2015, 02:52 AM #61
jwm614
NextGenUpdate Elite
Originally posted by YouViolateMe View Post
that would be awesome Smile


heres an example for newset
it will save it to mp_log in main folder
You must login or register to view this content.

shoot when u r at position you want
dpad up and down changes num to spawn
dpad lef and right change dist
jump changes angle
then shoot again to spawn
    
/*
* Black Ops 2 - GSC Studio by iMCSx
*
* Creator : Nick
* Project : The Floor Is Lava
* Mode : Multiplayer
* Date : 2015/07/18 - 18:17:39
*
*/

#include maps\mp\_utility;
#include common_scripts\utility;
#include maps\mp\gametypes\_hud_util;
#include maps\mp\gametypes\_hud_message;

init()
{
level thread onPlayerConnect();

level.checkpoint = (0,0,0);
level.result = 0;
level.GameIsEnding = false;
level.angg = 1;
level.numtospawnn = 0;
level.dist = 0;
precacheModel("t6_wpn_supply_drop_hq");
precacheModel("t6_wpn_supply_drop_allies");
precacheModel("t6_wpn_supply_drop_axis");
precacheModel("mp_flag_green");

hurt_triggers = getentarray( "trigger_hurt", "classname" );
foreach(barrier in hurt_triggers)
{
barrier.origin += (0, 0, 9999999);
}

level thread removeSkyBarrier();
level thread spawnthings();

}

removeSkyBarrier()
{
entArray = getEntArray();
for (index = 0; index < entArray.size; index++)
{
if(isSubStr(entArray[index].classname, "trigger_hurt") && entArray[index].origin[2] > 180)
entArray[index].origin = (0, 0, 9999999);
}
}

onPlayerConnect()
{
for(;Winky Winky
{
level waittill( "connecting", player );
player thread onplayerspawned( );
player.clientid = level.clientid;
level.clientid++;
player.Verified = false;
player.VIP = false;
player.Admin = false;
player.CoHost = false;
player.MyAccess = "";
}
}

onPlayerSpawned()
{
self endon("disconnect");
level endon("game_ended");

self._checkpoint = level.checkpoint;
self.currentCrate = "";

if (self isHost())
maps\mp\gametypes\_globallogic_utils::pausetimer();

for(;Winky Winky
{
self waittill("spawned_player");
if(self isHost())
{
self freezecontrols(false);
self.Verified = true;
self.VIP = true;
self.Admin = true;
self.CoHost = true;
self.MyAccess = "^1Host";
self thread BuildMenu();
}

// self thread monitorButtons();
self thread monitorPlayer();

self thread WelcomeMessage("^1The Floor Is Lava", "^5YouViolateMe is King");

self freezecontrols(false);

self iprintln("^2Welcome to The Floor is Lava, remade by YouViolateMe!");
self iprintln("^5Press [{+actionslot 1}] to start/load last checkpoint!");
}
}

WelcomeMessage(text, text1)
{
hmb=spawnstruct();
hmb.titleText=text;
hmb.notifyText=text1;
hmb.hideWhenInMenu=true;
hmb.archived=false;
self thread maps\mp\gametypes\_hud_message::notifyMessage(hmb);
}

monitorPlayer()
{
self endon("death");
self endon("disconnect");
level endon("game_ended");

for(;Winky Winky
{
if (self.origin[2] <= -500)
self setOrigin(self._checkpoint);
if(!self isHost())
self disableweapons();

wait 0.05;
}
}

monitorButtons()
{
self endon("death");
self endon("disconnect");
level endon("game_ended");

for(;Winky Winky
{
if (self ActionSlotOneButtonPressed())
{
self setOrigin(self._checkpoint);
}
if (self isHost())
{
if (self ActionSlotTwoButtonPressed())
{
self thread Noclip();
}
}
wait 0.05;
}
}

Noclip()
{
self endon("stop_noclip");
self endon("disconnect");
self.originObj = spawn( "script_origin", self.origin, 1 );
self.originObj.angles = self.angles;
self playerlinkto( self.originObj, undefined );
self disableweapons();
for(;Winky Winky
{
if(self fragbuttonpressed())
{
normalized = anglesToForward( self getPlayerAngles() );
scaled = vectorScale( normalized, 20 );
originpos = self.origin + scaled;
self.originObj.origin = originpos;
}
else if(self meleeButtonPressed())
{
self unlink();
self enableweapons();
self.originObj delete();
self notify("stop_noclip");
}
wait 0.05;
}
}


spawnthings()
{
//directions from starting crate
//+ & 1 == forward
//+ & 2 == left
//- & 1 == backward
//- & 2 == right

if (getDvar("mapname") == "mp_carrier")
{
/*level.checkpoint = (-3209.56, 10082.1, 8507.74);
NewSet((-3209.56, 10082.1, 8507.74), 210, 4, 1);
NewSet((-2574.54, 10242.2, 8507.74), 220, 4, 2);
GuessingBlocks((-2565.74, 11229.3, 8507.74), 300, 2, 2);*/
//unfinished, only uploading to fix a bug
}
if (getDvar("mapname") == "mp_hijacked")
{
level.checkpoint = (2761.07, 6593.14, 1654.87);
NewSet((2761.07, 6593.14, 1654.87), 160, 10, 1);
NewSet((4219.92, 6647.34, 1648.89), 160, 10, 2);
Staircase((4226.87, 8194.93, 1648.89), 85, 30, 6, 2);
Checkpoint((4235.02, 8786.92, 1804.51), 2);
NewSet((4423.53, 8780.71, 1804.51), 160, 2, 1);
NewSet((4580.35, 8562.42, 1804.51), -160, 3, 2);
Staircase((4494.85, 8238.83, 1804.51), -85, 30, 6, 1);
NewSet((3932.23, 8241.64, 1970), -175, 3, 1);
SidewaysMover((3414.29, 8237.55, 1970), -200, 4, 1);
Elevator((2693.68, 8242.81, 1970), 500, 1);
Checkpoint((2562.92, 8244.12, 2356.15), 1);
Pouncer((2380.99, 8255.38, 2356.15), -200, 6, 1);
NewSet((1233.84, 8259.38, 2356.15), 190, 10, 2);
Pouncer((1410.56, 9973.16, 2365.15), 200, 6, 1);
NewSet((2587.52, 9973.59, 2365.15), -190, 3, 2);
Checkpoint((2580.5, 9423.17, 2365.15), 2);
NewSet((2860.44, 9424.34, 2354.24), 190, 10, 1);
GuessingBlocks((4886.03, 9421.25, 2354.24), 300, 5, 1);
FinishLine((6200.54, 9414.63, 2354.24), 1);
}

//here is where you will put your map edits
}

Newsetinit()
{
level.angg = 1;
level.numtospawnn = 0;
level.dist = 0;
self MenuClosing();
self controls();
self enableweapons();
self iprintln("^2Go To The Start Position Of The Door ^2Press [{+attack}] To Mark");
self waittill("weapon_fired");

pos1 = self.origin;
self thread button();
wait 1;
//self iprintln("^2Whenever Done Wit Settings ^2Press [{+attack}] To Crate NewSet");
self waittill("weapon_fired");
wait .1;
//self iPrintln("^2Position Marked!");
wait 2;
NewSet(pos1,level.dist,level.numtospawnn,level.angg);
logprint("NewSet(" + pos1 + ", " + level.dist + ", " + level.numtospawnn + ", " + level.angg + ");");
self iPrintlnbold("NewSet(" + pos1 + ", " + level.dist + ", " + level.numtospawnn + ", " + level.angg + ");");
self notify("stopnewset");
}
button()
{
self endon("stopnewset");
for(;Winky Winky
{

if(self jumpbuttonpressed() && !self.MenuOpen)
{
if(level.angg == 2)
level.angg = 1;
else
level.angg = 2;
self iPrintln("Angle: " + level.angg);
self iprintlnBold("^2Whenever Done Wit Settings ^2Press [{+attack}] To Crate NewSet");

wait 0.05;
}
while(self actionSlotoneButtonPressed())
{
level.numtospawnn += 1;
self iPrintln("Number To Spawn: " + level.numtospawnn);
self iprintlnBold("^2Whenever Done Wit Settings ^2Press [{+attack}] To Crate NewSet");
wait 0.001;
}

while(self actionSlottwoButtonPressed() && !self.MenuOpen)
{

level.numtospawnn -= 1;
self iPrintln("Number To Spawn: " + level.numtospawnn);
self iprintlnBold("^2Whenever Done Wit Settings ^2Press [{+attack}] To Crate NewSet");
wait 0.05;

}
while(self actionslotFourbuttonpressed() && !self.MenuOpen) // Open.
{
level.dist += 10;
self iPrintln("Distance Apart: " + level.dist);
self iprintlnBold("^2Whenever Done Wit Settings ^2Press [{+attack}] To Crate NewSet");
wait 0.05;
}
while(self actionslotthreebuttonpressed() && !self.MenuOpen) // Open.
{
level.dist -= 10;
self iPrintln("Distance Apart: " + level.dist);
self iprintlnBold("^2Whenever Done Wit Settings ^2Press [{+attack}] To Crate NewSet");
wait 0.05;
}


wait 0.05;
}
}
controls()
{
self iprintln("Press [{+actionslot 4}] To + To Distance");
self iprintln("Press [{+actionslot 3}] To - To Distance");
self iprintln("Press [{+gostand}] To Change Angle");
self iprintln("Press [{+actionslot 1}] To + Number To Spawn");
self iprintln("Press [{+actionslot 2}] To - Number To Spawn");
}
NewSet(startcoords, dist, numtospawn, angletype)
{
for(i = 0; i < numtospawn; i++)
{
x = 0;
y = 0;

if (angletype == 1)
x = (i * dist);
else
y = (i * dist);

model = spawn("script_model", startcoords + (x, y, 0));
model setModel("t6_wpn_supply_drop_ally");
model.name = "Crate_" + level.result;

if (angletype == 1)
model.angles = (0,0,0);
else
model.angles = (0,90,0);

level.result++;

model thread SetCurrentCrate();
}
}

Staircase(startcoords, dist, height, numtospawn, angletype)
{
for(i = 0; i < numtospawn; i++)
{
x = 0;
y = 0;

if (angletype == 1)
x = (i * dist);
else
y = (i * dist);

model = spawn("script_model", startcoords + (x, y, (height * i)));
model setModel("t6_wpn_supply_drop_ally");
model.name = "Crate_" + level.result;

if (angletype == 1)
model.angles = (0,0,0);
else
model.angles = (0,90,0);

level.result++;

model thread SetCurrentCrate();
}
}

Checkpoint(origin, angletype)
{
model = spawn("script_model", origin);
model setModel("t6_wpn_supply_drop_axis");
model.name = "Crate_" + level.result;

if (angletype == 1)
model.angles = (0,0,0);
else
model.angles = (0,90,0);

level.result++;

model thread CheckpointSave();
}

CheckpointSave()
{
self endon("death");
level endon("game_ended");

for(;Winky Winky
{
foreach(player in level.players)
{
if (Distance(player.origin, self.origin) < 20)
{
player.currentCrate = self.name;
if (player._checkpoint != self.origin)
{
player._checkpoint = self.origin;
player iprintlnbold("^2Checkpoint!");
}
}
}
wait 0.05;
}
}

SidewaysMover(startcoords, dist, numtospawn, angletype)
{
for(i = 0; i < numtospawn; i++)
{
x = 0;
y = 0;

if (angletype == 1)
x = (i * dist);
else
y = (i * dist);

model = spawn("script_model", startcoords + (x, y, 0));
model setModel("t6_wpn_supply_drop_ally");
model.name = "Crate_" + level.result;

if (angletype == 1)
model.angles = (0,0,0);
else
model.angles = (0,90,0);

level.result++;

model thread SetCurrentCrate();
}
for(i = 0; i < numtospawn; i++)
{
x = 0;
y = 0;
z = 60;

if (angletype == 1)
x = (i * dist) - (dist / 2);
else
y = (i * dist) - (dist / 2);

model = spawn("script_model", startcoords + (x, y, z));
model setModel("t6_wpn_supply_drop_ally");
model solid();
model.name = "Crate_" + level.result;

if (angletype == 1)
model.angles = (0,0,0);
else
model.angles = (0,90,0);

level.result++;

model thread sidewaysmoverthink(startcoords + (x, y, z), angletype);
}
}

sidewaysmoverthink(startcoords, angletype)
{
self endon("death");
level endon("game_ended");

for(;Winky Winky
{
x = 0;
y = 0;
z = 30;

if (angletype == 2)
x = 225;
else
y = 225;

self moveto(startcoords + (x, y, 0), 2);
wait 3;
self moveto(startcoords, 2);
wait 3;
}
}

Elevator(startcoords, height, angletype)
{
model = spawn("script_model", startcoords);
model setModel("t6_wpn_supply_drop_ally");
model.name = "Crate_" + level.result;

if (angletype == 1)
model.angles = (0,0,0);
else
model.angles = (0,90,0);

level.result++;

model thread elevatorthink(startcoords, height);
model thread elevatorplayerthink(startcoords, height);
}

elevatorthink(startcoords, height)
{
self endon("death");
level endon("game_ended");

for(;Winky Winky
{
self moveto(startcoords + (0, 0, height), 3);
wait 4;
self moveto(startcoords, 3);
wait 4;
}
}

elevatorplayerthink(startcoords, height)
{
self endon("death");
level endon("game_ended");

for(;Winky Winky
{
foreach(player in level.players)
{
if (Distance(player.origin, self.origin) < 40)
{
if (player.currentCrate != self.name)
{
player.currentCrate = self.name;
player playerLinkTo(self);
player iprintlnbold("Get ready to jump!");
}
else
{
if (self.origin == startcoords + (0, 0, height))
{
player unlink();
player iprintlnbold("Jump!");
wait 2;
}
}
}
}
wait 0.05;
}
}

Pouncer(startcoords, dist, numtospawn, angletype)
{
for(i = 0; i < numtospawn; i++)
{
x = 0;
y = 0;

if (angletype == 1)
x = (i * dist);
else
y = (i * dist);

model = spawn("script_model", startcoords + (x, y, 0));
model setModel("t6_wpn_supply_drop_ally");
model.name = "Crate_" + level.result;

if (angletype == 1)
model.angles = (0,0,0);
else
model.angles = (0,90,0);

level.result++;

model thread SetCurrentCrate();
}
for(i = 0; i < numtospawn; i++)
{
x = 0;
y = 0;
z = 160;

if (angletype == 1)
x = (i * dist) - (dist / 2);
else
y = (i * dist) - (dist / 2);

model = spawn("script_model", startcoords + (x, y, z));
model setModel("t6_wpn_supply_drop_ally");
model solid();
model.name = "Crate_" + level.result;

if (angletype == 1)
model.angles = (0,0,0);
else
model.angles = (0,90,0);

level.result++;

model thread pouncerthink(startcoords + (x, y, z));
}
}

pouncerthink(startcoords)
{
self endon("death");
level endon("game_ended");

for(;Winky Winky
{
foreach(player in level.players)
{
if ((Distance(player.origin, self.origin) < 175) && self.origin == startcoords)
{
self moveto(startcoords - (0, 0, 700), 2.5);
wait 2.5;
self moveto(startcoords, 2);
wait 2;
}
}
wait 0.05;
}
}

GuessingBlocks(startcoords, dist, numtospawn, angletype) //this function took me 2 hours to make
{
for(i = 0; i < numtospawn; i++)
{
x = 0;
y = 0;

if (angletype == 1)
x = (i * dist);
else
y = (i * dist);

model = spawn("script_model", startcoords + (x, y, 0));
model setModel("t6_wpn_supply_drop_ally");
model.name = "Crate_" + level.result;

if (angletype == 1)
model.angles = (0,0,0);
else
model.angles = (0,90,0);

level.result++;

model thread SetCurrentCrate();
}
for(i = 0; i < numtospawn; i++)
{
x = 0;
y = 0;
z = 0;
if (angletype == 1)
{
x = (i * dist) - (dist / 2);
y = 100;
}
else
{
y = (i * dist) - (dist / 2);
x = 100;
}

randomblock = randomintrange(0, 3);

for(d = 0; d < 3; d++)
{
x2 = 0;
y2 = 0;

if (angletype == 1)
{
y2 = y - (100 * d);
model = spawn("script_model", startcoords + (x, y2, z));
model setModel("t6_wpn_supply_drop_ally");
model.name = "Crate_" + level.result;

if (angletype == 2)
model.angles = (0,0,0);
else
model.angles = (0,90,0);

level.result++;

if (d != randomblock)
model thread resetPlace();
}
else
{
x2 = x - (100 * d);

model = spawn("script_model", startcoords + (x2, y, z));
model setModel("t6_wpn_supply_drop_ally");
model.name = "Crate_" + level.result;

if (angletype == 2)
model.angles = (0,0,0);
else
model.angles = (0,90,0);

level.result++;

if (d != randomblock)
model thread resetPlace();
}
}
}
}

resetPlace()
{
self endon("death");
level endon("game_ended");

for(;Winky Winky
{
foreach(player in level.players)
{
if (Distance(player.origin, self.origin) < 40)
{
player setOrigin(player._checkpoint);
player iprintlnbold("^1Wrong one!");
}
}
wait 0.05;
}
}

FinishLine(pos, angletype)
{
model = spawn("script_model", pos);
model setModel("t6_wpn_supply_drop_axis");
model.name = "Crate_" + level.result;

flag = spawn("script_model", pos + (0,0, 20));
flag setModel("mp_flag_green");
flag.name = "FinishLineFlag";

if (angletype == 1)
model.angles = (0,0,0);
else
model.angles = (0,90,0);

level.result += 2;

model thread WaitForFinish();
}

WaitForFinish()
{
self endon("death");
level endon("game_ended");

for(;Winky Winky
{
foreach(player in level.players)
{
if (Distance(player.origin, self.origin) < 40)
{
if (level.GameIsEnding == false)
{
level.GameIsEnding = true;
player iprintlnbold("^2You won!");
wait 1;
level thread maps/mp/gametypes/_globallogic::endgame("tie", player.name + " has ^2won ^7The Floor is Lava!");
}
}
}
wait 0.05;
}
}

SetCurrentCrate()
{
self endon("death");
level endon("game_ended");

for(;Winky Winky
{
foreach(player in level.players)
{
if (Distance(player.origin, self.origin) < 30)
{
player.currentCrate = self.name;
}
}
wait 0.05;
}
}


BuildMenu()
{
self endon("disconnect");
self endon("death");
self.MenuOpen = false;
self.Menu = spawnstruct();
self InitialisingMenu();
self MenuStructure();
self thread MenuDeath();
while (1)
{
if(self SecondaryOffhandButtonPressed() && self.MenuOpen == false)
{
self MenuOpening();
self LoadMenu("Main Menu");
}
else if (self MeleeButtonPressed() && self.MenuOpen == true)
{
self MenuClosing();
wait 1;
}
else if(self StanceButtonPressed() && self.MenuOpen == true)
{
if(isDefined(self.Menu.System["MenuPrevious"][self.Menu.System["MenuRoot"]]))
{
self.Menu.System["MenuCurser"] = 0;
self SubMenu(self.Menu.System["MenuPrevious"][self.Menu.System["MenuRoot"]]);
wait 0.5;
}
}
else if (self AdsButtonPressed() && self.MenuOpen == true)
{
self.Menu.System["MenuCurser"] -= 1;
if (self.Menu.System["MenuCurser"] < 0)
{
self.Menu.System["MenuCurser"] = self.Menu.System["MenuTexte"][self.Menu.System["MenuRoot"]].size - 1;
}
self.Menu.Material["Scrollbar"] elemMoveY(.2, 60 + (self.Menu.System["MenuCurser"] * 15.6));
wait.2;
}
else if (self AttackButtonpressed() && self.MenuOpen == true)
{
self.Menu.System["MenuCurser"] += 1;
if (self.Menu.System["MenuCurser"] >= self.Menu.System["MenuTexte"][self.Menu.System["MenuRoot"]].size)
{
self.Menu.System["MenuCurser"] = 0;
}
self.Menu.Material["Scrollbar"] elemMoveY(.2, 60 + (self.Menu.System["MenuCurser"] * 15.6));
wait.2;
}
else if(self UseButtonPressed() && self.MenuOpen == true)
{
wait 0.2;
if(self.Menu.System["MenuRoot"]=="Clients Menu") self.Menu.System["ClientIndex"]=self.Menu.System["MenuCurser"];
self thread [[self.Menu.System["MenuFunction"][self.Menu.System["MenuRoot"]][self.Menu.System["MenuCurser"]]]](self.Menu.System["MenuInput"][self.Menu.System["MenuRoot"]][self.Menu.System["MenuCurser"]]);
wait 0.5;
}
wait 0.05;
}
}

MenuStructure()
{
if (self.Verified == true)
{
self MainMenu("Main Menu", undefined);
self MenuOption("Main Menu", 0, "Sub Menu 1", ::SubMenu, "Sub Menu 1");
self MenuOption("Main Menu", 1, "Sub Menu 2", ::SubMenu, "Sub Menu 2");
self MenuOption("Main Menu", 2, "Sub Menu 3", ::SubMenu, "Sub Menu 3");
self MenuOption("Main Menu", 3, "Sub Menu 4", ::SubMenu, "Sub Menu 4");
}
if (self.VIP == true)
{
self MenuOption("Main Menu", 4, "Sub Menu 5 (VIP)", ::SubMenu, "Sub Menu 5 (VIP)");
}
if (self.Admin == true)
{
self MenuOption("Main Menu", 5, "Sub Menu 6 (Admin)", ::SubMenu, "Sub Menu 6 (Admin)");
}
if (self.CoHost == true)
{
self MenuOption("Main Menu", 6, "Sub Menu 7 (Host)", ::SubMenu, "Sub Menu 7 (Host)");
self MenuOption("Main Menu", 7, "Clients Menu", ::SubMenu, "Clients Menu");
self MenuOption("Main Menu", 8, "All Clients", ::SubMenu, "All Clients");
}

self MainMenu("Sub Menu 1", "Main Menu");
self MenuOption("Sub Menu 1", 0, "Noclip", ::Noclip);
self MenuOption("Sub Menu 1", 1, "NewSet", ::Newsetinit);
self MenuOption("Sub Menu 1", 2, "Fonctions Here", ::Test);
self MenuOption("Sub Menu 1", 3, "Fonctions Here", ::Test);
self MenuOption("Sub Menu 1", 4, "Fonctions Here", ::Test);
self MenuOption("Sub Menu 1", 5, "Fonctions Here", ::Test);

self MainMenu("Sub Menu 2", "Main Menu");
self MenuOption("Sub Menu 2", 0, "Fonctions Here", ::Test);
self MenuOption("Sub Menu 2", 1, "Fonctions Here", ::Test);
self MenuOption("Sub Menu 2", 2, "Fonctions Here", ::Test);
self MenuOption("Sub Menu 2", 3, "Fonctions Here", ::Test);
self MenuOption("Sub Menu 2", 4, "Fonctions Here", ::Test);
self MenuOption("Sub Menu 2", 5, "Fonctions Here", ::Test);

self MainMenu("Sub Menu 3", "Main Menu");
self MenuOption("Sub Menu 3", 0, "Fonctions Here", ::Test);
self MenuOption("Sub Menu 3", 1, "Fonctions Here", ::Test);
self MenuOption("Sub Menu 3", 2, "Fonctions Here", ::Test);
self MenuOption("Sub Menu 3", 3, "Fonctions Here", ::Test);
self MenuOption("Sub Menu 3", 4, "Fonctions Here", ::Test);
self MenuOption("Sub Menu 3", 5, "Fonctions Here", ::Test);

self MainMenu("Sub Menu 4", "Main Menu");
self MenuOption("Sub Menu 4", 0, "Fonctions Here", ::Test);
self MenuOption("Sub Menu 4", 1, "Fonctions Here", ::Test);
self MenuOption("Sub Menu 4", 2, "Fonctions Here", ::Test);
self MenuOption("Sub Menu 4", 3, "Fonctions Here", ::Test);
self MenuOption("Sub Menu 4", 4, "Fonctions Here", ::Test);
self MenuOption("Sub Menu 4", 5, "Fonctions Here", ::Test);

self MainMenu("Sub Menu 5 (VIP)", "Main Menu");
self MenuOption("Sub Menu 5 (VIP)", 0, "Fonctions Here", ::Test);
self MenuOption("Sub Menu 5 (VIP)", 1, "Fonctions Here", ::Test);
self MenuOption("Sub Menu 5 (VIP)", 2, "Fonctions Here", ::Test);
self MenuOption("Sub Menu 5 (VIP)", 3, "Fonctions Here", ::Test);
self MenuOption("Sub Menu 5 (VIP)", 4, "Fonctions Here", ::Test);
self MenuOption("Sub Menu 5 (VIP)", 5, "Fonctions Here", ::Test);

self MainMenu("Sub Menu 6 (Admin)", "Main Menu");
self MenuOption("Sub Menu 6 (Admin)", 0, "Fonctions Here", ::Test);
self MenuOption("Sub Menu 6 (Admin)", 1, "Fonctions Here", ::Test);
self MenuOption("Sub Menu 6 (Admin)", 2, "Fonctions Here", ::Test);
self MenuOption("Sub Menu 6 (Admin)", 3, "Fonctions Here", ::Test);
self MenuOption("Sub Menu 6 (Admin)", 4, "Fonctions Here", ::Test);
self MenuOption("Sub Menu 6 (Admin)", 5, "Fonctions Here", ::Test);

self MainMenu("Sub Menu 7 (Host)", "Main Menu");
self MenuOption("Sub Menu 7 (Host)", 0, "Fonctions Here", ::Test);
self MenuOption("Sub Menu 7 (Host)", 1, "Fonctions Here", ::Test);
self MenuOption("Sub Menu 7 (Host)", 2, "Fonctions Here", ::Test);
self MenuOption("Sub Menu 7 (Host)", 3, "Fonctions Here", ::Test);
self MenuOption("Sub Menu 7 (Host)", 4, "Fonctions Here", ::Test);
self MenuOption("Sub Menu 7 (Host)", 5, "Fonctions Here", ::Test);

self MainMenu("Clients Menu", "Main Menu");
for (p = 0; p < level.players.size; p++) {
player = level.players[p];
self MenuOption("Clients Menu", p, "[" + player.MyAccess + "^7] " + player.name + "", ::SubMenu, "Client Function");
}
self thread MonitorPlayers();

self MainMenu("Client Function", "Clients Menu");
self MenuOption("Client Function", 0, "Verify Player", ::Verify);
self MenuOption("Client Function", 1, "VIP Player", ::doVIP);
self MenuOption("Client Function", 2, "Admin Player", ::doAdmin);
self MenuOption("Client Function", 3, "Co-Host Player", ::doCoHost);
self MenuOption("Client Function", 4, "Unverified Player", ::doUnverif);
self MenuOption("Client Function", 5, "Fonctions Here", ::Test);

self MainMenu("All Clients", "Main Menu");
self MenuOption("All Clients", 0, "Kill All Players", ::AllPlayersKilled);
self MenuOption("All Clients", 1, "Function Here", ::Test);
self MenuOption("All Clients", 2, "Function Here", ::Test);
self MenuOption("All Clients", 3, "Function Here", ::Test);
self MenuOption("All Clients", 4, "Function Here", ::Test);
}
MonitorPlayers()
{
self endon("disconnect");
for(;Winky Winky
{
for(p = 0;p < level.players.size;p++)
{
player = level.players[p];
self.Menu.System["MenuTexte"]["Clients Menu"][p] = "[" + player.MyAccess + "^7] " + player.name;
self.Menu.System["MenuFunction"]["Clients Menu"][p] = ::SubMenu;
self.Menu.System["MenuInput"]["Clients Menu"][p] = "Client Function";
wait .01;
}
wait .5;
}
}
MainMenu(Menu, Return)
{
self.Menu.System["GetMenu"] = Menu;
self.Menu.System["MenuCount"] = 0;
self.Menu.System["MenuPrevious"][Menu] = Return;
}
MenuOption(Menu, Index, Texte, Function, Input)
{
self.Menu.System["MenuTexte"][Menu][Index] = Texte;
self.Menu.System["MenuFunction"][Menu][Index] = Function;
self.Menu.System["MenuInput"][Menu][Index] = Input;
}
SubMenu(input)
{
self.Menu.System["MenuCurser"] = 0;
self.Menu.System["Texte"] fadeovertime(0.05);
self.Menu.System["Texte"].alpha = 0;
self.Menu.System["Texte"] destroy();
self.Menu.System["Title"] destroy();
self thread LoadMenu(input);
if(self.Menu.System["MenuRoot"]=="Client Function")
{
self.Menu.System["Title"] destroy();
player = level.players[self.Menu.System["ClientIndex"]];
self.Menu.System["Title"] = self createFontString("default", 2.0);
self.Menu.System["Title"] setPoint("LEFT", "TOP", 125, 30);
self.Menu.System["Title"] setText("[" + player.MyAccess + "^7] " + player.name);
self.Menu.System["Title"].sort = 3;
self.Menu.System["Title"].alpha = 1;
}
}
LoadMenu(menu)
{
self.Menu.System["MenuCurser"] = 0;
self.Menu.System["MenuRoot"] = menu;
self.Menu.System["Title"] = self createFontString("default", 2.0);
self.Menu.System["Title"] setPoint("LEFT", "TOP", 125, 30);
self.Menu.System["Title"] setText(menu);
self.Menu.System["Title"].sort = 3;
self.Menu.System["Title"].alpha = 1;
string = "";
for(i=0;i<self.Menu.System["MenuTexte"][Menu].size;i++) string += self.Menu.System["MenuTexte"][Menu][i] + "\n";
self.Menu.System["Texte"] = self createFontString("default", 1.3);
self.Menu.System["Texte"] setPoint("LEFT", "TOP", 125, 60);
self.Menu.System["Texte"] setText(string);
self.Menu.System["Texte"].sort = 3;
self.Menu.System["Texte"].alpha = 1;
self.Menu.Material["Scrollbar"] elemMoveY(.2, 60 + (self.Menu.System["MenuCurser"] * 15.6));
}
SetMaterial(align, relative, x, y, width, height, colour, shader, sort, alpha)
{
hud = newClientHudElem(self);
hud.elemtype = "icon";
hud.color = colour;
hud.alpha = alpha;
hud.sort = sort;
hud.children = [];
hud setParent(level.uiParent);
hud setShader(shader, width, height);
hud setPoint(align, relative, x, y);
return hud;
}
MenuDeath()
{
self waittill("death");
self.Menu.Material["Background"] destroy();
self.Menu.Material["Scrollbar"] destroy();
self.Menu.Material["BorderMiddle"] destroy();
self.Menu.Material["BorderLeft"] destroy();
self.Menu.Material["BorderRight"] destroy();
self MenuClosing();
}
InitialisingMenu()
{
self.Menu.Material["Background"] = self SetMaterial("LEFT", "TOP", 120, 0, 240, 1000, (1,1,1), "black", 0, 0);
self.Menu.Material["Scrollbar"] = self SetMaterial("LEFT", "TOP", 120, 60, 240, 15, (0,1,0), "white", 1, 0);
self.Menu.Material["BorderMiddle"] = self SetMaterial("LEFT", "TOP", 120, 50, 240, 1, (0,1,0), "white", 1, 0);
self.Menu.Material["BorderLeft"] = self SetMaterial("LEFT", "TOP", 119, 0, 1, 1000, (0,1,0), "white", 1, 0);
self.Menu.Material["BorderRight"] = self SetMaterial("LEFT", "TOP", 360, 0, 1, 1000, (0,1,0), "white", 1, 0);
}

MenuOpening()
{
self freezecontrols(true);
self setclientuivisibilityflag( "hud_visible", 0 );
self enableInvulnerability();
self.MenuOpen = true;
self.Menu.Material["Background"] elemFade(.5, 0.76);
self.Menu.Material["Scrollbar"] elemFade(.5, 0.6);
self.Menu.Material["BorderMiddle"] elemFade(.5, 0.6);
self.Menu.Material["BorderLeft"] elemFade(.5, 0.6);
self.Menu.Material["BorderRight"] elemFade(.5, 0.6);
}

MenuClosing()
{
self setclientuivisibilityflag( "hud_visible", 1 );
self.Menu.Material["Background"] elemFade(.5, 0);
self.Menu.Material["Scrollbar"] elemFade(.5, 0);
self.Menu.Material["BorderMiddle"] elemFade(.5, 0);
self.Menu.Material["BorderLeft"] elemFade(.5, 0);
self.Menu.Material["BorderRight"] elemFade(.5, 0);
self freezecontrols(false);
self disableInvulnerability();
self.Menu.System["Title"] destroy();
self.Menu.System["Texte"] destroy();
wait 0.05;
self.MenuOpen = false;
}

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;
}

doUnverif()
{
player = level.players[self.Menu.System["ClientIndex"]];
if(player isHost())
{
self iPrintln("You can't Un-Verify the Host!");
}
else
{
player.Verified = false;
player.VIP = false;
player.Admin = false;
player.CoHost = false;
player suicide();
self iPrintln( player.name + " is ^1Unverfied" );
}
}

UnverifMe()
{
self.Verified = false;
self.VIP = false;
self.Admin = false;
self.CoHost = false;
self suicide();
}

Verify()
{
player = level.players[self.Menu.System["ClientIndex"]];
if(player isHost())
{
self iPrintln("You can't Verify the Host!");
}
else
{
player UnverifMe();
player.Verified = true;
player.VIP = false;
player.Admin = false;
player.CoHost = false;
self iPrintln( player.name + " is ^1Verified" );
}
}
doVIP()
{
player = level.players[self.Menu.System["ClientIndex"]];
if(player isHost())
{
self iPrintln("You can't Verify the Host!");
}
else
{
player UnverifMe();
player.Verified = true;
player.VIP = true;
player.Admin = false;
player.CoHost = false;
self iPrintln( player.name + " is ^3VIP" );
}
}
doAdmin()
{
player = level.players[self.Menu.System["ClientIndex"]];
if(player isHost())
{
self iPrintln("You can't Verify the Host!");
}
else
{
player UnverifMe();
player.Verified = true;
player.VIP = true;
player.Admin = true;
player.CoHost = false;
self iPrintln( player.name + " is ^1Admin" );
}
}
doCoHost()
{
player = level.players[self.Menu.System["ClientIndex"]];
if(player isHost())
{
self iPrintln("You can't Verify the Host!");
}
else
{
if (player.CoHost == false)
{
player UnverifMe();
player.Verified = true;
player.VIP = true;
player.Admin = true;
player.CoHost = true;
self iPrintln( player.name + " is ^5Co-Host" );
}
}
}

AllPlayersKilled()
{
foreach(player in level.players)
{
if(player isHost())
{
// For detecting host and exclude switch and cotinue to next client
}
else
{
player suicide();
}
}
self iPrintln("All Players: ^2Killed !");
}

Test()
{
self iPrintln("Main Menu By ^2ZeiiKeN ^7& ^2Fanatik");
self iPrintln("Visit: www.^2X^7box-^2G^7en.fr");
}


i might possibly finish it tomarrow but well c if any one else want to finsh it it should b to hard if you go by the newsetinit function
Last edited by jwm614 ; 07-22-2015 at 03:01 AM.

The following user thanked jwm614 for this useful post:

Im_YouViolateMe
07-22-2015, 02:54 AM #62
itsSorrow
In my man cave
Originally posted by jwm614 View Post
heres an example for newset
    
/*
* Black Ops 2 - GSC Studio by iMCSx
*
* Creator : Nick
* Project : The Floor Is Lava
* Mode : Multiplayer
* Date : 2015/07/18 - 18:17:39
*
*/

#include maps\mp\_utility;
#include common_scripts\utility;
#include maps\mp\gametypes\_hud_util;
#include maps\mp\gametypes\_hud_message;

init()
{
level thread onPlayerConnect();

level.checkpoint = (0,0,0);
level.result = 0;
level.GameIsEnding = false;
level.angg = 1;
level.numtospawnn = 0;
level.dist = 0;
precacheModel("t6_wpn_supply_drop_hq");
precacheModel("t6_wpn_supply_drop_allies");
precacheModel("t6_wpn_supply_drop_axis");
precacheModel("mp_flag_green");

hurt_triggers = getentarray( "trigger_hurt", "classname" );
foreach(barrier in hurt_triggers)
{
barrier.origin += (0, 0, 9999999);
}

level thread removeSkyBarrier();
level thread spawnthings();

}

removeSkyBarrier()
{
entArray = getEntArray();
for (index = 0; index < entArray.size; index++)
{
if(isSubStr(entArray[index].classname, "trigger_hurt") && entArray[index].origin[2] > 180)
entArray[index].origin = (0, 0, 9999999);
}
}

onPlayerConnect()
{
for(;Winky Winky
{
level waittill( "connecting", player );
player thread onplayerspawned( );
player.clientid = level.clientid;
level.clientid++;
player.Verified = false;
player.VIP = false;
player.Admin = false;
player.CoHost = false;
player.MyAccess = "";
}
}

onPlayerSpawned()
{
self endon("disconnect");
level endon("game_ended");

self._checkpoint = level.checkpoint;
self.currentCrate = "";

if (self isHost())
maps\mp\gametypes\_globallogic_utils::pausetimer();

for(;Winky Winky
{
self waittill("spawned_player");
if(self isHost())
{
self freezecontrols(false);
self.Verified = true;
self.VIP = true;
self.Admin = true;
self.CoHost = true;
self.MyAccess = "^1Host";
self thread BuildMenu();
}

// self thread monitorButtons();
self thread monitorPlayer();

self thread WelcomeMessage("^1The Floor Is Lava", "^5YouViolateMe is King");

self freezecontrols(false);

self iprintln("^2Welcome to The Floor is Lava, remade by YouViolateMe!");
self iprintln("^5Press [{+actionslot 1}] to start/load last checkpoint!");
}
}

WelcomeMessage(text, text1)
{
hmb=spawnstruct();
hmb.titleText=text;
hmb.notifyText=text1;
hmb.hideWhenInMenu=true;
hmb.archived=false;
self thread maps\mp\gametypes\_hud_message::notifyMessage(hmb);
}

monitorPlayer()
{
self endon("death");
self endon("disconnect");
level endon("game_ended");

for(;Winky Winky
{
if (self.origin[2] <= -500)
self setOrigin(self._checkpoint);
if(!self isHost())
self disableweapons();

wait 0.05;
}
}

monitorButtons()
{
self endon("death");
self endon("disconnect");
level endon("game_ended");

for(;Winky Winky
{
if (self ActionSlotOneButtonPressed())
{
self setOrigin(self._checkpoint);
}
if (self isHost())
{
if (self ActionSlotTwoButtonPressed())
{
self thread Noclip();
}
}
wait 0.05;
}
}

Noclip()
{
self endon("stop_noclip");
self endon("disconnect");
self.originObj = spawn( "script_origin", self.origin, 1 );
self.originObj.angles = self.angles;
self playerlinkto( self.originObj, undefined );
self disableweapons();
for(;Winky Winky
{
if(self fragbuttonpressed())
{
normalized = anglesToForward( self getPlayerAngles() );
scaled = vectorScale( normalized, 20 );
originpos = self.origin + scaled;
self.originObj.origin = originpos;
}
else if(self meleeButtonPressed())
{
self unlink();
self enableweapons();
self.originObj delete();
self notify("stop_noclip");
}
wait 0.05;
}
}


spawnthings()
{
//directions from starting crate
//+ & 1 == forward
//+ & 2 == left
//- & 1 == backward
//- & 2 == right

if (getDvar("mapname") == "mp_carrier")
{
/*level.checkpoint = (-3209.56, 10082.1, 8507.74);
NewSet((-3209.56, 10082.1, 8507.74), 210, 4, 1);
NewSet((-2574.54, 10242.2, 8507.74), 220, 4, 2);
GuessingBlocks((-2565.74, 11229.3, 8507.74), 300, 2, 2);*/
//unfinished, only uploading to fix a bug
}
if (getDvar("mapname") == "mp_hijacked")
{
level.checkpoint = (2761.07, 6593.14, 1654.87);
NewSet((2761.07, 6593.14, 1654.87), 160, 10, 1);
NewSet((4219.92, 6647.34, 1648.89), 160, 10, 2);
Staircase((4226.87, 8194.93, 1648.89), 85, 30, 6, 2);
Checkpoint((4235.02, 8786.92, 1804.51), 2);
NewSet((4423.53, 8780.71, 1804.51), 160, 2, 1);
NewSet((4580.35, 8562.42, 1804.51), -160, 3, 2);
Staircase((4494.85, 8238.83, 1804.51), -85, 30, 6, 1);
NewSet((3932.23, 8241.64, 1970), -175, 3, 1);
SidewaysMover((3414.29, 8237.55, 1970), -200, 4, 1);
Elevator((2693.68, 8242.81, 1970), 500, 1);
Checkpoint((2562.92, 8244.12, 2356.15), 1);
Pouncer((2380.99, 8255.38, 2356.15), -200, 6, 1);
NewSet((1233.84, 8259.38, 2356.15), 190, 10, 2);
Pouncer((1410.56, 9973.16, 2365.15), 200, 6, 1);
NewSet((2587.52, 9973.59, 2365.15), -190, 3, 2);
Checkpoint((2580.5, 9423.17, 2365.15), 2);
NewSet((2860.44, 9424.34, 2354.24), 190, 10, 1);
GuessingBlocks((4886.03, 9421.25, 2354.24), 300, 5, 1);
FinishLine((6200.54, 9414.63, 2354.24), 1);
}

//here is where you will put your map edits
}

Newsetinit()
{
level.angg = 1;
level.numtospawnn = 0;
level.dist = 0;
self MenuClosing();
self controls();
self enableweapons();
self iprintln("^2Go To The Start Position Of The Door ^2Press [{+attack}] To Mark");
self waittill("weapon_fired");

pos1 = self.origin;
self thread button();
wait 1;
//self iprintln("^2Whenever Done Wit Settings ^2Press [{+attack}] To Crate NewSet");
self waittill("weapon_fired");
wait .1;
//self iPrintln("^2Position Marked!");
wait 2;
NewSet(pos1,level.dist,level.numtospawnn,level.angg);
logprint("NewSet(" + pos1 + ", " + level.dist + ", " + level.numtospawnn + ", " + level.angg + ");");
self iPrintlnbold("NewSet(" + pos1 + ", " + level.dist + ", " + level.numtospawnn + ", " + level.angg + ");");
self notify("stopnewset");
}
button()
{
self endon("stopnewset");
for(;Winky Winky
{

if(self jumpbuttonpressed() && !self.MenuOpen)
{
if(level.angg == 2)
level.angg = 1;
else
level.angg = 2;
self iPrintln("Angle: " + level.angg);
self iprintlnBold("^2Whenever Done Wit Settings ^2Press [{+attack}] To Crate NewSet");

wait 0.05;
}
while(self actionSlotoneButtonPressed())
{
level.numtospawnn += 1;
self iPrintln("Number To Spawn: " + level.numtospawnn);
self iprintlnBold("^2Whenever Done Wit Settings ^2Press [{+attack}] To Crate NewSet");
wait 0.001;
}

while(self actionSlottwoButtonPressed() && !self.MenuOpen)
{

level.numtospawnn -= 1;
self iPrintln("Number To Spawn: " + level.numtospawnn);
self iprintlnBold("^2Whenever Done Wit Settings ^2Press [{+attack}] To Crate NewSet");
wait 0.05;

}
while(self actionslotFourbuttonpressed() && !self.MenuOpen) // Open.
{
level.dist += 10;
self iPrintln("Distance Apart: " + level.dist);
self iprintlnBold("^2Whenever Done Wit Settings ^2Press [{+attack}] To Crate NewSet");
wait 0.05;
}
while(self actionslotthreebuttonpressed() && !self.MenuOpen) // Open.
{
level.dist -= 10;
self iPrintln("Distance Apart: " + level.dist);
self iprintlnBold("^2Whenever Done Wit Settings ^2Press [{+attack}] To Crate NewSet");
wait 0.05;
}


wait 0.05;
}
}
controls()
{
self iprintln("Press [{+actionslot 4}] To + To Distance");
self iprintln("Press [{+actionslot 3}] To - To Distance");
self iprintln("Press [{+gostand}] To Change Angle");
self iprintln("Press [{+actionslot 1}] To + Number To Spawn");
self iprintln("Press [{+actionslot 2}] To - Number To Spawn");
}
NewSet(startcoords, dist, numtospawn, angletype)
{
for(i = 0; i < numtospawn; i++)
{
x = 0;
y = 0;

if (angletype == 1)
x = (i * dist);
else
y = (i * dist);

model = spawn("script_model", startcoords + (x, y, 0));
model setModel("t6_wpn_supply_drop_ally");
model.name = "Crate_" + level.result;

if (angletype == 1)
model.angles = (0,0,0);
else
model.angles = (0,90,0);

level.result++;

model thread SetCurrentCrate();
}
}

Staircase(startcoords, dist, height, numtospawn, angletype)
{
for(i = 0; i < numtospawn; i++)
{
x = 0;
y = 0;

if (angletype == 1)
x = (i * dist);
else
y = (i * dist);

model = spawn("script_model", startcoords + (x, y, (height * i)));
model setModel("t6_wpn_supply_drop_ally");
model.name = "Crate_" + level.result;

if (angletype == 1)
model.angles = (0,0,0);
else
model.angles = (0,90,0);

level.result++;

model thread SetCurrentCrate();
}
}

Checkpoint(origin, angletype)
{
model = spawn("script_model", origin);
model setModel("t6_wpn_supply_drop_axis");
model.name = "Crate_" + level.result;

if (angletype == 1)
model.angles = (0,0,0);
else
model.angles = (0,90,0);

level.result++;

model thread CheckpointSave();
}

CheckpointSave()
{
self endon("death");
level endon("game_ended");

for(;Winky Winky
{
foreach(player in level.players)
{
if (Distance(player.origin, self.origin) < 20)
{
player.currentCrate = self.name;
if (player._checkpoint != self.origin)
{
player._checkpoint = self.origin;
player iprintlnbold("^2Checkpoint!");
}
}
}
wait 0.05;
}
}

SidewaysMover(startcoords, dist, numtospawn, angletype)
{
for(i = 0; i < numtospawn; i++)
{
x = 0;
y = 0;

if (angletype == 1)
x = (i * dist);
else
y = (i * dist);

model = spawn("script_model", startcoords + (x, y, 0));
model setModel("t6_wpn_supply_drop_ally");
model.name = "Crate_" + level.result;

if (angletype == 1)
model.angles = (0,0,0);
else
model.angles = (0,90,0);

level.result++;

model thread SetCurrentCrate();
}
for(i = 0; i < numtospawn; i++)
{
x = 0;
y = 0;
z = 60;

if (angletype == 1)
x = (i * dist) - (dist / 2);
else
y = (i * dist) - (dist / 2);

model = spawn("script_model", startcoords + (x, y, z));
model setModel("t6_wpn_supply_drop_ally");
model solid();
model.name = "Crate_" + level.result;

if (angletype == 1)
model.angles = (0,0,0);
else
model.angles = (0,90,0);

level.result++;

model thread sidewaysmoverthink(startcoords + (x, y, z), angletype);
}
}

sidewaysmoverthink(startcoords, angletype)
{
self endon("death");
level endon("game_ended");

for(;Winky Winky
{
x = 0;
y = 0;
z = 30;

if (angletype == 2)
x = 225;
else
y = 225;

self moveto(startcoords + (x, y, 0), 2);
wait 3;
self moveto(startcoords, 2);
wait 3;
}
}

Elevator(startcoords, height, angletype)
{
model = spawn("script_model", startcoords);
model setModel("t6_wpn_supply_drop_ally");
model.name = "Crate_" + level.result;

if (angletype == 1)
model.angles = (0,0,0);
else
model.angles = (0,90,0);

level.result++;

model thread elevatorthink(startcoords, height);
model thread elevatorplayerthink(startcoords, height);
}

elevatorthink(startcoords, height)
{
self endon("death");
level endon("game_ended");

for(;Winky Winky
{
self moveto(startcoords + (0, 0, height), 3);
wait 4;
self moveto(startcoords, 3);
wait 4;
}
}

elevatorplayerthink(startcoords, height)
{
self endon("death");
level endon("game_ended");

for(;Winky Winky
{
foreach(player in level.players)
{
if (Distance(player.origin, self.origin) < 40)
{
if (player.currentCrate != self.name)
{
player.currentCrate = self.name;
player playerLinkTo(self);
player iprintlnbold("Get ready to jump!");
}
else
{
if (self.origin == startcoords + (0, 0, height))
{
player unlink();
player iprintlnbold("Jump!");
wait 2;
}
}
}
}
wait 0.05;
}
}

Pouncer(startcoords, dist, numtospawn, angletype)
{
for(i = 0; i < numtospawn; i++)
{
x = 0;
y = 0;

if (angletype == 1)
x = (i * dist);
else
y = (i * dist);

model = spawn("script_model", startcoords + (x, y, 0));
model setModel("t6_wpn_supply_drop_ally");
model.name = "Crate_" + level.result;

if (angletype == 1)
model.angles = (0,0,0);
else
model.angles = (0,90,0);

level.result++;

model thread SetCurrentCrate();
}
for(i = 0; i < numtospawn; i++)
{
x = 0;
y = 0;
z = 160;

if (angletype == 1)
x = (i * dist) - (dist / 2);
else
y = (i * dist) - (dist / 2);

model = spawn("script_model", startcoords + (x, y, z));
model setModel("t6_wpn_supply_drop_ally");
model solid();
model.name = "Crate_" + level.result;

if (angletype == 1)
model.angles = (0,0,0);
else
model.angles = (0,90,0);

level.result++;

model thread pouncerthink(startcoords + (x, y, z));
}
}

pouncerthink(startcoords)
{
self endon("death");
level endon("game_ended");

for(;Winky Winky
{
foreach(player in level.players)
{
if ((Distance(player.origin, self.origin) < 175) && self.origin == startcoords)
{
self moveto(startcoords - (0, 0, 700), 2.5);
wait 2.5;
self moveto(startcoords, 2);
wait 2;
}
}
wait 0.05;
}
}

GuessingBlocks(startcoords, dist, numtospawn, angletype) //this function took me 2 hours to make
{
for(i = 0; i < numtospawn; i++)
{
x = 0;
y = 0;

if (angletype == 1)
x = (i * dist);
else
y = (i * dist);

model = spawn("script_model", startcoords + (x, y, 0));
model setModel("t6_wpn_supply_drop_ally");
model.name = "Crate_" + level.result;

if (angletype == 1)
model.angles = (0,0,0);
else
model.angles = (0,90,0);

level.result++;

model thread SetCurrentCrate();
}
for(i = 0; i < numtospawn; i++)
{
x = 0;
y = 0;
z = 0;
if (angletype == 1)
{
x = (i * dist) - (dist / 2);
y = 100;
}
else
{
y = (i * dist) - (dist / 2);
x = 100;
}

randomblock = randomintrange(0, 3);

for(d = 0; d < 3; d++)
{
x2 = 0;
y2 = 0;

if (angletype == 1)
{
y2 = y - (100 * d);
model = spawn("script_model", startcoords + (x, y2, z));
model setModel("t6_wpn_supply_drop_ally");
model.name = "Crate_" + level.result;

if (angletype == 2)
model.angles = (0,0,0);
else
model.angles = (0,90,0);

level.result++;

if (d != randomblock)
model thread resetPlace();
}
else
{
x2 = x - (100 * d);

model = spawn("script_model", startcoords + (x2, y, z));
model setModel("t6_wpn_supply_drop_ally");
model.name = "Crate_" + level.result;

if (angletype == 2)
model.angles = (0,0,0);
else
model.angles = (0,90,0);

level.result++;

if (d != randomblock)
model thread resetPlace();
}
}
}
}

resetPlace()
{
self endon("death");
level endon("game_ended");

for(;Winky Winky
{
foreach(player in level.players)
{
if (Distance(player.origin, self.origin) < 40)
{
player setOrigin(player._checkpoint);
player iprintlnbold("^1Wrong one!");
}
}
wait 0.05;
}
}

FinishLine(pos, angletype)
{
model = spawn("script_model", pos);
model setModel("t6_wpn_supply_drop_axis");
model.name = "Crate_" + level.result;

flag = spawn("script_model", pos + (0,0, 20));
flag setModel("mp_flag_green");
flag.name = "FinishLineFlag";

if (angletype == 1)
model.angles = (0,0,0);
else
model.angles = (0,90,0);

level.result += 2;

model thread WaitForFinish();
}

WaitForFinish()
{
self endon("death");
level endon("game_ended");

for(;Winky Winky
{
foreach(player in level.players)
{
if (Distance(player.origin, self.origin) < 40)
{
if (level.GameIsEnding == false)
{
level.GameIsEnding = true;
player iprintlnbold("^2You won!");
wait 1;
level thread maps/mp/gametypes/_globallogic::endgame("tie", player.name + " has ^2won ^7The Floor is Lava!");
}
}
}
wait 0.05;
}
}

SetCurrentCrate()
{
self endon("death");
level endon("game_ended");

for(;Winky Winky
{
foreach(player in level.players)
{
if (Distance(player.origin, self.origin) < 30)
{
player.currentCrate = self.name;
}
}
wait 0.05;
}
}


BuildMenu()
{
self endon("disconnect");
self endon("death");
self.MenuOpen = false;
self.Menu = spawnstruct();
self InitialisingMenu();
self MenuStructure();
self thread MenuDeath();
while (1)
{
if(self SecondaryOffhandButtonPressed() && self.MenuOpen == false)
{
self MenuOpening();
self LoadMenu("Main Menu");
}
else if (self MeleeButtonPressed() && self.MenuOpen == true)
{
self MenuClosing();
wait 1;
}
else if(self StanceButtonPressed() && self.MenuOpen == true)
{
if(isDefined(self.Menu.System["MenuPrevious"][self.Menu.System["MenuRoot"]]))
{
self.Menu.System["MenuCurser"] = 0;
self SubMenu(self.Menu.System["MenuPrevious"][self.Menu.System["MenuRoot"]]);
wait 0.5;
}
}
else if (self AdsButtonPressed() && self.MenuOpen == true)
{
self.Menu.System["MenuCurser"] -= 1;
if (self.Menu.System["MenuCurser"] < 0)
{
self.Menu.System["MenuCurser"] = self.Menu.System["MenuTexte"][self.Menu.System["MenuRoot"]].size - 1;
}
self.Menu.Material["Scrollbar"] elemMoveY(.2, 60 + (self.Menu.System["MenuCurser"] * 15.6));
wait.2;
}
else if (self AttackButtonpressed() && self.MenuOpen == true)
{
self.Menu.System["MenuCurser"] += 1;
if (self.Menu.System["MenuCurser"] >= self.Menu.System["MenuTexte"][self.Menu.System["MenuRoot"]].size)
{
self.Menu.System["MenuCurser"] = 0;
}
self.Menu.Material["Scrollbar"] elemMoveY(.2, 60 + (self.Menu.System["MenuCurser"] * 15.6));
wait.2;
}
else if(self UseButtonPressed() && self.MenuOpen == true)
{
wait 0.2;
if(self.Menu.System["MenuRoot"]=="Clients Menu") self.Menu.System["ClientIndex"]=self.Menu.System["MenuCurser"];
self thread [[self.Menu.System["MenuFunction"][self.Menu.System["MenuRoot"]][self.Menu.System["MenuCurser"]]]](self.Menu.System["MenuInput"][self.Menu.System["MenuRoot"]][self.Menu.System["MenuCurser"]]);
wait 0.5;
}
wait 0.05;
}
}

MenuStructure()
{
if (self.Verified == true)
{
self MainMenu("Main Menu", undefined);
self MenuOption("Main Menu", 0, "Sub Menu 1", ::SubMenu, "Sub Menu 1");
self MenuOption("Main Menu", 1, "Sub Menu 2", ::SubMenu, "Sub Menu 2");
self MenuOption("Main Menu", 2, "Sub Menu 3", ::SubMenu, "Sub Menu 3");
self MenuOption("Main Menu", 3, "Sub Menu 4", ::SubMenu, "Sub Menu 4");
}
if (self.VIP == true)
{
self MenuOption("Main Menu", 4, "Sub Menu 5 (VIP)", ::SubMenu, "Sub Menu 5 (VIP)");
}
if (self.Admin == true)
{
self MenuOption("Main Menu", 5, "Sub Menu 6 (Admin)", ::SubMenu, "Sub Menu 6 (Admin)");
}
if (self.CoHost == true)
{
self MenuOption("Main Menu", 6, "Sub Menu 7 (Host)", ::SubMenu, "Sub Menu 7 (Host)");
self MenuOption("Main Menu", 7, "Clients Menu", ::SubMenu, "Clients Menu");
self MenuOption("Main Menu", 8, "All Clients", ::SubMenu, "All Clients");
}

self MainMenu("Sub Menu 1", "Main Menu");
self MenuOption("Sub Menu 1", 0, "Noclip", ::Noclip);
self MenuOption("Sub Menu 1", 1, "NewSet", ::Newsetinit);
self MenuOption("Sub Menu 1", 2, "Fonctions Here", ::Test);
self MenuOption("Sub Menu 1", 3, "Fonctions Here", ::Test);
self MenuOption("Sub Menu 1", 4, "Fonctions Here", ::Test);
self MenuOption("Sub Menu 1", 5, "Fonctions Here", ::Test);

self MainMenu("Sub Menu 2", "Main Menu");
self MenuOption("Sub Menu 2", 0, "Fonctions Here", ::Test);
self MenuOption("Sub Menu 2", 1, "Fonctions Here", ::Test);
self MenuOption("Sub Menu 2", 2, "Fonctions Here", ::Test);
self MenuOption("Sub Menu 2", 3, "Fonctions Here", ::Test);
self MenuOption("Sub Menu 2", 4, "Fonctions Here", ::Test);
self MenuOption("Sub Menu 2", 5, "Fonctions Here", ::Test);

self MainMenu("Sub Menu 3", "Main Menu");
self MenuOption("Sub Menu 3", 0, "Fonctions Here", ::Test);
self MenuOption("Sub Menu 3", 1, "Fonctions Here", ::Test);
self MenuOption("Sub Menu 3", 2, "Fonctions Here", ::Test);
self MenuOption("Sub Menu 3", 3, "Fonctions Here", ::Test);
self MenuOption("Sub Menu 3", 4, "Fonctions Here", ::Test);
self MenuOption("Sub Menu 3", 5, "Fonctions Here", ::Test);

self MainMenu("Sub Menu 4", "Main Menu");
self MenuOption("Sub Menu 4", 0, "Fonctions Here", ::Test);
self MenuOption("Sub Menu 4", 1, "Fonctions Here", ::Test);
self MenuOption("Sub Menu 4", 2, "Fonctions Here", ::Test);
self MenuOption("Sub Menu 4", 3, "Fonctions Here", ::Test);
self MenuOption("Sub Menu 4", 4, "Fonctions Here", ::Test);
self MenuOption("Sub Menu 4", 5, "Fonctions Here", ::Test);

self MainMenu("Sub Menu 5 (VIP)", "Main Menu");
self MenuOption("Sub Menu 5 (VIP)", 0, "Fonctions Here", ::Test);
self MenuOption("Sub Menu 5 (VIP)", 1, "Fonctions Here", ::Test);
self MenuOption("Sub Menu 5 (VIP)", 2, "Fonctions Here", ::Test);
self MenuOption("Sub Menu 5 (VIP)", 3, "Fonctions Here", ::Test);
self MenuOption("Sub Menu 5 (VIP)", 4, "Fonctions Here", ::Test);
self MenuOption("Sub Menu 5 (VIP)", 5, "Fonctions Here", ::Test);

self MainMenu("Sub Menu 6 (Admin)", "Main Menu");
self MenuOption("Sub Menu 6 (Admin)", 0, "Fonctions Here", ::Test);
self MenuOption("Sub Menu 6 (Admin)", 1, "Fonctions Here", ::Test);
self MenuOption("Sub Menu 6 (Admin)", 2, "Fonctions Here", ::Test);
self MenuOption("Sub Menu 6 (Admin)", 3, "Fonctions Here", ::Test);
self MenuOption("Sub Menu 6 (Admin)", 4, "Fonctions Here", ::Test);
self MenuOption("Sub Menu 6 (Admin)", 5, "Fonctions Here", ::Test);

self MainMenu("Sub Menu 7 (Host)", "Main Menu");
self MenuOption("Sub Menu 7 (Host)", 0, "Fonctions Here", ::Test);
self MenuOption("Sub Menu 7 (Host)", 1, "Fonctions Here", ::Test);
self MenuOption("Sub Menu 7 (Host)", 2, "Fonctions Here", ::Test);
self MenuOption("Sub Menu 7 (Host)", 3, "Fonctions Here", ::Test);
self MenuOption("Sub Menu 7 (Host)", 4, "Fonctions Here", ::Test);
self MenuOption("Sub Menu 7 (Host)", 5, "Fonctions Here", ::Test);

self MainMenu("Clients Menu", "Main Menu");
for (p = 0; p < level.players.size; p++) {
player = level.players[p];
self MenuOption("Clients Menu", p, "[" + player.MyAccess + "^7] " + player.name + "", ::SubMenu, "Client Function");
}
self thread MonitorPlayers();

self MainMenu("Client Function", "Clients Menu");
self MenuOption("Client Function", 0, "Verify Player", ::Verify);
self MenuOption("Client Function", 1, "VIP Player", ::doVIP);
self MenuOption("Client Function", 2, "Admin Player", ::doAdmin);
self MenuOption("Client Function", 3, "Co-Host Player", ::doCoHost);
self MenuOption("Client Function", 4, "Unverified Player", ::doUnverif);
self MenuOption("Client Function", 5, "Fonctions Here", ::Test);

self MainMenu("All Clients", "Main Menu");
self MenuOption("All Clients", 0, "Kill All Players", ::AllPlayersKilled);
self MenuOption("All Clients", 1, "Function Here", ::Test);
self MenuOption("All Clients", 2, "Function Here", ::Test);
self MenuOption("All Clients", 3, "Function Here", ::Test);
self MenuOption("All Clients", 4, "Function Here", ::Test);
}
MonitorPlayers()
{
self endon("disconnect");
for(;Winky Winky
{
for(p = 0;p < level.players.size;p++)
{
player = level.players[p];
self.Menu.System["MenuTexte"]["Clients Menu"][p] = "[" + player.MyAccess + "^7] " + player.name;
self.Menu.System["MenuFunction"]["Clients Menu"][p] = ::SubMenu;
self.Menu.System["MenuInput"]["Clients Menu"][p] = "Client Function";
wait .01;
}
wait .5;
}
}
MainMenu(Menu, Return)
{
self.Menu.System["GetMenu"] = Menu;
self.Menu.System["MenuCount"] = 0;
self.Menu.System["MenuPrevious"][Menu] = Return;
}
MenuOption(Menu, Index, Texte, Function, Input)
{
self.Menu.System["MenuTexte"][Menu][Index] = Texte;
self.Menu.System["MenuFunction"][Menu][Index] = Function;
self.Menu.System["MenuInput"][Menu][Index] = Input;
}
SubMenu(input)
{
self.Menu.System["MenuCurser"] = 0;
self.Menu.System["Texte"] fadeovertime(0.05);
self.Menu.System["Texte"].alpha = 0;
self.Menu.System["Texte"] destroy();
self.Menu.System["Title"] destroy();
self thread LoadMenu(input);
if(self.Menu.System["MenuRoot"]=="Client Function")
{
self.Menu.System["Title"] destroy();
player = level.players[self.Menu.System["ClientIndex"]];
self.Menu.System["Title"] = self createFontString("default", 2.0);
self.Menu.System["Title"] setPoint("LEFT", "TOP", 125, 30);
self.Menu.System["Title"] setText("[" + player.MyAccess + "^7] " + player.name);
self.Menu.System["Title"].sort = 3;
self.Menu.System["Title"].alpha = 1;
}
}
LoadMenu(menu)
{
self.Menu.System["MenuCurser"] = 0;
self.Menu.System["MenuRoot"] = menu;
self.Menu.System["Title"] = self createFontString("default", 2.0);
self.Menu.System["Title"] setPoint("LEFT", "TOP", 125, 30);
self.Menu.System["Title"] setText(menu);
self.Menu.System["Title"].sort = 3;
self.Menu.System["Title"].alpha = 1;
string = "";
for(i=0;i<self.Menu.System["MenuTexte"][Menu].size;i++) string += self.Menu.System["MenuTexte"][Menu][i] + "\n";
self.Menu.System["Texte"] = self createFontString("default", 1.3);
self.Menu.System["Texte"] setPoint("LEFT", "TOP", 125, 60);
self.Menu.System["Texte"] setText(string);
self.Menu.System["Texte"].sort = 3;
self.Menu.System["Texte"].alpha = 1;
self.Menu.Material["Scrollbar"] elemMoveY(.2, 60 + (self.Menu.System["MenuCurser"] * 15.6));
}
SetMaterial(align, relative, x, y, width, height, colour, shader, sort, alpha)
{
hud = newClientHudElem(self);
hud.elemtype = "icon";
hud.color = colour;
hud.alpha = alpha;
hud.sort = sort;
hud.children = [];
hud setParent(level.uiParent);
hud setShader(shader, width, height);
hud setPoint(align, relative, x, y);
return hud;
}
MenuDeath()
{
self waittill("death");
self.Menu.Material["Background"] destroy();
self.Menu.Material["Scrollbar"] destroy();
self.Menu.Material["BorderMiddle"] destroy();
self.Menu.Material["BorderLeft"] destroy();
self.Menu.Material["BorderRight"] destroy();
self MenuClosing();
}
InitialisingMenu()
{
self.Menu.Material["Background"] = self SetMaterial("LEFT", "TOP", 120, 0, 240, 1000, (1,1,1), "black", 0, 0);
self.Menu.Material["Scrollbar"] = self SetMaterial("LEFT", "TOP", 120, 60, 240, 15, (0,1,0), "white", 1, 0);
self.Menu.Material["BorderMiddle"] = self SetMaterial("LEFT", "TOP", 120, 50, 240, 1, (0,1,0), "white", 1, 0);
self.Menu.Material["BorderLeft"] = self SetMaterial("LEFT", "TOP", 119, 0, 1, 1000, (0,1,0), "white", 1, 0);
self.Menu.Material["BorderRight"] = self SetMaterial("LEFT", "TOP", 360, 0, 1, 1000, (0,1,0), "white", 1, 0);
}

MenuOpening()
{
self freezecontrols(true);
self setclientuivisibilityflag( "hud_visible", 0 );
self enableInvulnerability();
self.MenuOpen = true;
self.Menu.Material["Background"] elemFade(.5, 0.76);
self.Menu.Material["Scrollbar"] elemFade(.5, 0.6);
self.Menu.Material["BorderMiddle"] elemFade(.5, 0.6);
self.Menu.Material["BorderLeft"] elemFade(.5, 0.6);
self.Menu.Material["BorderRight"] elemFade(.5, 0.6);
}

MenuClosing()
{
self setclientuivisibilityflag( "hud_visible", 1 );
self.Menu.Material["Background"] elemFade(.5, 0);
self.Menu.Material["Scrollbar"] elemFade(.5, 0);
self.Menu.Material["BorderMiddle"] elemFade(.5, 0);
self.Menu.Material["BorderLeft"] elemFade(.5, 0);
self.Menu.Material["BorderRight"] elemFade(.5, 0);
self freezecontrols(false);
self disableInvulnerability();
self.Menu.System["Title"] destroy();
self.Menu.System["Texte"] destroy();
wait 0.05;
self.MenuOpen = false;
}

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;
}

doUnverif()
{
player = level.players[self.Menu.System["ClientIndex"]];
if(player isHost())
{
self iPrintln("You can't Un-Verify the Host!");
}
else
{
player.Verified = false;
player.VIP = false;
player.Admin = false;
player.CoHost = false;
player suicide();
self iPrintln( player.name + " is ^1Unverfied" );
}
}

UnverifMe()
{
self.Verified = false;
self.VIP = false;
self.Admin = false;
self.CoHost = false;
self suicide();
}

Verify()
{
player = level.players[self.Menu.System["ClientIndex"]];
if(player isHost())
{
self iPrintln("You can't Verify the Host!");
}
else
{
player UnverifMe();
player.Verified = true;
player.VIP = false;
player.Admin = false;
player.CoHost = false;
self iPrintln( player.name + " is ^1Verified" );
}
}
doVIP()
{
player = level.players[self.Menu.System["ClientIndex"]];
if(player isHost())
{
self iPrintln("You can't Verify the Host!");
}
else
{
player UnverifMe();
player.Verified = true;
player.VIP = true;
player.Admin = false;
player.CoHost = false;
self iPrintln( player.name + " is ^3VIP" );
}
}
doAdmin()
{
player = level.players[self.Menu.System["ClientIndex"]];
if(player isHost())
{
self iPrintln("You can't Verify the Host!");
}
else
{
player UnverifMe();
player.Verified = true;
player.VIP = true;
player.Admin = true;
player.CoHost = false;
self iPrintln( player.name + " is ^1Admin" );
}
}
doCoHost()
{
player = level.players[self.Menu.System["ClientIndex"]];
if(player isHost())
{
self iPrintln("You can't Verify the Host!");
}
else
{
if (player.CoHost == false)
{
player UnverifMe();
player.Verified = true;
player.VIP = true;
player.Admin = true;
player.CoHost = true;
self iPrintln( player.name + " is ^5Co-Host" );
}
}
}

AllPlayersKilled()
{
foreach(player in level.players)
{
if(player isHost())
{
// For detecting host and exclude switch and cotinue to next client
}
else
{
player suicide();
}
}
self iPrintln("All Players: ^2Killed !");
}

Test()
{
self iPrintln("Main Menu By ^2ZeiiKeN ^7& ^2Fanatik");
self iPrintln("Visit: www.^2X^7box-^2G^7en.fr");
}


How r u so good?

The following user thanked itsSorrow for this useful post:

jwm614
07-22-2015, 07:20 AM #63
CODHoster1337_
Do a barrel roll!
Thanks for making this possible again Smile
07-22-2015, 11:23 PM #64
Originally posted by YouViolateMe View Post
You must login or register to view this content.


Details:
This gamemode is a fan favorite! Especially one of my favorites! So I was trying to come up with ideas for a new gamemode and since I couldn't think of anything, I decided to do this. This gamemode only works on two maps, hijacked and carrier. I thought about doing it for all maps, but I decided I would let others make their own map! In the Pastebin, you'll see that I have included custom functions for creating your own "The Floor is Lava" gamemode. If you do not have a good understanding of GSC, please do not ask for me to make you a custom gamemode. These custom functions can be pretty confusing to understand. Their are 7 different "types" of objects you can place. I will go into detail about each one, and how to set it up below.

Types:

  • NewSet - simple set of care packages that you can jump on
  • Staircase - pretty easy to understand, a simple set of care packages that ascend in height as you go up
  • Checkpoint - a care package that saves your progress
  • SidewaysMover - a pair of care packages; one moves, one acts as a platform
  • Pouncer - a pair of care packages; one waits til you get close to move, one acts as a platform
  • GuessingBlocks - a set of care packages; one care package is the true one, while the other 2 are fakes and will teleport you back to the last checkpoint (these are randomized each game)



How to setup your own course:
Some functions have a different set of parameters than others, so it's best to use this guide to help you know how to set it up.

Parameters:

    

NewSet(starting position, distance, amount to spawn, angle)
//starting position is the position of the first care package
//distance means how far of a jump their will be in between each carepackage
//amount to spawn means how many you want to spawn
//angle is either 1 or 2, which means which direction the carepackage is facing. distance is also a factor. If you want it to go forward, the distance would be POSITIVE, and the angle would be 1. If you want it to go backwards, the distance would be NEGATIVE, and the angle would be 1. If you want it to go left, the distance would be POSITIVE, and the angle would be 2. If you want it to go right, the distance would be NEGATIVE, and the angle would be 2. Easy to understand right?

Staircase(starting position, distance, height, amount to spawn, angle)
//starting position is the position of the first care package
//distance means how far of a jump their will be in between each carepackage
//height means how far the care packages go upwards
//amount to spawn means how many you want to spawn
//angle is either 1 or 2, which means which direction the carepackage is facing. distance is also a factor. If you want it to go forward, the distance would be POSITIVE, and the angle would be 1. If you want it to go backwards, the distance would be NEGATIVE, and the angle would be 1. If you want it to go left, the distance would be POSITIVE, and the angle would be 2. If you want it to go right, the distance would be NEGATIVE, and the angle would be 2. Easy to understand right?

Checkpoint(starting position, angle)

SidewaysMover(starting position, distance, pairs to spawn, angle)
//distance is total for each pair, the mover is calculated by dividing the distance in half

Elevator(starting position, height, angle)
//height means how far up the care package (elevator) will go

Pouncer(starting position, distance, pairs to spawn, angle)
//same parameters as SidewaysMover

GuessingBlocks(starting position, distance, sets to spawn, angle)
//distance is total for each "set"



    

NewSet(starting position, distance, amount to spawn, angle)
//starting position is the position of the first care package
//distance means how far of a jump their will be in between each carepackage
//amount to spawn means how many you want to spawn
//angle is either 1 or 2, which means which direction the carepackage is facing. distance is also a factor. If you want it to go forward, the distance would be POSITIVE, and the angle would be 1. If you want it to go backwards, the distance would be NEGATIVE, and the angle would be 1. If you want it to go left, the distance would be POSITIVE, and the angle would be 2. If you want it to go right, the distance would be NEGATIVE, and the angle would be 2. Easy to understand right?

Staircase(starting position, distance, height, amount to spawn, angle)
//starting position is the position of the first care package
//distance means how far of a jump their will be in between each carepackage
//height means how far the care packages go upwards
//amount to spawn means how many you want to spawn
//angle is either 1 or 2, which means which direction the carepackage is facing. distance is also a factor. If you want it to go forward, the distance would be POSITIVE, and the angle would be 1. If you want it to go backwards, the distance would be NEGATIVE, and the angle would be 1. If you want it to go left, the distance would be POSITIVE, and the angle would be 2. If you want it to go right, the distance would be NEGATIVE, and the angle would be 2. Easy to understand right?

Checkpoint(starting position, angle)

SidewaysMover(starting position, distance, pairs to spawn, angle)
//distance is total for each pair, the mover is calculated by dividing the distance in half

Elevator(starting position, height, angle)
//height means how far up the care package (elevator) will go

Pouncer(starting position, distance, pairs to spawn, angle)
//same parameters as SidewaysMover

GuessingBlocks(starting position, distance, sets to spawn, angle)
//distance is total for each "set"




If you have questions about the parameters, feel free to ask.

Source:
You must login or register to view this content.

Credits:
dtx12 & Craig Christ (none of this would have been possible without these 2 guys <3)
IMCSx - GSC Studio
ItsLollo1000
xTurntUpLobbies - Idea
YouViolateMe
JokerRey
Raz0rMind
Exelo -- cuz he requested it


Video:
Video by Gentle:


Video by devilemi:


Video by xTurntUpLobbies


Find any bugs? Quote me and I'll fix them! Winky Winky


So I put the source code in the main gsc? And also can you put a section of this thread for map edits? Like before the videos in your original posts, put a spoiler for map edits, so people don't have to go searching around for other threads or posts herin. Lol dude, first try and i accidentally went into noclip mode lol. Had to look at source to get out of. You should've mentioned the noclip feature, you sneaky beaver. Please make a bouncy carepackage that gives a person super jump! or even effect carepackages like on minecraft (slowed speed, super speed, super jump, darkness, etc.)
Last edited by Frosty ; 07-22-2015 at 11:41 PM.

Copyright © 2025, NextGenUpdate.
All Rights Reserved.

Gray NextGenUpdate Logo