[Thing Template=AARUSBuildingPackableHQ]
{
	IDS = rus2_hq_infantry
	name = "#rus2_hq_infantry_Thing_name"
	editor_name = "#rus2_hq_infantry_Thing_editor_name"

	[BodyComponent]
	health = 8000
	defense = 5

	[DefenderComponent]
	{
		control_range = 20
	
		[Ability Template=AATurretAttackLocal]
		{
			turret_ids = Turret
			
			[AbilityDefinition Template=AAInfantryMG]
			{
				name = "#rus2_hq_infantry_DefenderComponent_AbilityDefinition_name"
				area = 2
				attenuation_range_min = 0.5
				attenuation_factor_max = 0.5
				max_targets = 4
				
				recharge_time = 2
				range = 16
				
				[Effect Template=PierceDamageEffect]
				amount = 70
				
				[WhenDo template=FXC_PlaySFX]	
				audio_ids = usa_mg_heavy
				
				[Flags]
				spell = true				
			}
		}
	}
	
	[DenizenComponent]
	{
		[DeploymentInfo]
		{
			creation_offset = 2.0, 1.5
			deployment_offset = 2.0, 6.0
		}
	}
	
	[DetectionComponent Template=HQDetectionComponent]

	[EconomyComponent]
	{		
		[Cost]	
		money = 200

		[Upkeep]
		ammo = 1
		oil = 1
		money = 0

		[Production]

		unit_limit_provided = 10
	}

	[PerformerComponent]
	{
		[Turret]
		{
			turret_ids = Turret
			yaw_rotation_per_sec_degrees = 60
			yaw_rotation_range_degrees = 360
			yaw_start_degrees = 0
			;offset = -3.801, 3.472
		}
	}

	[Placement]
	placement_group_ids = null

	[PropertiesComponent]
	{
		[Property]
		property_ids = captain
		
		[Property]
		property_ids = nation_rus
		
		[Property]
		property_ids = infhq		
		
		[Property]
		property_ids = mg		
	}

	[RecruitComponent]
	{
		[RecruitActor]
		actor_ids = regiment_rus_infantry_recon

		[RecruitActor]
		actor_ids = regiment_rus_engineer

		[RecruitActor]
		actor_ids = regiment_rus_infantry

		[RecruitActor]
		actor_ids = regiment_rus_infantry_sniper

		[RecruitActor]
		actor_ids = regiment_rus_infantry_at

		[RecruitActor]
		actor_ids = regiment_rus_infantry_artillery

		[RecruitActor]
		actor_ids = rus_truck_122mmartillery

		[RecruitActor]
		actor_ids = rus_truck_76mmartillery

		[RecruitActor]
		actor_ids = rus_truck_37mmartillery

		[RecruitActor]
		actor_ids = rus_truck_supply

		[RecruitActor]
		actor_ids = regiment_rus_infantry_amphib
	}
		
	[ResearchComponent]
	
	[Size]
	{
		blocking_shape = SQUARE
		square_size = 10
	}
	
	[SupplyComponent Template=HQSupplyComponent]
	
	[View]
	{
		minimap_icon = /Minimap/Icons/IconDivisionHQ.tga
		resource_prefix = RUSHQInfantry/RUSHQInfantry
		icon = /UI/Game/BuildingButtons/IconHQInfantry.png
	
		[WhenConstructed Template=FXC_CreateVFX]
		{
			vfx_ids = rus_waving_flag_pole
			location = building_flag
		}

		[WhenConstructed Template=FXC_CreateVFX]
		{
			vfx_ids = ground_hq_infantry_dirt
			terrain_group_filter = dirt
		}
		
		[WhenConstructed Template=FXC_CreateVFX]
		{
			vfx_ids = ground_hq_infantry_desert
			terrain_group_filter = desert
		}
		
		[WhenConstructed Template=FXC_CreateVFX]
		{
			vfx_ids = ground_hq_infantry_snow
			terrain_group_filter = snow
		}
		
		;;------ Spot Lights --------------------
		
		[WhenConstructed Template=FXC_CreateVFX]
		{
			vfx_ids = spotlight_03
			location = spotlight_ae_01
			attached = true
		}
		
		[WhenConstructed Template=FXC_CreateVFX]
		{
			vfx_ids = spotlight_02
			location = spotlight_ae_02
			attached = true
		}
		
		[WhenConstructed Template=FXC_CreateVFX]
		{
			vfx_ids = window_tiny
			location = window_01
			attached = true
		}
		
		[WhenConstructed Template=FXC_CreateVFX]
		{
			vfx_ids = window_tiny
			location = window_02
			attached = true
		}
		
		[WhenConstructed Template=FXC_CreateVFX]
		{
			vfx_ids = window_tiny
			location = window_03
			attached = true
		}
		
		[WhenConstructed Template=FXC_CreateVFX]
		{
			vfx_ids = window_tiny
			location = window_04
			attached = true
		}
		
		[WhenConstructed Template=FXC_CreateVFX]
		{
			vfx_ids = window_tiny
			location = window_05
			attached = true
		}
		
		[WhenConstructed Template=FXC_CreateVFX]
		{
			vfx_ids = window_tiny
			location = window_06
			attached = true
		}
		
		[WhenConstructed Template=FXC_CreateVFX]
		{
			vfx_ids = door_large
			location = door_01
			attached = true
		}
		
		[WhenConstructed Template=FXC_CreateVFX]
		{
			vfx_ids = door_narrow
			location = door_02
			attached = true
		}
		;Window07-10 ready for skylights (large)
	}
}
