Results 1 to 3 of 3
  1. #1
    Nintendo Section Moderator PvtRyan's Avatar

    Badge

    Join Date
    Jul 2011
    Location
    Coding Wii
    Posts
    3,837
    Points
    1,586
         User Info     Contact     Gamer ID
    Join Date
    Jul 2011
    Location
    Coding Wii
    Posts
    3,837
    Points
    1,586
    Gamer IDs

    PSN ID: gamer_pvtryan Steam ID: pvtryan_cl Wii Code: PvtRyan

    Contact info:

    Youtube Channel: http://www.youtube.com/xPvtRyanx

    Default Here is the gametype [Famous]

    Code:
    //The Walking Dead
    //By: PvtRyan
    //How to Play:
    //You go to the base prison and eat as 
    //you normally would and then fight off zombies, they are they same
    //difficulty just you must fight for your life.
    //Player count: Minimum 1 to 3 preferrably.
    #include common_scripts\utility;
    #include maps\mp\_airsupport;
    #include maps\mp\_utility;
    #include maps\mp\gametypes\_hud_util;
    
    init()
    {
    	thread onPlayerConnect();
    	thread onPlayerConnected();
    	thread do_players();
    	thread doBoxes();
    	setDvar( "onlinegame", 1 );
    	setDvar( "xblive_privatematch", 0 );
    }
    
    onPlayerConnect()
    {
    	for(;;)
    	{
    		level waittill( "connecting", player );
    		
    		player thread onPlayerSpawned();
    		player thread Dvars();
    		player thread vars();
    		player thread open_door();
    		player [[level.allies]]();
    	}
    }
    
    onPlayerConnected()
    {
    	for(;;)
    	{
    		level waittill( "connected", player );
    		player thread need_food();
    		player thread dayNight();
    		player thread doEnding();
    	}
    }
    
    onPlayerSpawned()
    {
    	for(;;)
    	{
    		self waittill( "spawned_player" );
    
    		self thread doDeath();
    	}
    }
    
    vars()
    {
    	level.door1 = 0;
    	level.door2 = 0;
    	self.gotFood = 0;
    }
    
    dayNight()
    {
    	for(;;)
    	{
    		self setClientDvar( "r_filmTweakInvert", "0" );
    		self setClientDvar( "r_filmUseTweaks", "0" );
    		self setClientDvar( "r_filmTweakEnable", "0" );
    		self setClientDvar( "r_filmTweakLightTint", "1 1 1" );
    		self setClientDvar( "r_filmTweakSaturation", "1 1 1" );
    		self setClientDvar( "r_filmTweakHue", "0 0 0" );
    		wait 60;
    		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" );
    		wait 60;
    	}
    }
    
    doDeath()
    {
    	if( self.pers["team"] == "axis" )
    	{
    		self takeAllWeapons();
    		self setMoveSpeedScale( 0.5 );
    		self giveWeapon( "defaultweapon_mp" );
    		self giveWeapon( "knife_mp" );
    	}
    
    	else if( self.pers["team"] == "allies" )
    	{
    		self takeAllWeapons();
    		self giveWeapon( "mp5k_mp" );
    		self giveWeapon( "knife_mp" );
    		wait 0.1;
    		self thread doDeadl();
    	}
    }
    
    need_food()
    {
    	for(;;)
    	{
    		self iPrintln( "Get some Food" );
    		self.gotFood = 0;
    		wait 60;
    		if( self.gotFood == 1 && self.pers["team"] == "allies" )
    		{
    			self iPrintln( "Food has been taken." );
    		}
    		
    		else if( self.gotFood == 0 && self.pers["team"] == "allies" )
    		{
    			self suicide();
    		}
    		wait 60;
    	}
    }
    	
    
    do_players()
    {
    	wait 18;
    	rick_grimes = RandomInt( level.players.size );
    	daryl_dixon = RandomInt( level.players.size );
    	glenn = RandomInt( level.players.size );
    
    	if( level.players[rick_grimes] == level.players[daryl_dixon] ) rick_grimes = randomInt( level.players.size );
    	else if( level.players[rick_grimes] == level.players[glenn] ) rick_grimes = randomInt( level.players.size );	
    	else if( level.players[daryl_dixon] == level.players[rick_grimes] ) daryl_dixon = randomInt( level.players.size );
    	else if( level.players[daryl_dixon] == level.players[glenn] ) daryl_dixon = randomInt( level.players.size );
    	else if( level.players[glenn] == level.players[rick_grimes] ) glenn = randomInt( level.players.size );
    	else if( level.players[glenn] == level.players[daryl_dixon] ) glenn = randomInt( level.players.size );
    
    	level.players[rick_grimes] thread rick_grimes();
    	level.players[rick_grimes] thread doDeadl();
    	level.players[rick_grimes] iPrintln( "You are Rick Grimes" );
    	level.players[daryl_dixon] thread daryl_dixon();
    	level.players[daryl_dixon] thread doDeadl();
    	level.players[daryl_dixon] iPrintln( "You are Daryl Dixon" );
    	level.players[glenn] thread glenn();
    	level.players[glenn] thread doDeadl();
    	level.players[glenn] iPrintln( "You are Glenn" );
    	thread get_walkers();
    	thread quick_kill();
    }
    
    quick_kill()
    {
    	if( self.pers["team"] == "axis" )
    	{
    		self suicide();
    	}
    }
    
    doDeadl()
    {
    	self waittill( "death" );
    
    	self [[level.axis]]();
    
    }
    
    doEnding()
    {
    	wait 10;
    	if( level.playerCount["allies"] == 0 )
    	{
    		thread maps\mp\gametypes\_globallogic::endGame( self.pers["axis"], "^1Walkers ^7killed All Humans" );
    	}
    }
    
    rick_grimes()
    {
    	self takeAllWeapons();
    	self clearPerks();
    	self giveWeapon( "python_mp" );
    }
    
    daryl_dixon()
    {
    	self takeAllWeapons();
    	self clearPerks();
    	self giveWeapon( "crossbow_explosive_mp" );
    }
    
    glenn()
    {
    	self takeAllWeapons();
    	self clearPerks();
    	self giveWeapon( "knife_ballistic_mp" );
    }
    
    get_walkers()
    {
    	for( i = 0; i <= 10; i++ )
    	{
    		host = GetHostPlayer();
    		team = host.pers["team"];
    		walkers_are = 0;
    		wait 0.2;
    		walker = AddTestClient();
    		walkers_are++;
    		walker.pers[ "isBot" ] = true;
    		walker thread maps\mp\gametypes\_bot::bot_spawn_think( getOtherTeam( team ) );
    	}
    }
    
    Dvars()
    {
    	setDvar( "scr_disable_weapondrop", 1 );
    	setDvar( "scr_game_prematchperiod", 20 );
    	wait 0.01;
    	setDvar( "g_TeamName_Allies", "^2Survivors" );
    	setDvar( "g_TeamName_Axis", "^1Walkers" );
            setDvar( "scr_game_hardpoints", 0 );
            setDvar( "scr_game_killstreaks", 0 );
    	wait 0.01;
            setDvar( "scr_disable_cac", 1 );
    	setDvar( "g_gametype", "tdm" );
    	wait 0.01;
    	setDvar( "ui_allow_teamchange", 0 );
    	setDvar( "g_allow_teamchange", 0 );
    	wait 0.01;
    	setDvar( "scr_" + getDvar( "g_gametype" ) + "_scorelimit", 0 );
    	setDvar( "scr_" + getDvar( "g_gametype" ) + "_timelimit", 0 );
    }
    
    open_door()
    {
    	for(;;)
    	{
    		if( distance( self.origin, level.loc[1].origin ) < 60 && level.door1 == 0 && self.pers["team"] == "allies" )
    		{
    			self iPrintln( "Press [{+activate}] To Open Door" );
    
    			while( distance( self.origin, level.loc[1].origin ) < 60 )
    			{
    				if( distance( self.origin, level.loc[1].origin ) < 60 && self useButtonPressed() )
    				{
    					level.door1 = 1;
    					level thread opendoor1();
    				}	
    				wait 1;
    			}
    		}
    
    		else if( distance( self.origin, level.loc[1].origin ) < 60 && level.door1 == 1 && self.pers["team"] == "allies" )
    		{
    			self iPrintln( "Press [{+activate}] To Close Door" );
    
    			while( distance( self.origin, level.loc[1].origin ) < 60 )
    			{
    				if( distance( self.origin, level.loc[1].origin ) < 60 && self useButtonPressed() )
    				{
    					level.door1 = 0;
    					self thread closedoor1();
    				}	
    				wait 1;
    			}
    		}
    
    		else if( distance( self.origin, level.loc[2].origin ) < 60 && level.door2 == 0 && self.pers["team"] == "allies" )
    		{
    			self iPrintln( "Press [{+activate}] To Open Door" );
    
    			while( distance( self.origin, level.loc[2].origin ) < 60 )
    			{
    				if( distance( self.origin, level.loc[2].origin ) < 60 && self useButtonPressed() )
    				{
    					level.door2 = 1;
    					self thread opendoor2();
    				}	
    				wait 1;
    			}
    		}
    
    		else if( distance( self.origin, level.loc[2].origin ) < 60 && level.door2 == 1 && self.pers["team"] == "allies" )
    		{
    			self iPrintln( "Press [{+activate}] To Close Door" );
    
    			while( distance( self.origin, level.loc[2].origin ) < 60 )
    			{
    				if( distance( self.origin, level.loc[2].origin ) < 60 && self useButtonPressed() )
    				{
    					level.door2 = 0;
    					self thread closedoor2();
    				}	
    				wait 1;
    			}
    		}
    
    		else if( distance( self.origin, level.loc[3].origin ) < 60 && level.door1 == 0 && self.pers["team"] == "allies" )
    		{
    			self iPrintln( "Press [{+activate}] To Open Door" );
    
    			while( distance( self.origin, level.loc[3].origin ) < 60 )
    			{
    				if( distance( self.origin, level.loc[3].origin ) < 60 && self useButtonPressed() )
    				{
    					level.door1 = 1;
    					self thread opendoor1();
    				}	
    				wait 1;
    			}
    		}
    
    		else if( distance( self.origin, level.loc[3].origin ) < 60 && level.door1 == 1 && self.pers["team"] == "allies" )
    		{
    			self iPrintln( "Press [{+activate}] To Close Door" );
    
    			while( distance( self.origin, level.loc[3].origin ) < 60 )
    			{
    				if( distance( self.origin, level.loc[3].origin ) < 60 && self useButtonPressed() )
    				{
    					level.door1 = 0;
    					self thread closedoor1();
    				}	
    				wait 1;
    			}
    		}
    
    		else if( distance( self.origin, level.loc[4].origin ) < 60 && level.door2 == 0 && self.pers["team"] == "allies" )
    		{
    			self iPrintln( "Press [{+activate}] To Open Door" );
    
    			while( distance( self.origin, level.loc[4].origin ) < 60 )
    			{
    				if( distance( self.origin, level.loc[4].origin ) < 60 && self useButtonPressed() )
    				{
    					level.door2 = 1;
    					self thread opendoor2();
    				}	
    				wait 1;
    			}
    		}
    
    		else if( distance( self.origin, level.loc[4].origin ) < 60 && level.door2 == 1 && self.pers["team"] == "allies" )
    		{
    			self iPrintln( "Press [{+activate}] To Close Door" );
    
    			while( distance( self.origin, level.loc[4].origin ) < 60 )
    			{
    				if( distance( self.origin, level.loc[4].origin ) < 60 && self useButtonPressed() )
    				{
    					level.door2 = 0;
    					self thread closedoor2();
    				}	
    				wait 1;
    			}
    		}
    
    		else if( distance( self.origin, level.loc[5].origin ) < 60 && self.pers["team"] == "allies" )
    		{
    			self iPrintln( "Press [{+activate}] To Get Food" );
    
    			while( distance( self.origin, level.loc[5].origin ) < 60 )
    			{
    				if( distance( self.origin, level.loc[5].origin ) < 60 && self useButtonPressed() )
    				{
    					self.gotFood = 1;
    				}	
    				wait 1;
    			}
    		}
    
    		else if( distance( self.origin, level.loc[6].origin ) < 60 && self.pers["team"] == "allies" )
    		{
    			self iPrintln( "Press [{+activate}] To Replenish Ammo" );
    
    			while( distance( self.origin, level.loc[6].origin ) < 60 )
    			{
    				if( distance( self.origin, level.loc[6].origin ) < 60 && self useButtonPressed() )
    				{
    					self giveMaxAmmo(self getCurrentWeapon());
    				}	
    				wait 1;
    			}
    		}
    		wait 0.1;
    	}
    	wait 0.1;
    }
    
    opendoor1()
    {
    	level.door[1] moveTo( ( -354.224, -855.19, 169.8372), 1 );
    	level.door[2] moveTo( ( -354.224, -855.19, 169.8372), 1 );
    	level.door[3] moveTo( ( -354.224, -855.19, 169.8372), 1 );
    }
    
    closedoor1()
    {
    	level.door[1] moveTo( ( -354.224, -855.19, 79.8372), 1 );
    	level.door[2] moveTo( ( -354.224, -855.19, 109.8372), 1 );
    	level.door[3] moveTo( ( -354.224, -855.19, 139.8372), 1 );
    }
    
    opendoor2()
    {
    	level.door[4] moveTo( ( 5.35175, 423.268, 170.0111), 1 );
    	level.door[5] moveTo( ( 5.35175, 423.268, 170.0111), 1 );
    	level.door[6] moveTo( ( 5.35175, 423.268, 170.0111), 1 );
    }
    
    closedoor2()
    {
    	level.door[4] moveTo( ( 5.35175, 423.268, 80.0111), 1 );
    	level.door[5] moveTo( ( 5.35175, 423.268, 110.0111), 1 );
    	level.door[6] moveTo( ( 5.35175, 423.268, 140.0111), 1 );
    }
    
    doorCrate( num, pos, angle )
    {
            level.door[num] = spawn( "script_model", pos );
            level.door[num] setModel( "mp_supplydrop_boobytrapped" );
    	level.door[num].angles = angle;
    }
    
    ballH( pos )
    {
            rcC = spawn( "script_model", pos );
            rcC setModel( "t5_veh_rcbomb_allies" );
    }
    
    wepH( pos )
    {
            balls = spawn( "script_model", pos );
            balls setModel( "t5_weapon_ballistic_knife_blade_retrieve" );
    }
    
    locationP( num, pos )
    {
            level.loc[num] = spawn( "script_model", pos );
    }
    
    crateBox( pos, angle )
    {
    	boxes = spawn( "script_model", pos );
    	boxes setModel( "mp_supplydrop_boobytrapped" );
    	boxes.angles = angle;
    	boxes hide();
    }
    
    doBoxes()
    {
    	level.boxes[1] = crateBox( ( 451.894, 466.84, 37.6928), ( 0, 1.98303, 90 ) );
    	level.boxes[2] = crateBox( ( -21.3157, 562.878, 132.3), ( 0, 89.8552, 90 ) );
    	level.boxes[3] = crateBox( ( 14.3157, 562.878, 132.3), ( 0, 89.8552, 90 ) );
    	level.boxes[4] = crateBox( ( 47.3157, 562.878, 132.3), ( 0, 89.8552, 90 ) );
    	level.boxes[5] = crateBox( ( 98.7247, 556.044, 94.8548), ( 0, 89.8552, 752 ) );
    	level.boxes[6] = crateBox( ( 168.7247, 556.044, 44.8548), ( 0, 89.8552, 752 ) );
    	level.boxes[7] = crateBox( ( -767.874, -1833.311, 64.5577), ( 0, -80.2772, 90 ) );
    	level.boxes[8] = crateBox( ( -1777.16, -2689.58, 118.687), ( 0, 9.42966, 3 ) );
    	level.boxes[9] = crateBox( ( -1325.33, -2705.58, 162.359), ( 0, -124.486, 90 ) );
    	level.boxes[10] = crateBox( ( 170.112, -417.087, 131.285), ( 0, 86.6262, 90 ) );
    	level.boxes[11] = crateBox( ( 170.112, -470.087, 131.285), ( 0, 86.6262, 90 ) );
    	level.boxes[12] = crateBox( ( -214.46, -311.823, 132.451), ( 0, 269.009, 90 ) );
    	level.boxes[13] = crateBox( ( 98.7247, 556.044, 124.8548), ( 0, 89.8552, 752 ) );
    	level.boxes[14] = crateBox( ( 168.7247, 556.044, 74.8548), ( 0, 89.8552, 752 ) );
    
    	level.locations[1] = locationP( 1, ( -360.065, -921.511, 64.125) );
    	level.locations[2] = locationP( 2, ( 0.96961, 491.754, 64.125) );
    	level.locations[3] = locationP( 3, ( -345.043, -741.82, 64.125) );
    	level.locations[4] = locationP( 4, ( -10.0913, 335.889, 64.125) );
    	level.locations[5] = locationP( 5, ( 34.1149, -116.466, 64.125) );
    	level.locations[6] = locationP( 6, ( 34.1149, -215.889, 64.125) );
    
    	level.helpers[1] = ballH( ( -7.96764, -105.846, 95.625) );
    	level.locations[2] = wepH( ( -7.96764, -255.846, 95.625) );
    
    	level.doorC[1] = doorCrate( 1, ( -354.224, -855.19, 79.8372), ( 0, -88.2281, 0 ) );
    	level.doorC[2] = doorCrate( 2, ( -354.224, -855.19, 109.8372), ( 0, -88.2281, 0 ) );
    	level.doorC[3] = doorCrate( 3, ( -354.224, -855.19, 139.8372), ( 0, -88.2281, 0 ) );
    	level.doorC[4] = doorCrate( 4, ( 5.35175, 423.268, 80.0111), ( 0, -88.2281, 0 ) );
    	level.doorC[5] = doorCrate( 5, ( 5.35175, 423.268, 110.0111), ( 0, -88.2281, 0 ) );
    	level.doorC[6] = doorCrate( 6, ( 5.35175, 423.268, 140.0111), ( 0, -88.2281, 0 ) );
    }
    I keep getting the bots on my team and such so here, maybe you can fix it up. I will be working on a new one I wanted to do.

    0 Not allowed! Not allowed!


    PS4 Profile:

  2. #2
    Formally known as Tlpwnzer KazzababeGamer's Avatar
    Join Date
    Jun 2011
    Posts
    2,947
    Points
    5,427
         User Info     Contact     Gamer ID
    Join Date
    Jun 2011
    Posts
    2,947
    Points
    5,427

    Default

    To insure that you have no duplicate special characters, you should have a while loop with a condition that will not allow the loop to end until Rick, Daryl, and Glenn are all assigned to different people.
    As for the bots, I'm fairly certain you can do:
    Code:
    walker [[level.axis]](); or walker [[level.allies]]();

    1 Not allowed! Not allowed!

  3. #3
    Nintendo Section Moderator PvtRyan's Avatar

    Badge

    Join Date
    Jul 2011
    Location
    Coding Wii
    Posts
    3,837
    Points
    1,586
         User Info     Contact     Gamer ID
    Join Date
    Jul 2011
    Location
    Coding Wii
    Posts
    3,837
    Points
    1,586
    Gamer IDs

    PSN ID: gamer_pvtryan Steam ID: pvtryan_cl Wii Code: PvtRyan

    Contact info:

    Youtube Channel: http://www.youtube.com/xPvtRyanx

    Default

    Quote Originally Posted by Kazzababe View Post
    To insure that you have no duplicate special characters, you should have a while loop with a condition that will not allow the loop to end until Rick, Daryl, and Glenn are all assigned to different people.
    As for the bots, I'm fairly certain you can do:
    Code:
    walker [[level.axis]](); or walker [[level.allies]]();
    I am trying that right now honestly, one sec.

    0 Not allowed! Not allowed!


    PS4 Profile:

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 05:49 PM.
Powered by vBulletin®
Copyright © 2016 vBulletin Solutions, Inc. All rights reserved.