//	map arrange data
//	location: d3_breen_01
//  shithard
"precache" {
	"entity" 	"weapon_custom26"
	"entity" 	"weapon_custom6"	
	"entity" 	"weapon_custom8"
	"entity" 	"weapon_custom15"
	"entity" 	"weapon_custom14"
	"entity" 	"weapon_custom30"
	"entity" 	"weapon_lasergun"	
	"entity" 	"weapon_svd"	
	"entity" 	"npc_combine_e"
	"entity" 	"npc_combine_ace"
	"entity"	"npc_stalker"
	"entity"	"npc_kscanner"	
	"entity"	"npc_manhack"		
	"model" "models/weapons/w_msbomb.mdl"	
}


"entities" {

	"instant_trig" {
		"keyvalues" {
			"timer"	"5"
			"label"	"unlockpod"
		}
	}

	"npc_combine_e" {
		"origin" "-2565.31 588.4 640.3"  "angle" "0 90 0"	
		"keyvalues" {
			"additionalequipment"	"weapon_custom6"		
			"squadname" "lookyme"
		}
	}	
	
	"weapon_custom26"
	{
		"origin" "-1974.0 809.43 650.05"  "angle" "0 0 0"
	}

	"instant_trig" {
		"origin" "-606 -719 -227"
		"keyvalues" {
			"radius"	"64"
			"label"		"finale"
			
		}
	}
	
	"item_item_crate" {
		"origin" "-635 152 -191"
		"keyvalues"
		{
			"itemclass"		"weapon_custom30"
			"itemcount"		"1"
		}
	}

	"item_item_crate" {
		"origin" "-635 152 0"
		"keyvalues"
		{
			"itemclass"		"item_ammo_pistol"
			"itemcount"		"2"
		}
	}	
	
//credits stuff	
	"removeentity" {
		"targetname" "song3"
	}	

	"removeentity" {
		"targetname" "hl1_song25"
	}
	
	"point_servercommand" {
		"origin" "73 675 1024"
		"angle" "0 0 0"
		"keyvalues" {
			"targetname" "game_s_cmd"
		}
	}

	"event" {
			"targetname" "logic_ending_credits"
			"action" "addoutput"	
			"value" "OnTrigger game_s_cmd,command,instant_trig_run newcredits,0.1,1"
		}	

	// OUR FIRST TRAP
	"instant_trig" {
		"origin" "-1059 314 1340"
		"keyvalues" {
			"radius" "125"
			"label" "teleport_lift_trap"
		}
	}
	
	"instant_trig" {
		"origin" "-1076 304 -227"
		"keyvalues" {
			"radius" "125"
			"label" "main_group"
		}
	}

	//	game over if player shoots breen 
	"event" {
			"targetname" "breen"
			"action" "addoutput"	
			"value" "OnDeath game_s_cmd,command,instant_trig_run gameover,0.1,1"
	}
}

"entities:gameover" {

	"player" {
		"kill"
		"fadeout"	"1"		
		"message"	"#HL2_GameOver_KillBreen"
	}
}

"entities:killbreen" {

	"instant_trig" {
		"keyvalues" {
			"group"		"1"
			"islived"	"breen"
			"label"		"null"
		}	
	}	
}

"entities:newcredits" {

    "event" {
        "targetname" "game_s_cmd"
        "action"    "Command"
        "value"        "sv_unlockedchapters 64"
    }

	"player" {
		"music"	"credits"
	}
	
}

"entities:unlockpod" {

	"event" {
		"targetname"	"pod"
		"action"	"unlock"
	}
	

}


"entities:finale" {
	"player" {
		"music"	"song_hl1_15_edit"
	}

	"npc_combine_e" {
		"origin" "824.1 -144.4 64.0"  "angle" "0 -167 0"
		"keyvalues" {
			"additionalequipment"	"weapon_custom14"	
			"targetname" "soldiers_mapadd" //needs soldiers_* to be cleaned by map end trigger			
			"squadname" "rollercoaster"
		}
	}

	"npc_combine_e" {
		"origin" "908.6 270.6 64.0"  "angle" "0 -140 0"
		"keyvalues" {
			"additionalequipment"	"weapon_custom8"	
			"targetname" "soldiers_mapadd" //needs soldiers_* to be cleaned by map end trigger					
			"squadname" "rollercoaster"
		}
	}

	"npc_stalker" {
		"origin" "-279.3 726.7 64.0"  "angle" "0 -90 0"
		"keyvalues" {
			"beampower"	"2"		
			"targetname" "soldiers_mapadd" //needs soldiers_* to be cleaned by map end trigger					
			"squadname" "fu_player"
		}
	}

	"npc_stalker" {
		"origin" "-349.3 -707.8 316.0"  "angle" "0 91 0"
		"keyvalues" {
			"beampower"	"2"		
			"targetname" "soldiers_mapadd" //needs soldiers_* to be cleaned by map end trigger					
			"squadname" "fu_player"
		}
	}

	"npc_combine_ace" {
		"origin" "-696.3 433.6 316.0"  "angle" "0 -140 0"
		"keyvalues" {
			"additionalequipment"	"weapon_custom15"	
			"targetname" "soldiers_mapadd" //needs soldiers_* to be cleaned by map end trigger					
			"squadname" "hahaha"
		}
	}	

	"npc_stalker" {
		"origin" "-228.0 41.8 580.0"  "angle" "0 28 0"
		"keyvalues" {
			"beampower"	"2"	
			"targetname" "soldiers_mapadd" //needs soldiers_* to be cleaned by map end trigger					
			"squadname" "hahaha"
		}
	}	

	"npc_kscanner" {
		"origin" "-566.0 -613.4 728.0"  "angle" "0 45 0"
		"keyvalues" {
			"beampower"	"2"		
			"targetname" "soldiers_mapadd" //needs soldiers_* to be cleaned by map end trigger					
			"squadname" "hahaha"
		}
	}
	
	"npc_combine_e" {
		"origin" "-214.5 395.1 1409.9"  "angle" "0 -30 0"
		"longrange"
		"alwaysthink"		
		"keyvalues" {
			"additionalequipment"	"weapon_svd"		
			"targetname" "soldiers_mapadd" //needs soldiers_* to be cleaned by map end trigger					
			"squadname" "bs"
		}
	}

	"npc_combine_ace" {
		"origin" "-537.5 -348.2 831.0"  "angle" "0 5 0"
		"keyvalues" {
			"additionalequipment"	"weapon_lasergun"	
			"targetname" "soldiers_mapadd" //needs soldiers_* to be cleaned by map end trigger					
			"squadname" "bs"
		}
	}	

	"npc_combine_ace" {
		"origin" "-570.5 354.2 831.0"  "angle" "0 5 0"
		"keyvalues" {
			"additionalequipment"	"weapon_custom8"
			"targetname" "soldiers_mapadd" //needs soldiers_* to be cleaned by map end trigger					
			"squadname" "bs"
		}
	}		
}


"entities:teleport_lift_trap" {

	// #1
	"setmsbomb2" {
		"origin" "-1151.0 512.0 1212.5"  "angle" "0 0 0"
	}

	"setmsbomb2" {
		"origin" "-1151.0 538.0 1212.5"  "angle" "0 0 0"
	}

	"setmsbomb2" {
		"origin" "-1151.0 424.6 1212.5"  "angle" "0 0 0"
	}

	"setmsbomb2" {
		"origin" "-1151.0 397.7 1212.5"  "angle" "0 0 0"
	}
	
	// #2
	"setmsbomb2" {
		"origin" "-1027.0 385.0 912.5"  "angle" "0 90 0"
	}
	
	"setmsbomb2" {
		"origin" "-1047.0 385.0 912.5"  "angle" "0 90 0"
	}
	
	"setmsbomb2" {
		"origin" "-1067.0 385.0 912.5"  "angle" "0 90 0"
	}
	
	//#3
	"setmsbomb2" {
		"origin" "-1153.3 432.3 312.5"  "angle" "0 45 0"
	}
	
	"setmsbomb2" {
		"origin" "-1160.8 439.9 612.5"  "angle" "0 45 0"
	}
	
	"setmsbomb2" {
		"origin" "-1158.0 489.2 612.5"  "angle" "0 329 0"
	}

	"setmsbomb2" {
		"origin" "-1151.9 499.4 612.5"  "angle" "0 329 0"
	}

	"setmsbomb2" {
		"origin" "-953.7 488.8 612.5"  "angle" "0 211 0"
	}

	"setmsbomb2" {
		"origin" "-958.6 496.9 612.5"  "angle" "0 211 0"
	}
	
	"setmsbomb2" {
		"origin" "-950.7 440.4 612.5"  "angle" "0 135 0"
	}
	
	"setmsbomb2" {
		"origin" "-959.1 432.0 612.5"  "angle" "0 135 0"
	}
	
	//#4
	"setmsbomb2" {
		"origin" "-1138.5 545.0 312.5"  "angle" "0 270 0"
	}

	"setmsbomb2" {
		"origin" "-1129.8 545.0 312.5"  "angle" "0 270 0"
	}

	"setmsbomb2" {
		"origin" "-1118.7 545.0 312.5"  "angle" "0 270 0"
	}

	"setmsbomb2" {
		"origin" "-1110.5 545.0 312.5"  "angle" "0 270 0"
	}
	
	"setmsbomb2" {
		"origin" "-997.4 545.0 312.5"  "angle" "0 270 0"
	}
	
	"setmsbomb2" {
		"origin" "-986.3 545.0 312.5"  "angle" "0 270 0"
	}
	
	"setmsbomb2" {
		"origin" "-977.9 545.0 312.5"  "angle" "0 270 0"
	}
	
	"setmsbomb2" {
		"origin" "-968.2 545.0 312.5"  "angle" "0 270 0"
	}
	
	"setmsbomb2" {
		"origin" "-961.0 538.9 312.5"  "angle" "0 180 0"
	}
	
	"setmsbomb2" {
		"origin" "-961.0 526.3 312.5"  "angle" "0 180 0"
	}
	
	"setmsbomb2" {
		"origin" "-961.0 521.3 312.5"  "angle" "0 180 0"
	}
	
	"setmsbomb2" {
		"origin" "-961.0 509.6 312.5"  "angle" "0 180 0"
	}
	
	"setmsbomb2" {
		"origin" "-961.0 424.5 312.5"  "angle" "0 180 0"
	}

	"setmsbomb2" {
		"origin" "-961.0 413.9 312.5"  "angle" "0 180 0"
	}

	"setmsbomb2" {
		"origin" "-961.0 401.7 312.5"  "angle" "0 180 0"
	}
	
	"setmsbomb2" {
		"origin" "-961.0 393.5 312.5"  "angle" "0 180 0"
	}
	
	// LOWER 'Z' ORIGIN (X Y Z) FOR EASIER TRAP. PLAYER HEIGHT IS 40 UNITS...
	"setmsbomb2" {
		"origin" "-961.0 534.4 212.5"  "angle" "0 180 0"
	}
	
	"setmsbomb2" {
		"origin" "-961.0 524.1 212.5"  "angle" "0 180 0"
	}

	"setmsbomb2" {
		"origin" "-961.0 515.8 212.5"  "angle" "0 180 0"
	}

	"setmsbomb2" {
		"origin" "-961.0 507.6 212.5"  "angle" "0 180 0"
	}
	
	"setmsbomb2" {
		"origin" "-949.0 479.3 212.5"  "angle" "0 180 0"
	}
	
	"setmsbomb2" {
		"origin" "-949.0 469.9 212.5"  "angle" "0 180 0"
	}
	
	"setmsbomb2" {
		"origin" "-949.0 457.5 212.5"  "angle" "0 180 0"
	}
	
	"setmsbomb2" {
		"origin" "-949.0 448.3 212.5"  "angle" "0 180 0"
	}
	
	// LOWER 'Z' ORIGIN (X Y Z) FOR EASIER TRAP. PLAYER HEIGHT IS 40 UNITS...
	"setmsbomb2" {
		"origin" "-980.4 385.0 112.5"  "angle" "0 90 0"
	}
	
	"setmsbomb2" {
		"origin" "-989.3 385.0 112.5"  "angle" "0 90 0"
	}
	
	"setmsbomb2" {
		"origin" "-1001.9 385.0 112.5"  "angle" "0 90 0"
	}
	
	"setmsbomb2" {
		"origin" "-1013.2 385.0 112.5"  "angle" "0 90 0"
	}
	
	"setmsbomb2" {
		"origin" "-1027.6 385.0 112.5"  "angle" "0 90 0"
	}

	"setmsbomb2" {
		"origin" "-1039.8 385.0 112.5"  "angle" "0 90 0"
	}
	
	"setmsbomb2" {
		"origin" "-1055.0 385.0 112.5"  "angle" "0 90 0"
	}
	
	"setmsbomb2" {
		"origin" "-1065.3 385.0 112.5"  "angle" "0 90 0"
	}

	"setmsbomb2" {
		"origin" "-1078.7 385.0 112.5"  "angle" "0 90 0"
	}
	
	"setmsbomb2" {
		"origin" "-1092.0 385.0 112.5"  "angle" "0 90 0"
	}
}

"entities:main_group" {
	
	"npc_stalker" {
		"origin" "984.6 213.4 1088.0"  "angle" "0 184 0"
		"keyvalues" {
			"spawnflags" "256"
			"targetname" "soldiers_mapadd" //needs soldiers_* to be cleaned by map end trigger					
		}
	}
	
	"npc_stalker" {
		"origin" "338.2 524.6 768.0"  "angle" "0 252 0"
		"keyvalues" {
			"spawnflags" "256"
			"targetname" "soldiers_mapadd" //needs soldiers_* to be cleaned by map end trigger					
		}
	}
	
	"npc_stalker" {
		"origin" "348.5 -527.1 768.0"  "angle" "0 109 0"
		"keyvalues" {
			"spawnflags" "256"
			"targetname" "soldiers_mapadd" //needs soldiers_* to be cleaned by map end trigger					
		}
	}
	
	"setmsbomb2" {
		"origin" "-577.0 -221.9 -202.9"  "angle" "0 180 0"
	}
	
	"setmsbomb2" {
		"origin" "-577.0 -223.1 -229.1"  "angle" "0 180 0"
	}
	
	"setmsbomb2" {
		"origin" "-577.0 -222.1 -143.3"  "angle" "0 180 0"
	}
	
	"setmsbomb2" {
		"origin" "-577.0 -223.1 -157.5"  "angle" "0 180 0"
	}
	
	"setmsbomb2" {
		"origin" "-577.0 -222.3 -170.3"  "angle" "0 180 0"
	}
	
	"setmsbomb2" {
		"origin" "-577.0 -222.3 -187.9"  "angle" "0 180 0"
	}
	
	"combine_mine" {
		"origin" "-357.6 -724.4 -255.7"  "angle" "-0 64 0"
	}
	
	"combine_mine" {
		"origin" "-334.6 -595.7 -255.6"  "angle" "0 52 360"
	}
	
	"combine_mine" {
		"origin" "-172.8 -542.5 -255.6"  "angle" "-0 -1 360"
	}
	
	"combine_mine" {
		"origin" "-9.7 -633.1 -255.6"  "angle" "0 101 0"
	}
	
	"combine_mine" {
		"origin" "33.2 -577.2 -255.6"  "angle" "-0 113 0"
	}
	
	"combine_mine" {
		"origin" "90.2 -448.6 -255.6"  "angle" "-0 29 360"
	}
	
	"combine_mine" {
		"origin" "195.1 -482.0 -255.6"  "angle" "-0 15 360"
	}
	
	"combine_mine" {
		"origin" "356.0 -475.8 -208.3"  "angle" "19 -115 15"
	}
	
	"combine_mine" {
		"origin" "391.7 -380.6 -175.0"  "angle" "19 167 345"
	}
	
	"combine_mine" {
		"origin" "538.1 -289.3 -98.2"  "angle" "-22 1 10"
	}
	
	"combine_mine" {
		"origin" "608.8 -230.2 -58.1"  "angle" "-10 92 338"
	}

// too many issues with ending scripts right now...	
//	"instant_trig" {
//		"origin" "-498 -766 -227"
//		"keyvalues" {
//			"radius" "125"
//			"label" "release_the_cracken"
//		}
//	}
}

"entities:release_the_cracken" {
	
	"npc_enemyfinder" {
		"origin" "407.3 -7221.4 1088.0"  "angle" "0 145 0"
		"keyvalues" {
			"targetname" "cracken_spotter"
			"squadname" "cracken_squad"
			"FieldOfView" "-1.0"
			"MinSearchDist" "0"
			"MaxSearchDist" "2048"
			"ignoreunseenenemies" "0"
			"StartOn" "1"
		}
	}
	
	"npc_maker" {
		"origin" "-598.6 -245.2 1868.1"
		"keyvalues" {
			"targetname" "cracken1_spawner"
			"startdisabled" "0"
			"SpawnFrequency" "-1"
			"MaxNPCCount" "99"
			"MaxLiveChildren" "2"
			"NPCType" "npc_manhack"
			"NPCTargetname" "cracken1"
			"NPCSquadname" "cracken_squad"
			//"additionalequipment" ""
			"spawnflags" "128"
		}
	}
	
	"npc_maker" {
		"origin" "-508.3 -233.1 1857.1"
		"keyvalues" {
			"targetname" "cracken2_spawner"
			"startdisabled" "0"
			"SpawnFrequency" "-1"
			"MaxNPCCount" "99"
			"MaxLiveChildren" "2"
			"NPCType" "npc_manhack"
			"NPCTargetname" "cracken2"
			"NPCSquadname" "cracken_squad"
			//"additionalequipment" ""
			"spawnflags" "128"
		}
	}
	
	"npc_maker" {
		"origin" "-514.0 158.1 1829.7"
		"keyvalues" {
			"targetname" "cracken3_spawner"
			"startdisabled" "0"
			"SpawnFrequency" "-1"
			"MaxNPCCount" "99"
			"MaxLiveChildren" "2"
			"NPCType" "npc_manhack"
			"NPCTargetname" "cracken3"
			"NPCSquadname" "cracken_squad"
			//"additionalequipment" ""
			"spawnflags" "128"
		}
	}
	
	"npc_maker" {
		"origin" "-669.4 170.9 1918.3"
		"keyvalues" {
			"targetname" "cracken4_spawner"
			"startdisabled" "0"
			"SpawnFrequency" "-1"
			"MaxNPCCount" "99"
			"MaxLiveChildren" "2"
			"NPCType" "npc_manhack"
			"NPCTargetname" "cracken4"
			"NPCSquadname" "cracken_squad"
			//"additionalequipment" ""
			"spawnflags" "128"
		}
	}
}