//========================================================================================== // // norwegian_battery_b6.gm // // Who When What //------------------------------------------------------------------------------------------ // ^1[13th]^4Thunder 04 May 2014 Initial Script // //========================================================================================== // global Map = { Debug = 1, // please set to zero before distributing your script ShowMovers = false, Command_Post_Dyno = 0, door_of_the_commandpost_house_Dyno = 0, gun_controls_Dyno = 0, Command_Post_Built = function( trigger ) { if ( TestMap ) { return; } Util.MapDebugPrint( "Command_Post_Built" ); }, door_of_the_commandpost_house_Built = function( trigger ) { if ( TestMap ) { return; } Util.MapDebugPrint( "door_of_the_commandpost_house_Built" ); }, Command_Post_Planted = function( trigger ) { if ( TestMap ) { return; } Map.Command_Post_Dyno += 1; Util.MapDebugPrint( "Command_Post_Planted" ); }, door_of_the_commandpost_house_Planted = function( trigger ) { if ( TestMap ) { return; } Map.door_of_the_commandpost_house_Dyno += 1; Util.MapDebugPrint( "door_of_the_commandpost_house_Planted" ); }, gun_controls_Planted = function( trigger ) { if ( TestMap ) { return; } Map.gun_controls_Dyno += 1; Util.MapDebugPrint( "gun_controls_Planted" ); }, Command_Post_Defused = function( trigger ) { if ( TestMap ) { return; } Map.Command_Post_Dyno -= 1; Util.MapDebugPrint( "Command_Post_Defused" ); }, door_of_the_commandpost_house_Defused = function( trigger ) { if ( TestMap ) { return; } Map.door_of_the_commandpost_house_Dyno -= 1; Util.MapDebugPrint( "door_of_the_commandpost_house_Defused" ); }, gun_controls_Defused = function( trigger ) { if ( TestMap ) { return; } Map.gun_controls_Dyno -= 1; Util.MapDebugPrint( "gun_controls_Defused" ); }, Command_Post_Destroyed = function( trigger ) { if ( TestMap ) { return; } Map.Command_Post_Dyno = 0; Util.MapDebugPrint( "Command_Post_Destroyed" ); }, door_of_the_commandpost_house_Destroyed = function( trigger ) { if ( TestMap ) { return; } Map.door_of_the_commandpost_house_Dyno = 0; Util.MapDebugPrint( "door_of_the_commandpost_house_Destroyed" ); }, gun_controls_Destroyed = function( trigger ) { if ( TestMap ) { return; } Map.gun_controls_Dyno = 0; Util.MapDebugPrint( "gun_controls_Destroyed" ); }, keycard_Taken = function( trigger ) { if ( TestMap ) { return; } Util.MapDebugPrint( "keycard_Taken" ); }, keycard_Returned = function( trigger ) { if ( TestMap ) { return; } Util.MapDebugPrint( "keycard_Returned" ); }, keycard_Secured = function( trigger ) { if ( TestMap ) { return; } Util.MapDebugPrint( "keycard_Secured" ); }, }; global OnMapLoad = function() { if ( TestMapOn ) { Util.AutoTestMap(); } // Register callback functions OnTrigger( "MISSING_STRING", Map.Command_Post_Built ); OnTrigger( "MISSING_STRING", Map.door_of_the_commandpost_house_Built ); OnTrigger( "Planted at the MISSING_STRING.", Map.Command_Post_Planted ); OnTrigger( "Planted at the MISSING_STRING.", Map.door_of_the_commandpost_house_Planted ); OnTrigger( "Planted at the MISSING_STRING.", Map.gun_controls_Planted ); OnTrigger( "Defused at the MISSING_STRING.", Map.Command_Post_Defused ); OnTrigger( "Defused at the MISSING_STRING.", Map.door_of_the_commandpost_house_Defused ); OnTrigger( "Defused at the MISSING_STRING.", Map.gun_controls_Defused ); OnTrigger( "MISSING_STRING", Map.Command_Post_Destroyed ); OnTrigger( "MISSING_STRING", Map.door_of_the_commandpost_house_Destroyed ); OnTrigger( "MISSING_STRING", Map.gun_controls_Destroyed ); OnTrigger( "MISSING_STRING", Map.keycard_Taken ); OnTrigger( "MISSING_STRING", Map.keycard_Returned ); OnTrigger( "MISSING_STRING", Map.keycard_Secured ); //~Util.DisableGoal( ".*", true ); // all but routes //~SetAvailableMapGoals( TEAM.AXIS, true, "ATTACK_.*" ); //~SetAvailableMapGoals( TEAM.ALLIES, true, "ATTACK_.*" ); // Max users per goal //Util.SetMaxUsers( 1, "DEFEND_.*" ); //Util.SetMaxUsers( 1, "GRENADE_.*" ); //Util.SetMaxUsers( 1, "MOUNTMG42_.*" ); // Camp times SetMapGoalProperties( "MOUNTMG42_.*", {MinCampTime=15, MaxCampTime=90} ); SetMapGoalProperties( "MOBILEMG42_.*", {MinCampTime=10, MaxCampTime=60} ); Util.MapDebugPrint( "Omni-bot map script for " + GetMapName() + " executed." ); }; global OnBotJoin = function( bot ) { // Uncomment for shootable breakables //~bot.TargetBreakableDist = 90.0; // Only set MaxViewDistance on maps with limited sight (e.g. fog) //~bot.MaxViewDistance = 2400; }; global InitializeRoutes = function() { MapRoutes = { BUILD_Command_Post = { }, BUILD_door_of_the_commandpost_house = { }, PLANT_door_of_the_commandpost_house = { }, PLANT_Command_Post = { }, PLANT_gun_controls = { }, FLAG_keycard = { }, }; Util.Routes(MapRoutes); };