Results 1 to 2 of 2
  1. #1
    Member PoRtUgAlZz's Avatar
    Join Date
    Jan 2012
    Posts
    115
    Points
    392
         User Info     Contact     Gamer ID
    Join Date
    Jan 2012
    Posts
    115
    Points
    392

    Contact info:

    Youtube Channel: http://www.youtube.com/user/TwiiZZyH4X

    Default [HELP] Chaos Dogs For Nuketown !

    I Need Help Trying To Get This Working Plz Help! :confused: All i did was changed the co-ordinates for the thing i needed ;) plz help.

    Code:
    #include common_scripts\utility;
    #include maps\mp\_airsupport;
    #include maps\mp\_utility;
    #include maps\mp\gametypes\_hud_util;
    
     /*//////////\\\\\\\\\\\\\\
     //....CHAOS DOGS V1.....\\
     ||======================||
     || This mod was made by ||
     ||    JellyInjector	 ||
     ||	    and		 ||
     ||	   Kylaii	 ||
     \\======================//
     \\\\\\\\\\\\////////////*/
    
    //Dog Dvar Default Settings
    //setDvar( "scr_dog_count", "8" ); //number of dogs for killstreak
    //setDvar( "scr_dog_max_at_once", "4" ); //max dogs at once
    //setDvar( "scr_dog_health", "100" ); //dogs health
    //setDvar( "scr_dog_time", "60" ); //how long dogs last
    
    init()
    {
    	thread onPlayerConnect();
    	thread onPlayerConnected();
    
    	level.casSpot = -110;
    	level.casColor = 1;
    	level.prematchPeriod = 23;
    	level.doublePoints = 0;
    	level.instaKill = 0;
    	level.powerOn = 0;
    	level.lastPowerup = 99;
    
    	thread doMap();
    	thread powerDisplay();
    	thread cleanUpSystem();
    	thread summonDogs();
    	thread roundCount();
    	thread secret();
    
    	game["icons"]["allies"] = "compass_objpoint_dogs";
    	setdvar( "g_TeamIcon_Allies", game["icons"]["allies"] );
    
    	precacheModel( "prop_suitcase_bomb" );
    	PrecacheShader( "perk_times_two" );
    	PrecacheShader( "hud_ammo_refill_drop" );
    	PrecacheShader( "hud_ks_minigun" );
    	PrecacheShader( "headicon_dead" );
    
    	wait 2;
    
    	level.fx_tabun_0 = level._effect["fx_fire_player_sm_smk_2sec"];
    	level.fx_tabun_1 = level._effect["character_fire_death_sm"];
    	level.fx_tabun_2 = level._effect["character_fire_death_torso"];
    	level.fx_tabun_3 = "napalmground_sm_mp";
    	level.fx_tabun_single = "napalmground_lg_mp";
    	PreCacheItem( level.fx_tabun_0 );
    	PreCacheItem( level.fx_tabun_1 );
    	PreCacheItem( level.fx_tabun_2 );
    	PreCacheItem( level.fx_tabun_3 );
    	PreCacheItem( level.fx_tabun_single );
    }
    
    onPlayerConnect()
    {
    	for(;;)
    	{
    		level waittill( "connecting", player );
    
    		player thread playerTeams();
    	}
    }
    
    onPlayerConnected()
    {
    	for(;;)
    	{
    		level waittill( "connected", player );
    
    		player thread onPlayerSpawned();
    		if( level.powerOn == 0 )
    	        player thread doMapThinkPOff();
    		player thread doMapThinkPOn();
    		player thread perkDisplay();
    		player thread cash();
    		player thread globalVars();
    		player thread setupTeam();
    		player thread reset();
    		//player thread doVision();
    	}
    }
    
    onPlayerSpawned()
    {
    	for(;;)
    	{
    		self waittill( "spawned_player" );
    
    		self thread spawnStuff();
    	}
    }
    
    spawnStuff()
    {
    	self clearPerks();
    	self takeAllWeapons();
    	self giveWeapon( "knife_mp" );
    	self giveWeapon( "cz75_mp" );
    	self giveMaxAmmo( "cz75_mp" );
    	self giveWeapon( "m1911_mp" );
    	self giveMaxAmmo( "m1911_mp" );
    	self giveWeapon( "tabun_gas_mp" );
    	self switchToWeapon( "m1911_mp" );
    
    	self.maxhealth = 400;
    	self.health = self.maxhealth;
    
            thread doVision();
    }
    
    doVision()
    {
    	self setClientDvar( "r_filmTweakInvert", "0" );
    	self setClientDvar( "r_filmUseTweaks", "1" );
    	self setClientDvar( "r_filmTweakEnable", "1" );
    	self setClientDvar( "r_filmTweakLightTint", "0 0 0" );
    	self setClientDvar( "r_filmTweakSaturation", "1 1 1" );
    	self setClientDvar( "r_filmTweakHue", "0 0 0" );
    }
    
    createGreen( pos, angle ) // Crate for Miscellanious
    {
    	crateG = spawn( "script_model", pos );
    	crateG setModel( "mp_supplydrop_ally" );
    	crateG.angles = angle;
    }
    
    createPerk( pos, angle, num ) // Crate for Machines
    {
    	level.crateR[num] = spawn( "script_model", pos );
    	level.crateR[num] setModel( "mp_supplydrop_axis" );
    	level.crateR[num].angles = angle;
    }
    
    createRed( pos, angle ) // Crate for Red
    {
    	cratered = spawn( "script_model", pos );
    	cratered setModel( "mp_supplydrop_axis" );
    	cratered.angles = angle;
    }
    
    createBlack( pos, angle ) // Crate for Boundaries
    {
    	crateB = spawn( "script_model", pos );
    	crateB setModel( "mp_supplydrop_boobytrapped" );
    	crateB.angles = angle;
    }
    
    createPower( pos, angle ) // RCXD for Power Box
    {
    	level.xdcar = spawn( "script_model", pos );
    	level.xdcar setModel( "t5_veh_rcbomb_allies" );
    	level.xdcar.angles = angle;
    }
    
    createDoor( pos, angle, num ) // Crate for Moving Doors
    {
    	level.crateD[num] = spawn( "script_model", pos );
    	level.crateD[num] setModel( "mp_supplydrop_ally" );
    	level.crateD[num].angles = angle;
    }
    
    createSpot( pos )
    {
    	level.teleSpot = spawn( "script_model", pos );
    }
    
    doMap()
    {
    	// Perk Machines
    	level.bunkers[1] = createPerk( ( -816, 741, -33 ), ( 0, 70, 90 ), 1 );
    	level.bunkers[2] = createPerk( ( 597, 309, -23 ), ( 0, 11, 90 ), 2 );
    	level.bunkers[3] = createPerk( ( 329, -551, -26 ), ( 0, -175, 90 ), 3 );
    	level.bunkers[54] = createPerk( ( -620.119, -2063.17, 241.438 ), ( 0, -88.0988, 90 ), 4 );
    
    	// Boundaries
    	level.bunkers[4] = createBlack( ( -647.351, -1990.5, 258.536 ), ( 0, 87.6355, 0 ) );
    	level.bunkers[5] = createBlack( ( -714.183, -1989.94, 259.624 ), ( 0, 89.0088, 0 ) );
    	level.bunkers[19] = createBlack( ( -789.805, -1992.51, 260.83 ), ( 0, 91.5329, 0 ) );
    	level.bunkers[20] = createBlack( ( -858.18, -1996.76, 258.866 ), ( 0, 90.1431, 0 ) );
    	level.bunkers[21] = createBlack( ( -925.035, -1998.67, 258.403 ), ( 0, 92.2085, 0 ) );
    	level.bunkers[22] = createBlack( ( -995.546, -1998.06, 255.094 ), ( 0, 85.1089, 0 ) );
    	level.bunkers[42] = createBlack( ( -1064.65, -1993.39, 250.712 ), ( 0, 84.5843, 0 ) );
    	level.bunkers[43] = createBlack( ( -1002.83, -2032.74, 250.913 ), ( 0, 179.978, 0 ) );
    	level.bunkers[44] = createBlack( ( -1079.51, -2005.88, 253.857 ), ( 0, 127.236, 0 ) );
    	level.bunkers[45] = createBlack( ( -1029.21, -2004.31, 259.212 ), ( 0, 99.2536, 0 ) );
    	level.bunkers[49] = createBlack( ( -552.089, -2179.59, 228.099 ), ( 0, -0.908325, 0 ) );
    	level.bunkers[50] = createBlack( ( -556.295, -2253.51, 229.62 ), ( 0, -4.87439, 0 ) );
    	level.bunkers[51] = createBlack( ( -563.485, -2320.66, 230.116 ), ( 0, -5.81084, 0 ) );
    	level.bunkers[52] = createBlack( ( -560.94, -2182.39, 244.213 ), ( 0, -2.03157, 0 ) );
    	level.bunkers[53] = createBlack( ( -566.295, -2258.11, 240.329 ), ( 0, -1.29001, 0 ) );
    	level.bunkers[55] = createBlack( ( -561.776, -2258.56, 206.514 ), ( 0, -4.99238, 0 ) );
    	level.bunkers[56] = createBlack( ( -569.9, -2329.5, 198.583 ), ( 0, -5.89326, 0 ) );
    	level.bunkers[57] = createBlack( ( -572.599, -2321.62, 235.217 ), ( 0, -4.32771, 0 ) );
    	level.bunkers[58] = createBlack( ( -633.058, -2319.54, 197.805 ), ( 0, -93.2763, 0 ) );
            level.bunkers[59] = createBlack( ( -706.241, -2316.07, 197.761 ), ( 0, -90.2056, 0 ) );
            level.bunkers[60] = createBlack( ( -781.53, -2314.73, 200.191 ), ( 0, -92.3919, 0 ) );
            level.bunkers[61] = createBlack( ( -855.735, -2309.15, 202.722 ), ( 0, -93.6684, 0 ) );
            level.bunkers[62] = createBlack( ( -922.859, -2305.05, 202.437 ), ( 0, -92.9488, 0 ) );
            level.bunkers[63] = createBlack( ( -994.643, -2298.81, 204.622 ), ( 0, -95.4592, 0 ) );
            level.bunkers[64] = createBlack( ( -1061.96, -2294.53, 208.396 ), ( 0, -88.9300, 0 ) );
            level.bunkers[65] = createBlack( ( -1100.93, -2097.3, 250.138 ), ( 0, -178.071, 0 ) );
            level.bunkers[67] = createBlack( ( -1097.21, 2161.06, 247.389 ), ( 0, -173.847, 0 ) );
            level.bunkers[68] = createBlack( ( -1091.41, -2221.51, 245.416 ), ( 0, -178.291, 0 ) ); 
            level.bunkers[69] = createBlack( ( -1087.72, -2267.64, 244.04 ), ( 0, -179.224, 0 ) );
            level.bunkers[70] = createBlack( ( -1091, -2240.88, 214.572 ), ( 0, -178.536, 0 ) );
            level.bunkers[71] = createBlack( ( -1096.85, -2171.57, 221.321 ), ( 0, -171.739, 0 ) );
            level.bunkers[72] = createBlack( ( -1094.77, -2070.26, 254.832 ), ( 0, -176.298, 0 ) );
            level.bunkers[73] = createBlack( ( -1040.48, -2286.38, 238.58 ), ( 0, -91.5906, 0 ) );
            level.bunkers[74] = createBlack( ( -976.534, -2282.85, 239.71 ), ( 0, -96.0511, 0 ) );
            level.bunkers[75] = createBlack( ( -920.837, -2284.51, 238.347 ), ( 0, -94.3317, 0 ) );
            level.bunkers[76] = createBlack( ( -865.885, -2284.53, 238.07 ), ( 0, -94.469, 0 ) );
            level.bunkers[77] = createBlack( ( -801.371, -2284.6, 236.413 ), ( 0, -90.7996, 0 ) );
            level.bunkers[78] = createBlack( ( -736.696, -2283.32, 234.836 ), ( 0, -90.134, 0 ) );
            level.bunkers[79] = createBlack( ( -768.953, -2276.77, 235.652 ), ( 0, -88.2444, 0 ) );
            level.bunkers[80] = createBlack( ( -614.316, -2278.44, 232.783 ), ( 0, -91.7384, 0 ) );
    
    	// Teleporter
    	level.bunkers[7] = createGreen( ( 1541.09, 1437.8, -13.8212 ), ( 0, 150, 90 ) );
    	level.bunkers[8] = createGreen( ( 1511.5, 1455.28, -13 ), ( -180, 160, 90 ) );
    	level.bunkers[9] = createGreen( ( 1574.41, 1421.62, -13.5092 ), ( 0, 150, 90 ) );
    	level.bunkers[10] = createGreen( ( 1519.63, 1444.48, 39.2482 ), ( 0, 60, 0 ) );
    	level.bunkers[11] = createGreen( ( 1580.14, 1412.93, 42.395 ), ( 0, 60, 0 ) );
    	level.bunkers[12] = createDoor( ( 1767.54, 570.59, -26.2161 ), ( 0, -77.8417, 90 ), 1 );
    	level.bunkers[13] = createDoor( ( 1776.14, 530.79, -25.9901 ), ( 0, -74.115, 90 ), 2 );
    	level.bunkers[49] = createDoor( ( 1887.77, 220.554, -26.2554 ), ( 0, -73.3759, 90 ), 3 );
            level.bunkers[50] = createDoor( ( 1899, 177.921, -23.8611 ), ( 0, -71.4228, 90 ), 4 );
    	level.bunkers[14] = createGreen( ( 1654.02, 1372.95, -11.8996 ), ( 0, 240, -90 ) );
    	level.bunkers[16] = createGreen( ( 1637.93, 1379.34, 42.3871 ), ( 0, 60, 0 ) );
    	level.bunkers[17] = createGreen( ( 1650.83, 1374.77, -12.0637 ), ( 0, 330, -90 ) );
    	level.bunkers[18] = createSpot( ( 1942.75, 395.39, -70.9436 ) );
    	level.bunkers[24] = createGreen( ( 1636.58, 1337.78, -12.0023 ), ( 0, 60, 90 ) );
    	level.bunkers[25] = createGreen( ( 1619.59, 1310.5, -12.4566 ), ( 0, 60, 90 ) );
    	level.bunkers[26] = createGreen( ( 1604.19, 1284.2, -11.5834 ), ( 0, 60, 90 ) );
    	level.bunkers[27] = createGreen( ( 1590.46, 1259.8, -11.9353 ), ( 0, 60, 90 ) );
    	level.bunkers[28] = createGreen( ( 1576.98, 1238.55, -12.175 ), ( 0, 60, 90 ) );
    	level.bunkers[29] = createGreen( ( 1644.78, 1354.06, 41.259 ), ( 90, 330, 0 ) );
    	level.bunkers[30] = createGreen( ( 1609.37, 1292.61, 40.6795 ), ( -90, 150, 0 ) );
    	level.bunkers[31] = createGreen( ( 1586.44, 1252.25, 40.7318 ), ( 90, 330, 0 ) );
    
    	// Power Box
    	level.bunkers[15] = createPower( ( -728.532, 562.813, -17.2573 ), ( 0, -16.0709, 90 ) );
    
    	wait 0.5;
    
    	// Mystery Box
    	level.oldMysBox = 99;
    	level.mBoxSpot = [];
    	level.mBoxAngle = [];
    	level.mBoxSpot[0] = ( -113.5, 894.58, -49.192 );
    	level.mBoxAngle[0] = ( 0, -62.1749, 0 );
    	level.mBoxSpot[1] = ( -1756.79, 827.009, -42.8748 );
    	level.mBoxAngle[1] = ( 0, -112.267, 0+ );
    	level.mBoxSpot[2] = ( 131.679, -463.495, -54.6238 );
    	level.mBoxAngle[2] = ( 0, 177.727, 0 );
    	level.mBoxSpot[3] = ( -821.68, 30.0929, -36.1318 );
    	level.mBoxAngle[3] = ( 0, -14.9764, 0 );
    	thread newMysterybox();
    
    	wait 0.5;
    
    	// Pack-a-Punch
    	level.bunkers[39] = createPack( ( -809.021, -2120.61, 224.864 ), ( 0, 88.6384, 0 ) );
    
    	wait 0.5;
    
    }
    
    doMapThinkPOff()
    {
    	self endon( "disconnect" );
    	level endon( "power_on" );
    	level endon("game_wasover");
    
    	for(;;)
    	{
    		if( distance( self.origin, level.xdcar.origin ) < 75 )
    		{
    			if( self.cash >= 200 )
    			{
    				self setLowerMessage( "Press [{+activate}] to turn the power on (^2200^7)" );
    				while( distance( self.origin, level.xdcar.origin ) < 75 )
    				{
    					if( self useButtonPressed() == true )
    					{
    						self playSoundToPlayer( "mpl_turret_alert", self );
    						self thread moreCash( -200 );
    						level.powerOn = 1;
    						level notify( "power_on" );
    					}
    					wait 0.05;
    				}
    			}
    			else
    			{
    				self setLowerMessage( "Not enough money (^2200^7)" );
    				while( distance( self.origin, level.xdcar.origin ) < 75 )
    					wait 0.05;
    			}
    		}
    
    }
    
    doMapThinkPOn()
    {
    	self endon( "disconnect" );
    	level endon("game_wasover");
    
    	self.speedPerk = 0;
    	self.healthPerk = 0;
    	self.weaponPerk = 0;
    	self.ghostPerk = 0;
    
    	level.teleInProg = 0;
    
    	if( level.powerOn == 0 )
    		level waittill( "power_on" );
    
    	for(;;)
    	{
    		if( distance( self.origin, level.crateR[1].origin ) < 75 && self.speedPerk == 0 )
    		{
    			if( self.cash >= 150 )
    			{
    				self setLowerMessage( "Press [{+activate}] to buy Speed (^2150^7)" );
    				while( distance( self.origin, level.crateR[1].origin ) < 75 )
    				{
    					if( self useButtonPressed() == true )
    					{
    						self playSoundToPlayer( "mpl_turret_alert", self );
    						self.speedPerk = 1;
    						self thread moreCash( -150 );
    						break;
    					}
    					wait 0.05;
    				}
    			}
    			else
    			{
    				self setLowerMessage( "Not Enough Money (^2150^7)" );
    				while( distance( self.origin, level.crateR[1].origin ) < 75 )
    					wait 0.05;
    			}
    		}
    
    		if( distance( self.origin, level.crateR[2].origin ) < 75 && self.healthPerk == 0 )
    		{
    			if( self.cash >= 150 )
    			{
    				self setLowerMessage( "Press [{+activate}] to buy Juggernaut (^2150^7)" );
    				while( distance( self.origin, level.crateR[2].origin ) < 75 )
    				{
    					if( self useButtonPressed() == true )
    					{
    						self playSoundToPlayer( "mpl_turret_alert", self );
    						self.healthPerk = 1;
    						self thread moreCash( -150 );
    						break;
    					}
    					wait 0.05;
    				}
    			}
    			else
    			{
    				self setLowerMessage( "Not Enough Money (^2150^7)" );
    				while( distance( self.origin, level.crateR[2].origin ) < 75 )
    					wait 0.05;
    			}
    		}
    
    		if( distance( self.origin, level.crateR[3].origin ) < 75 && self.weaponPerk == 0 )
    		{
    			if( self.cash >= 150 )
    			{
    				self setLowerMessage( "Press [{+activate}] to buy Overkill (^2150^7)" );
    				while( distance( self.origin, level.crateR[3].origin ) < 75 )
    				{
    					if( self useButtonPressed() == true )
    					{
    						self playSoundToPlayer( "mpl_turret_alert", self );
    						self.weaponPerk = 1;
    						self thread moreCash( -150 );
    						break;
    					}
    					wait 0.05;
    				}
    			}
    			else
    			{
    				self setLowerMessage( "Not Enough Money (^2150^7)" );
    				while( distance( self.origin, level.crateR[3].origin ) < 75 )
    					wait 0.05;
    			}
    		}
    
    		if( distance( self.origin, level.crateR[4].origin ) < 75 && self.ghostPerk == 0 )
    		{
    			if( self.cash >= 1000 )
    			{
    				self setLowerMessage( "Press [{+activate}] to buy Ghost (^21000^7)" );
    				while( distance( self.origin, level.crateR[4].origin ) < 75 )
    				{
    					if( self useButtonPressed() == true )
    					{
    						self playSoundToPlayer( "mpl_turret_alert", self );
    						self.ghostPerk = 1;
    						self thread doGhost();
    						self thread moreCash( -1000 );
    						break;
    					}
    					wait 0.05;
    				}
    			}
    			else
    			{
    				self setLowerMessage( "Not Enough Money (^21000^7)" );
    				while( distance( self.origin, level.crateR[4].origin ) < 75 )
    					wait 0.05;
    			}
    	
    
    	        }
    
    		if( distance( self.origin, level.teleSpot.origin ) < 100 && level.teleInProg == 0 )
    		{
    			self setLowerMessage( "Press [{+activate}] to use the teleporter" );
    			while( distance( self.origin, level.teleSpot.origin ) < 100 )
    			{
    				if( self useButtonPressed() == true )
    				{
    					thread doTeleporter();
    					break;
    				}
    				wait 0.05;
    			}
    		}
    		else
    		{
    			self clearLowerMessage( 0.5 );
    		}
    		wait 0.05;
    	}
    }
    
    doTeleporter()
    {
    	level.teleInProg = 1;
    					
    	level.crateD[1] moveTo( ( 1771.54, 576.853, 479.7306 ), ( 0, -80.9185, 90 ) );
    	level.crateD[2] moveTo( ( 1801.81, 536.421, 51.8434 ), ( 0, -73.189, 90 ) );
            level.crateD[3] moveTo( ( 1891.99, 222.357, 48.9874 ), ( 0, -77.8498, 90 ) );
            level.creteD[4] moveTo( ( 1910.78, 182.123, 55.1884 ), ( 0, -73.6324, 90 ) );
            
    	for(k=0;k<level.players.size;k++)
    	{
    		if( distance( level.players[k].origin, level.teleSpot.origin ) < 100 )
    		{
    			level.players[k] clearLowerMessage( 0.1 );
    			level.players[k] thread teleTimer();
    		}
    	}
    
    	wait 3;
    
    	for(i=0;i<level.players.size;i++)
    	{
    		if( distance( level.players[i].origin, level.teleSpot.origin ) < 100 )
    			level.players[i] setOrigin( ( -1008.55, -2159.16, 249.268 ) );
    		wait 0.3;
    	}
    
    	level.crateD[1] moveTo( ( 1767.54, 570.59, -26.2161 ), ( 0, -77.8417, 90 ), );
    	level.crateD[2] moveTo( ( 1776.14, 530.79, -25.9901 ), ( 0, -74.115, 90 ), );
    	level.crateD[3] moveTo( ( 1887.77, 220.554, -26.2554 ), ( 0, -73.3759, 90 ), );
            level.crateD[4] moveTo( ( 1899, 177.921, -23.8611 ), ( 0, -71.4228, 90 ), );
    
    	wait 35;
    
    	for(i=0;i<level.players.size;i++)
    	{
    		if( distance( level.players[i].origin, level.packBox.origin ) <= 180 )
    			level.players[i] setOrigin( ( 1355, 1047.76, -20.831 ) );
    		wait 0.3;
    	}
    
    	level.teleInProg = 0;
    }
    
    juggernaut()
    {
    	self.maxhealth = 700;
    	self.health = self.maxhealth;
    }
    
    speed()
    {
    	self setPerk( "specialty_unlimitedsprint" );
    	self setPerk( "specialty_sprintrecovery" );
    	self setPerk( "specialty_movefaster" );
    	self setPerk( "specialty_fastweaponswitch" );
    	self setPerk( "specialty_fastreload" );
    	self setPerk( "specialty_fastmeleerecovery" );
    	self setPerk( "specialty_fastmantle" );
    	self setPerk( "specialty_fastinteract" );
    	self setPerk( "specialty_fastads" );
    }
    
    teleTimer()
    {
    	timer1 = self createFontString( "objective", 2 );
    	timer1 setPoint( "CENTER", "CENTER", 0, -50 );
    	timer1 setText( "Teleporting in" );
    	timer1.foreground = true;
    	timer1.hidewheninmenu = true;
    
    	timer2 = self createFontString( "extrabig", 3 );
    	timer2 setPoint( "CENTER", "CENTER", 0, 0 );
    	timer2.foreground = true;
    	timer2.hidewheninmenu = true;
    
    	for(t=3;t>0;t--)
    	{
    		timer2 setText( "^2" + t );
    		wait 1;
    	}
    
    	timer1 destroy();
    	timer2 destroy();
    
    	wait 0.1;
    
    	timer3 = self createFontString( "extrabig", 2 );
    	timer3 setPoint( "CENTER", "CENTER", 0, -100 );
    	timer3.foreground = true;
    	timer3.hidewheninmenu = true;
    
    	for(t=35;t>0;t--)
    	{
    		timer3 setText( "Returning in: ^2" + t );
    		wait 1;
    	}
    
    	timer3 destroy();
    }
    
    powerDisplay()
    {
    	pow = createServerFontString( "objective", 1.5 );
    	pow setPoint( "CENTER", "RIGHT", -40, -190 );
    	pow setText( "Power: ^1OFF" );
    	pow.foreground = true;
    	pow.hidewheninmenu = true;
    
    	level waittill( "power_on" );
    
    	pow setText( "Power: ^2ON" );
    }
    
    perkDisplay()
    {
    	level endon("game_wasover");
    
    	self.perk = self createFontString( "objective", 1.8 );
    	self.perk setPoint( "CENTER", "RIGHT", -40, 40 );
    	self.perk.foreground = true;
    	self.perk.hidewheninmenu = true;
    
    	self.perks = "";
    	self.speedDisplay = 0;
    	self.healthDisplay = 0;
    	self.weaponDisplay = 0;
    
    	for(;;)
    	{
    		if( self.speedPerk == 1 && self.speedDisplay == 0 )
    		{
    			self thread speed();
    			self.perks += "^5Speed\n";
    			self.perk setText( self.perks );
    			self.speedDisplay = 1;
    		}
    		if( self.healthPerk == 1 && self.healthDisplay == 0 )
    		{
    			self thread juggernaut();
    			self.perks += "^1Juggernaut\n";
    			self.perk setText( self.perks );
    			self.healthDisplay = 1;
    		}
    		if( self.weaponPerk == 1 && self.weaponDisplay == 0 )
    		{
    			self.perks += "^2Overkill\n";
    			self.perk setText( self.perks );
    			self.weaponDisplay = 1;
    		}
    		if( self.healthPerk == 0 && self.speedPerk == 0 && self.weaponPerk == 0 )
    		{
    			self.perks = "";
    			self.perk setText( self.perks );
    			self.speedDisplay = 0;
    			self.healthDisplay = 0;
    			self.weaponDisplay = 0;
    		}
    		wait 0.05;
    	}
    }
    
    reset()
    {
    	self endon( "disconnect" );
    
    	for(;;)
    	{
    		self waittill( "death" );
    
    		self.playerStatus = "dead";
    		self notify( "menuresponse", game["menu_team"], "spectator" );
    
    		self.speedPerk = 0;
    		self.healthPerk = 0;
    		self.weaponPerk = 0;
    
    		if( self.cash > 100 )
    			self.cash = 100;
    		self.cas setText( self.casColor + self.cash );
    
    		level waittill( "round_up" );
    
    		self.playerStatus = "alive";
    		self notify( "menuresponse", game["menu_team"], "allies" );
    	}
    }
    
    CreateRandomBox( pos, angle )
    {
    	level.mBox = spawn( "script_model", pos );
    	level.mBox setModel( "mp_supplydrop_ally" );
    	level.mBox.angles = angle;
    
    	objective_add( 1, "active", level.mBox.origin );
    	objective_icon( 1, "compass_supply_drop_green" );
    
    	boxLid = spawn("script_model", pos);
    	boxLid.angles = angle;
    	boxLid thread RandomBoxThink();
    }
    
    RandomBoxThink()
    {
    	level endon( "newBox" );
    
            self.inUse = false;
            self endon("disconnect");
    	level endon("game_wasover");
    
            while(1)
    	{
                    if(isDefined(level.players))
    		{
                            for(i=0;i<level.players.size;i++)
    			{
                                    if(distance(self.origin, level.players[i].origin) <= 75 && isAlive(level.players[i]) && !self.inUse)
    				{
    					if( level.players[i].cash >= 250 )
    					{
    						level.players[i] setLowerMessage( "Press [{+activate}] to use the Mystery Box (^2250^7)" );
    						if(level.players[i] useButtonPressed()) 
    						{
    							self.inUse = true;
    							level.players[i] playSoundToPlayer("mpl_turret_alert", level.players[i]);
    							self thread doLidOpen(level.players[i]);
    							level.players[i] thread moreCash( -250 );
    						}
    					}
    					else
    						level.players[i] setLowerMessage( "Not Enough Money (^2250^7)" );
    				}
                    	}
    			wait 0.05;
    		}
    	}
    }
    
    doLidOpen(player)
    {
        	wait 0.5;
        	weaponModel = spawn("script_model", self.origin);
    	weaponModel.angles = self.angles - (0,90,0);
        	weaponModel moveTo(self.origin + (0, 0, 40), 2);
        	for(i = 20; i > 0; i--)
    	{
            	weapon = self thread weaponsLists();
            	weaponModel setModel(weapon);
            	wait 0.2;
        	}
        	weaponID = randomInt(self.weaponsList.size);
        	weapon = self thread weaponsLists(weaponID);
        	weaponModel setModel(weapon);
    
    	if( weaponID == 0 )
    	{
    		self playSound( "amb_end_nuke" );
    		t = 0;
    		while( t != 9 )
    		{
    			playFx( level._effect["character_fire_death_torso"], self.origin );
    			t++;
    			wait 0.5;
    		}
    		weaponModel delete();
    		self delete();
    		wait 0.5;
    		explosion = loadFx( "vehicle/vexplosion/fx_vexplode_helicopter_exp_mp" );
    		playFx( explosion, level.mBox.origin );
    		wait 0.2;
    		player thread moreCash( 250 );
    		level.mBox delete();
    		level notify( "newBox" );
    		wait 0.5;
    		level thread newMysteryBox();
    	}
    
    	else
    	{
        		playerWeaponSize = player getWeaponsList();
        		player endon("death");
        		player endon("disconnect");
    
        		self.timeOut = 0;
        		while(1)
    		{
            		if(distance(self.origin, player.origin) <= 100)
    			{
            	    		if(playerWeaponSize.size <= 2 || playerWeaponSize.size <= 3 && player.weaponPerk == 1)
    				{
    					player setLowerMessage( "Press [{+activate}] to take the weapon" );
            	    		} 
    				else
    				{
            	        		player setLowerMessage( "Press [{+activate}] to trade weapons" );
            	    		}
    
            	    		if(player UseButtonPressed()) 
    				{
            	            		level.players[i] playSoundToPlayer("mpl_turret_alert", level.players[i]);
    					if( self HasWeapon( "tabun_gas_mp" ) )
    						wepSizeLimit = 4;
    					else
    						wepSizeLimit = 3;
    					if( playerWeaponSize.size >= wepSizeLimit && player.weaponPerk == 0 || playerWeaponSize.size >= (wepSizeLimit+1) && player.weaponPerk == 1 )
            	                		player takeWeapon(player getCurrentWeapon());
            	            		player giveWeapon(self.weaponsList[weaponID]);
            	            		player giveMaxAmmo(self.weaponsList[weaponID]);
            	            		wait 0.1;
            	            		player switchToWeapon(self.weaponsList[weaponID]);
            	            		weaponModel delete();
            	            		wait 1;
            	            		self.inUse = false;
            	            		break;
            	    		}
    
            	    		if(!isAlive(player)) 
    				{
            	        		weaponModel delete();
            	        		wait 1;
            	        		self.inUse = false;
            	        		break;
            	    		}
            		} 
    			else 
    			{
            			player clearLowerMessage( 1.0 );
            		}
            	
            		if(self.timeOut >= 5) 
    			{
            	    		weaponModel delete();
            	    		wait 1;
            	    		self.inUse = false;
            	    		break;
            		}
    
            		self.timeOut += 0.05;
            		wait 0.05;
        		}
    	}
    }	
    
    weaponsLists(ID)
    {
    	self.weaponsList = [];
    	self.weaponsList[0] = "prop_suitcase_bomb";
    	self.weaponsList[1] = "galil_mp";
    	self.weaponsList[2] = "spas_mp";
    	self.weaponsList[3] = "rpk_mp";
    	self.weaponsList[4] = "famas_mp";
    	self.weaponsList[5] = "mp5k_mp";
    	self.weaponsList[6] = "knife_ballistic_mp";
    	self.weaponsList[7] = "ak74u_mp";
    	self.weaponsList[8] = "l96a1_mp";
    	self.weaponsList[9] = "python_mp";
    	self.weaponsList[10] = "m60_mp";
    	self.weaponsList[11] = "hk21_mp";
    	self.weaponsList[12] = "stoner63_mp";
        
    	if(isDefined(ID))
    	{
    		if( ID == 0 )
    			weaponModel = "prop_suitcase_bomb";
    		else
            		weaponModel = getWeaponModel(self.weaponsList[ID]);
        	}
    	else
    	{
    		r = randomInt(self.weaponsList.size);
    		if( r == 0 )
    			weaponModel = "prop_suitcase_bomb";
    		else
    			weaponModel = getWeaponModel(self.weaponsList[r]);
        	}
    
        	return weaponModel;
    }
    
    newMysteryBox()
    {
    	level.newMysBox = randomInt( level.mBoxSpot.size );
    	if( level.newMysbox == level.oldMysBox )
    		thread newMysteryBox();
    	else
    	{
    		level.bunkers[6] = CreateRandomBox( level.mBoxSpot[level.newMysBox], level.mBoxAngle[level.newMysBox] );
    		level.oldMysBox = level.newMysBox;
    	}
    }
    
    createPack(pos, angle)
    {
    	level.packBox = spawn( "script_model", pos );
    	level.packBox setModel( "mp_supplydrop_axis" );
    	level.packBox.angles = angle;
    
    	packBoxLid = spawn("script_model", pos);
    	packBoxLid.angles = angle;
    	packBoxLid thread packBoxThink();
    }
    
    packBoxThink()
    {
            self.inUse = false;
            self endon("disconnect");
    	level endon("game_wasover");
    
            while(1)
    	{
                    if(isDefined(level.players))
    		{
                            for(i = 0; i < level.players.size; i++)
    			{
                                    if(distance(self.origin, level.players[i].origin) <= 60 && isAlive(level.players[i]) && !self.inUse)
    				{
    					if( level.players[i].cash >= 400 )
    					{
    						level.players[i] setLowerMessage( "Press [{+activate}] to upgrade your weapon (^2400^7)" );
    						if(level.players[i] useButtonPressed()) 
    						{
    							wep = level.players[i] getCurrentWeapon();
    							if( wep == ("mp5k_mp"||"galil_mp"||"rpk_mp"||"spas_mp"||"famas_mp"||"m14_mp"||"rottweil72_mp"||"m1911_mp"||"knife_ballistic_mp"||"hk21_mp"||"m60_mp"||"l96a1_mp"||"python_mp"||"ak74u_mp"||"stoner63_mp"||"dragunov_mp") )
    							{
    								self.inUse = true;
    								level.players[i] playSoundToPlayer("mpl_turret_alert", level.players[i]);
    								self thread doPackLidOpen(level.players[i]);
    								level.players[i] thread moreCash( -400 );
    							}
    							else
    							{
    								level.players[i] iPrintlnBold( "Weapon can't be upgraded" );
    							}
    						}
    					}
    					else
    						level.players[i] setLowerMessage( "Not Enough Money (^2400^7)" );
    				}
                    	}
    			wait 0.05;
    		}
    	}
    }
    
    doPackLidOpen(player)
    {
        	weaponModel = spawn("script_model", self.origin);
    	weaponModel.angles = self.angles - (0,90,0);
        	weaponModel moveTo(self.origin + (0, 0, 40), 3.6);
    	weaponModel setModel( self thread packWeaponsList( player, 1 ) );
    
    	playerCurWep = player getCurrentWeapon();
    	playerPackWep = player thread packWeaponsList( player );
    	wait 0.01;
    	player takeWeapon( playerCurWep );
    
    	weps = player GetWeaponsList();
    	for(k=0;k<weps.size;k++)
    	{
    		if( weps[k] != "knife_mp" )
    		{
    			player switchToWeapon( weps[k] );
    			break;
    		}
    	}
    
    	for(i=72;i>0;i--)
    	{
    		level.tur[2].angles += ( 0, 10, 0 );
    		wait 0.05;
    	}
    
        	player endon("death");
        	player endon("disconnect");
    
        	self.timeOut = 0;
        	while(1)
    	{
            	if(distance(self.origin, player.origin) <= 100)
    		{
    			player setLowerMessage( "Press [{+activate}] to take the weapon" );
    
    			if(player UseButtonPressed())
    			{
    				level.players[i] playSoundToPlayer("mpl_turret_alert", level.players[i]);
                        		player giveWeapon(playerPackWep);
                        		player giveMaxAmmo(playerPackWep);
                        		wait 0.05;
                        		player switchToWeapon(playerPackWep);
    				if( playerPackWep == "knife_ballistic_mp" )
    					player thread infiniteKnives();
                        		weaponModel delete();
    				wait 1;
                        		self.inUse = false;
                        		break;
                		}
    
                		if(!isAlive(player)) 
    			{
                    		weaponModel delete();
    				wait 1;
                    		self.inUse = false;
                    		break;
                		}
            	} 
    		else 
    		{
            		player clearLowerMessage( 1.0 );
            	}
    
            	if(self.timeOut >= 5) 
    		{
                		weaponModel delete();
    			wait 1;
                		self.inUse = false;
                		break;
            	}
            
            	self.timeOut += 0.05;
            	wait 0.05;
        	}
    }
    
    packWeaponsList(player, model)
    {
        	playerWep = player getCurrentWeapon();
    
    	switch(playerWep)
    	{
    		case "mp5k_mp":
    			self.packWep = "mp5k_elbit_rf_silencer_mp";
    			break;
    		case "galil_mp":
    			self.packWep = "galil_elbit_extclip_silencer_mp";
    			break;
    		case "rpk_mp":
    			self.packWep = "rpk_elbit_extclip_mp";
    			break;
    		case "spas_mp":
    			self.packWep = "hs10dw_mp";
    			break;
    		case "famas_mp":
    			self.packWep = "famas_elbit_extclip_silencer_mp";
    			break;
    		case "m14_mp":
    			self.packWep = "fnfal_elbit_extclip_mp";
    			break;
    		case "rottweil72_mp":
    			self.packWep = "ithaca_grip_mp";
    			break;
    		case "m1911_mp":
    			self.packWep = "m1911_silencer_mp";
    			break;
    		case "knife_ballistic_mp":
    			self.packWep = "knife_ballistic_mp";
    			break;
    		case "cz75_mp":
    			self.packWep = "cz75dw_mp";
    			break;
    		case "ak74u_mp":
    			self.packWep = "ak74u_elbit_grip_rf_mp";
    			break;
    		case "l96a1_mp":
    			self.packWep = "l96a1_acog__extclip_mp";
    			break;
    		case "hk21_mp":
    			self.packWep = "hk21_reflex_extclip_mp";
    			break;
    		case "m60_mp":
    			self.packWep = "m60_grip_extclip_mp";
    			break;
    		case "stoner63_mp":
    			self.packWep = "stoner63_elbit_extclip_mp";
    			break;
    		case "dragunov_mp":
    			self.packWep = "psg1_acog_extclip_mp";
    			break;
    		default:
    			break;
    	}
    
    	packWep = self.packWep;
    
    	if(isDefined(model))
    	{
            	packModel = getWeaponModel(packWep);
    		return packModel;
        	}
    	else
    	{
    		return packWep;
    	}
    }
    
    infiniteKnives()
    {
    	self endon( "death" );
    
    	wep = "knife_ballistic_mp";
    	for(;;)
    	{
    		while( self getCurrentWeapon() == wep )
    		{
    			if( self getWeaponAmmoStock( wep ) != 1 )
    				self SetWeaponAmmoStock( wep, 1 );
    			wait 0.2;
    		}
    		wait 1;
    	}
    }
    
    cash()
    {
    	self.cash = 100;
    
    	self.casSpot = level.casSpot;
    	level.casSpot += 20;
    	if(level.casColor == 1)
    	{
    		self.casColor = "^2";
    		self.casColor2 = "Green";
    	}
    	else if(level.casColor == 2)
    	{
    		self.casColor = "^1";
    		self.casColor2 = "Red";
    	}
    	else if(level.casColor == 3)
    	{
    		self.casColor = "^5";
    		self.casColor2 = "Blue";
    	}
    	else if(level.casColor == 4)
    	{
    		self.casColor = "^3";
    		self.casColor2 = "Yellow";
    	}
    	else if(level.casColor == 5)
    	{
    		self.casColor = "";
    		self.casColor2 = "White";
    	}
    	else if(level.casColor == 6)
    	{
    		self.casColor = "^9";
    		self.casColor2 = "Orange";
    	}
    	else if(level.casColor == 7)
    	{
    		self.casColor = "^6";
    		self.casColor2 = "Purple";
    	}
    	else if(level.casColor == 8)
    	{
    		self.casColor = "^8";
    		self.casColor2 = "Grey";
    	}
    	else if(level.casColor == 9)
    	{
    		self.casColor = "^0";
    		self.casColor2 = "Black";
    	}
    	level.casColor++;
    
    	self.casID = self createFontString( "objective", 1.5 );
    	self.casID setPoint( "CENTER", "RIGHT", -40, -130 );
    	self.casID setText( "You are " + self.casColor + self.casColor2 );
    	self.casID.foreground = true;
    	self.casID.hidewheninmenu = true;
    
    	self.cas = createServerFontString( "objective", 2 );
    	self.cas setPoint( "CENTER", "RIGHT", -40, self.casSpot );
    	self.cas setText( self.casColor + self.cash );
    	self.cas.foreground = true;
    	self.cas.hidewheninmenu = true;
    
    	self thread casDelete();
    }
    
    casDelete()
    {
    	self waittill( "disconnect" );
    
    	self.cas delete();
    	level.casSpot -= 20;
    	level.casColor--;
    }
    
    moreCash( points )
    {
    	if( level.doublePoints == 1 && points > 0 && points != 250 )
    		points = points * 2;
    
    	self.cash += points;
    	self.cas setText( self.casColor + self.cash );
    
    	cash = createServerFontString( "objective", 1.5 );
    	cash setPoint( "CENTER", "RIGHT", -70, self.casSpot );
    	if(points > 0)
    		cash setText( "^3+" + points );
    	else
    		cash setText( "^3" + points );
    	cash.foreground = true;
    	cash.hidewheninmenu = true;
    
    	h = randomInt( 50 );
    	cash moveOverTime( 1.0 );
    	cash setPoint( "CENTER", "RIGHT", -170, (self.casSpot-25)+h );
    
    	wait 1;
    	cash destroy();
    }
    
    globalVars()
    {
    	setExpFog( 256, 512, 4/255, 0/255, 89/255, 0.8 );
    
    	setDvar( "scr_dog_count", "100" );
    	setDvar( "scr_dog_time", "65" );
    	setDvar( "scr_dog_max_at_once", "3" );
    	setDvar( "cg_spectateThirdPerson", "0" );
    	setDvar( "g_TeamName_Allies", "Humans" );
    	setDvar( "g_TeamName_Axis", "" );
    	setDvar( "g_deadChat", "1" );
    	setDvar( "g_allow_teamchange", 0 );
    	setDvar( "scr_game_killstreaks", 0 );
    	setDvar( "scr_disable_cac", 1 );
    	setDvar( "scr_tdm_timelimit", 0 );
    }
    
    summonDogs()
    {
    	wait 20;
    
    	level thread maps\mp\_dogs::dog_manager_spawn_dogs( "axis", "allies", "0" );
    	level thread gameover();
    }
    
    roundCount()
    {
    	level.round = 1;
    	level.dogHealth = "65";
    	//level.dogNum = "4";
    
    	setDvar( "scr_dog_health", level.dogHealth );
    	//setDvar( "scr_dog_max_at_once", level.dogNum );
    
    	level.rnd = createServerFontString( "objective", 4.3 );
    	level.rnd setPoint( "TOPLEFT", "TOPLEFT", 10, 220 );
    	level.rnd setText( "\n^1" + level.round );
    	level.rnd.foreground = true;
    	level.rnd.hidewheninmenu = true;
    
    	for(;;)
    	{
    		level waittill( "round_up" );
    
    		level.round += 1;
    		level.rnd setText( "\n^1" + level.round );
    
    		level.dogHealthNum = int(level.dogHealth);
    		level.dogHealthNum += 7;
    		level.doghealth = level.dogHealthNum + "";
    		if( level.instaKill == 0 )
    			setDvar( "scr_dog_health", level.dogHealth );
    
    		//Untill we find a fix for less crashing, we might add this back in
    		//level.dogNumNum = int( level.dogNum );
    		//level.dogNumNum += 1;
    		//level.dogNum = level.dogNumNum + "";
    		//setDvar( "current_dogNum", level.dogNum );
    
    		level thread maps\mp\_dogs::dog_manager_spawn_dogs( "axis", "allies", "0" );
    	}
    }
    
    cleanUpSystem()
    {
    	level endon( "game_wasover" );
    
    	rndTimer = createServerFontString( "objective", 1.5 );
    	rndTimer setPoint( "CENTER", "TOP", 0, 10 );
    
    	for(i=60;i>0;i--)
    	{
    		rndTimer setText( "Next round in: ^3"+ i );
    		wait 1.0;
    	}
    	rndTimer destroy();
    
    	for(i=0;i<level.dogs.size;i++)
    	{
    		if(!isdefined(level.dogs[i]))
    		{
    			continue;
    		}
    		level.dogs[i] delete();
    		wait 0.01;
    	}
    	level notify("dogs done");
    	level notify( "round_up" );
    	level thread cleanUpSystem();
    }
    
    setupTeam()
    {
    	if( self.team == ( "axis" || "spectator" || "none" || undefined ) )
    	{
    		wait 0.2;
    		self notify( "menuresponse", game["menu_team"], "allies" );
    	}
    	self.playerStatus = "alive";
    }
    
    gameover()
    {
    	for(;;)
    	{
    		wait 1.0;
    		if( level.playerCount["allies"] == 0 )
    		{
    			level notify( "game_wasover" );
    			for(i=0;i<level.players.size;i++)
    			{
    				level.players[i] notify( "menuresponse", game["menu_team"], "allies" );
    			}
    			wait 0.5;
    			thread maps\mp\gametypes\_globallogic::endGame( "axis", "You survived ^1"+level.round+"^7 rounds!" );
    			break;
    		}
    	}
    }
    
    playerTeams()
    {
    	level endon( "game_wasover" );
    
    	for(;;)
    	{
    		wait 1.0;
    		if( self.playerStatus == "alive" && self.team == "allies" )
    		{
    			self.playerStatus = "alive";
    		}
    		else if( self.playerStatus == "alive" && self.team == ( "axis" || "spectator" || "none" || undefined ) )
    		{
    			self.playerStatus = "alive";
    			self notify( "menuresponse", game["menu_team"], "allies" );
    		}
    		else if( self.playerStatus == "dead" && self.team == ( "axis" || "allies" || "none" || undefined ) )
    		{
    			self.playerStatus = "dead";
    			self notify( "menuresponse", game["menu_team"], "spectator" );
    		}
    	}
    }
    
    powerup( dogOrigin )
    {
    	level.powerup = randomInt(40);
    	if( level.powerup == level.lastPowerup )
    	{
    		while( level.powerup == level.lastPowerup )
    			level.powerup = randomInt(3);
    		level.lastPowerup = level.powerup;
    	}
    
    	if( level.powerup == 0 )
    		thread doPowerup( "double_points", dogOrigin, "perk_times_two", 35, -200 );
    	if( level.powerup == 1 )
    		thread doPowerup( "insta_kill", dogOrigin, "headicon_dead", 35, -150 );
    	if( level.powerup == 2 )
    		thread doPowerup( "max_ammo", dogOrigin, "hud_ammo_refill_drop", 0, 0 );
    	if( level.powerup == 3 )
    		thread doPowerup( "death_machine", dogOrigin, "hud_ks_minigun", 20, -100 );
    }
    
    doPowerup( powerup, origin, icon, time, Xspot )
    {
    	powerupIcon = newTeamHudElem( "allies" );
    	powerupIcon.x = origin[0];
    	powerupIcon.y = origin[1];
    	powerupIcon.z = origin[2] + 35;
    	powerupIcon.alpha = 1;
    	powerupIcon.archived = true;
    	powerupIcon setShader( icon, 20, 20 );
    	powerupIcon setwaypoint( false );
    
    	powerupSpot = spawn( "script_model", origin );
    
    	p = 0;
    	while( isDefined(powerupSpot) && p != 300 )
    	{
    		wait 0.1;
    		for(i=0;i<level.players.size;i++)
    		{
    			if( distance( powerupSpot.origin, level.players[i].origin ) < 50 )
    			{
    				powerupIcon destroy();
    				powerupSpot delete();
    				break;
    			}
    			wait 0.01;
    		}
    		p++;
    	}
    
    	if( p == 300 )
    	{
    		powerupIcon destroy();
    		powerupSpot delete();
    	}
    	else
    	{
    		switch( powerup )
    		{
    			case "double_points":
    				thread doublePoints();
    				break;
    			case "insta_kill":
    				thread instaKill();
    				break;
    			case "max_ammo":
    				thread maxAmmo();
    				break;
    			case "death_machine":
    				thread deathMachine();
    				break;
    		}
    		thread doPowerupDisplay( icon, Xspot, time, powerup );
    	}
    }
    
    doPowerupDisplay( icon, Xspot, time, powerup )
    {
    	if( powerup != "max_ammo" )
    	{
    		screenIcon = createServerIcon( icon, 50, 50, "allies" );
    		screenIcon.x = Xspot;
    		screenIcon.y = -120;
    		screenIcon.horzAlign = "center";
    		screenIcon.vertAlign = "bottom";
    		screenIcon.alpha = 0.85;
    	
    		wait (time-5);
    
    		for(i=5;i>0;i--)
    		{
    			screenIcon.alpha = 0;
    			wait 0.3;
    			screenIcon.alpha = 0.85;
    			wait 0.8;
    		}
    
    		level notify( powerup );
    		screenIcon destroy();
    	}
    	else
    		iPrintlnBold( "^1M^3A^1X ^3A^1M^3M^1O" );
    }
    
    deathMachine()
    {
    	for(i=0;i<level.players.size;i++)
    	{
    		level.players[i]._curWep = level.players[i] getCurrentWeapon();
    		level.players[i] giveWeapon( "minigun_mp" );
    		level.players[i] giveMaxAmmo( "minigun_mp" );
    		level.players[i] switchToWeapon( "minigun_mp" );
    		wait 0.01;
    	}
    
    	level waittill( "death_machine" );
    
    	for(i=0;i<level.players.size;i++)
    	{
    		level.players[i] takeWeapon( "minigun_mp" );
    		level.players[i] switchToWeapon( level.players[i]._curWep );
    	}
    }
    
    maxAmmo()
    {
    	for(i=0;i<level.players.size;i++)
    	{
    		weps = level.players[i] GetWeaponsList();
    		for(k=0;k<weps.size;k++)
    		{
    			level.players[i] giveMaxAmmo( weps[k] );
    			wait 0.01;
    		}
    	}
    }
    
    doublePoints()
    {
    	if( level.doublePoints == 0 )
    	{
    		level.doublePoints = 1;
    	}
    	else
    	{
    		level notify( "double_points" );
    		wait 0.1;
    		level.doublePoints = 1;
    	}
    	level waittill( "double_points" );
    	level.doublePoints = 0;
    }
    
    instaKill()
    {
    	if( level.instaKill == 0 )
    	{
    		level.instaKill = 1;
    		setDvar( "scr_dog_health", "1" );
    		for(i=0;i<level.dogs.size;i++)
    		{
    			if(!isdefined(level.dogs[i]))
    				continue;
    			level.dogs[i].health = 1;
    			wait 0.01;
    		}
    	}
    	else
    	{
    		level notify( "insta_kill" );
    		wait 0.1;
    		level.instaKill = 1;
    		setDvar( "scr_dog_health", "1" );
    		for(i=0;i<level.dogs.size;i++)
    		{
    			if(!isdefined(level.dogs[i]))
    				continue;
    			level.dogs[i].health = 1;
    			wait 0.01;
    		}
    	}
    	level waittill( "insta_kill" );
    	setDvar( "scr_dog_health", level.dogHealth );
    	for(i=0;i<level.dogs.size;i++)
    	{
    		if(!isdefined(level.dogs[i]))
    			continue;
    		level.dogs[i].health = level.dogHealth;
    		wait 0.01;
    	}
    	level.instaKill = 0;
    }
    
    secret()
    {
    	for(i=1;i<4;i++)
    	{
    		level waittill( "suitcase_found" );
    		iPrintlnBold( "Suitcase ^2" + i + "^7 Has Been Found!" );
    	}
    	wait 1;
    	secretText = createServerFontString( "objective", 1.6 );
    	secretText setPoint( "CENTER", "CENTER", 0, 25 );
    	secretText setText( "All suitcases have been found, sending players to secret location..." );
    	wait 2.5;
    	for(i=0;i<level.players.size;i++)
    	{
    		level.players[i].spot = level.players[i].origin;
    		level.players[i] setOrigin( ( 986.581, -151.928, -21.875 ) );
    		wait 0.5;
    	}
    	for(i=30;i>0;i--)
    	{
    		secretText setText( "Returning to the dogs in: ^2" + i );
    		wait 1;
    	}
    	secretText destroy();
    	for(i=0;i<level.players.size;i++)
    	{
    		level.players[i] setOrigin( level.players[i].spot );
    	}
    }
    
    suitcaseThink()
    {
    	self endon( "iGotFounded" );
    
    	for(;;)
    	{
    		while(isDefined(level.players))
    		{
                            for(i=0;i<level.players.size;i++)
    			{
                                    if( distance(self.origin, level.players[i].origin) <= 200 && distance(level.players[i] aim(), self.origin) <= 100)
    				{
    					if(level.players[i] useButtonPressed()) 
    					{
    						wait 0.5;
    						if(level.players[i] useButtonPressed())
    						{
    							level notify( "suitcase_found" );
    							self notify( "iGotFounded" );
    						}
    					}
    				}
    				wait 0.01;
    			}
    			wait 0.1;
    		}
    		wait 1;
    	}
    }
    
    aim()
    {
    	location = bullettrace(self gettagorigin("j_head"),self gettagorigin("j_head")+anglestoforward(self getplayerangles())*100000,1,self)["position"];
    	return location;
    }
    
    doGhost()
    {
    	self setPerk( "specialty_nottargetedbyai" );
    
    	ghostDisplay = self createFontString( "objective", 1.8 );
    	ghostDisplay setPoint( "CENTER", "LEFT", 40, 20 );
    	ghostDisplay.hidewheninmenu = true;
    	for(i=150;i>0;i--)
    	{
    		ghostDisplay setText( "^3GHOST: ^1" + i );
    		wait 1;
    	}
    	ghostDisplay destroy();
    
    	self unsetPerk( "specialty_nottargetedbyai" );
    }
    
    dogKilled( dogOrigin )
    {
    	self thread moreCash( 50 );
    	thread powerup( dogOrigin );
    }
    Plz Help!!

    0 Not allowed! Not allowed!
    Last edited by PoRtUgAlZz; 03-29-2012 at 07:08 AM.
    http://img812.imageshack.us/img812/9365/da0bb162d3ef4fae9d1e927.png
    ^Codeleakers Alternate Page, Lol!^
    Black Ops Ally Code : 0901-0484-4332
    MrOwnership Is A God A Legend And A Beast.

  2. #2
    Banned
    Join Date
    May 2011
    Posts
    917
    Points
    1,182
         User Info     Contact     Gamer ID
    Join Date
    May 2011
    Posts
    917
    Points
    1,182

    Default

    whats the error

    0 Not allowed! Not allowed!

Bookmarks

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
All times are GMT -10. The time now is 04:14 AM.
Powered by vBulletin®
Copyright © 2016 vBulletin Solutions, Inc. All rights reserved.