//==========================================================================================
//
//	facility31_b1.gm
//
//	Who     	When		What
//------------------------------------------------------------------------------------------
//	FA Buckwild	01 May 2020	Initial Script
//
//==========================================================================================
//

global Map =
{
	Debug = 0, // please set to zero before distributing your script

	Allied_Command_Post_Built = function( trigger )
	{
		Util.MapDebugPrint( "Allied_Command_Post_Built" );
	},

	Allied_Command_Post_Destroyed = function( trigger )
	{
		Util.MapDebugPrint( "Allied_Command_Post_Destroyed" );
	},

	Warehouse_Wall_Destroyed = function( trigger )
	{
		Util.MapDebugPrint( "Warehouse_Wall_Destroyed" );
	},

	Chemical_Counter_Agent_Taken = function( trigger )
	{
		Util.MapDebugPrint( "Chemical_Counter_Agent_Taken" );
	},

	counteragentb_Taken = function( trigger )
	{
		Util.MapDebugPrint( "counteragentb_Taken" );
	},

	counteragentc_Taken = function( trigger )
	{
		Util.MapDebugPrint( "counteragentc_Taken" );
	},

	Chemical_Counter_Agent_Returned = function( trigger )
	{
		Util.MapDebugPrint( "Chemical_Counter_Agent_Returned" );
	},

	counteragentb_Returned = function( trigger )
	{
		Util.MapDebugPrint( "counteragentb_Returned" );
	},

	counteragentc_Returned = function( trigger )
	{
		Util.MapDebugPrint( "counteragentc_Returned" );
	},

	Chemical_Counter_Agent_Secured = function( trigger )
	{
		Util.MapDebugPrint( "Chemical_Counter_Agent_Secured" );
	},

	counteragentb_Secured = function( trigger )
	{
		Util.MapDebugPrint( "counteragentb_Secured" );
	},

	counteragentc_Secured = function( trigger )
	{
		Util.MapDebugPrint( "counteragentc_Secured" );
	},

	forwardspawn1_flag_Axis_Captured = function( trigger )
	{
		Util.MapDebugPrint( "forwardspawn1_flag_Axis_Captured" );
	},

	forwardspawn1_flag_Allies_Captured = function( trigger )
	{
		Util.MapDebugPrint( "forwardspawn1_flag_Allies_Captured" );
	},

};

global OnMapLoad = function()
{
	// Register callback functions
	OnTrigger( "MISSING_STRING", Map.Allied_Command_Post_Built );
	OnTrigger( "MISSING_STRING", Map.Allied_Command_Post_Destroyed );
	OnTrigger( "MISSING_STRING", Map.Warehouse_Wall_Destroyed );
	OnTrigger( "MISSING_STRING", Map.Chemical_Counter_Agent_Taken );
	OnTrigger( "MISSING_STRING", Map.counteragentb_Taken );
	OnTrigger( "MISSING_STRING", Map.counteragentc_Taken );
	OnTrigger( "MISSING_STRING", Map.Chemical_Counter_Agent_Returned );
	OnTrigger( "MISSING_STRING", Map.counteragentb_Returned );
	OnTrigger( "MISSING_STRING", Map.counteragentc_Returned );
	OnTrigger( "MISSING_STRING", Map.Chemical_Counter_Agent_Secured );
	OnTrigger( "MISSING_STRING", Map.counteragentb_Secured );
	OnTrigger( "MISSING_STRING", Map.counteragentc_Secured );
	OnTrigger( "MISSING_STRING", Map.forwardspawn1_flag_Axis_Captured );
	OnTrigger( "MISSING_STRING", Map.forwardspawn1_flag_Allies_Captured );

	//~Util.DisableGoal( ".*", true ); // all but routes
	//~SetAvailableMapGoals( TEAM.AXIS, true, "ATTACK_.*" );
	//~SetAvailableMapGoals( TEAM.ALLIES, true, "ATTACK_.*" );

	// Max users per goal
	//Util.SetMaxUsers( 1, "MOUNTMG42_.*" );

	// Camp times
	//SetMapGoalProperties( "MOUNTMG42_.*", {MinCampTime=15, MaxCampTime=90} );


	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 =
	{
		PLANT_Warehouse_Wall =
		{
		},
		FLAG_Chemical_Counter_Agent =
		{
		},
		FLAG_counteragentb =
		{
		},
		FLAG_counteragentc =
		{
		},
		CHECKPOINT_forwardspawn1_flag =
		{
		},
		BUILD_Allied_Command_Post =
		{
		},
		PLANT_Allied_Command_Post =
		{
		},
	};
	Util.Routes(MapRoutes);
};
