##################################
### MISSILES WEAPON COMPONENTS ###
##################################

weapon_component_template = {
	key = "TOMAHAWK_CRUISE_MISSILE"
	size = large
	type = missile
	entity = "turret_torpedo_entity"
	
	icon = "GFX_ship_part_cruise_missile_1"
	icon_frame = 1
	
	power = -120
	damage = { min = 125 max = 175}
	hull_damage = 1.0
	shield_damage = 0.75
	shield_penetration = 0.75
	armor_damage = 1.5
	armor_penetration = 0.0
	windup = { min = 10 max = 20 }
	total_fire_time = 70
	range = 175.0
	min_range = 50
	accuracy = 1.0
	tracking = 0.0
	missile_speed = 12.0
	missile_evasion = 0.1
	missile_shield = 0.0
	missile_armor = 0.0
	missile_health = 18.0
	missile_retarget_range = 100.0
	
	prerequisites = { "tech_tomahawk_cruise_missile_1" }
	component_set = "TOMAHAWK_CRUISE_MISSILE"
	projectile_gfx = "large_missile"
	tags = { weapon_type_explosive g_slot }
	ai_tags = { weapon_role_artillery artillery artillery_stealth energy_torpedoes energy_torpedoes_stealth }
	inline_script = "targeting/capital_ships"

	resources = {
		category = ship_components
		cost = {
			alloys = @l_t7_cost
			volatile_motes = @l_t5_rare
		}		
		upkeep = {
			energy = @l_t7_upkeep_energy
			alloys = @l_t7_upkeep_alloys
		}
	}

	target_weights = {
		Flagship = 5
		titan = 4
		Dreadnought = 3
		battleship = 2
		Carrier = 1
	}

	ai_weight = {
		weight = 1
		modifier = {
			factor = 0
			has_monthly_income = { resource = volatile_motes value <= 1 }
		}
	}
}

weapon_component_template = {
	key = "FRIGATE_TORPEDO_1"
	size = torpedo
	type = missile
	
	icon = "GFX_ship_part_frigate_torpedo_1"
	icon_frame = 1
	
	power = -5
	damage = { min = 70 max = 100 }
	hull_damage = 1.5
	shield_damage = 1.0
	shield_penetration = 1.0
	armor_damage = 1.5
	armor_penetration = 0.5
	windup = { min = 20 max = 30 }
	total_fire_time = 300
	range = 200
	min_range = 50
	accuracy = 1.0
	tracking = 0.0
	missile_speed = 24.0
	missile_evasion = 0.15
	missile_shield = 0.0
	missile_armor = 0.0
	missile_health = 15.0
	missile_retarget_range = 150.0
	size_damage_factor = 1
	
	prerequisites = { "tech_missiles_3" }
	component_set = "FRIGATE_TORPEDO_1"
	projectile_gfx = "large_missile"
	tags = { weapon_type_explosive g_slot }
	ai_tags = { weapon_role_artillery artillery artillery_stealth energy_torpedoes energy_torpedoes_stealth }
	potential = {
		is_ship_size = frigate
	}
	inline_script = "targeting/capital_ships"

	resources = {
		category = ship_components
		cost = {
			alloys = @l_t7_cost
		}		
		upkeep = {
			energy = @l_t7_upkeep_energy
			alloys = @l_t7_upkeep_alloys
		}
	}
	
	target_weights = {
		Flagship = 5
		titan = 4
		Dreadnought = 3
		battleship = 2
		Carrier = 1
	}

	ai_weight = {
		weight = 1
	}
}

weapon_component_template = {
	key = "BATTLECRUISER_TORPEDO_1"
	size = torpedo
	type = missile
	
	icon = "GFX_ship_part_battlecruiser_torpedo_1"
	icon_frame = 1
	
	power = -50
	damage = { min = 130 max = 180 }
	hull_damage = 1.75
	shield_damage = 1.0
	shield_penetration = 1.0
	armor_damage = 1.75
	armor_penetration = 0.75
	windup = { min = 20 max = 40 }
	total_fire_time = 150
	range = 140
	min_range = 25
	accuracy = 1.0
	tracking = 0.0
	missile_speed = 16.0
	missile_evasion = 0.15
	missile_shield = 0.0
	missile_armor = 0.0
	missile_health = 35.0
	missile_retarget_range = 75.0
	size_damage_factor = 1.5
	
	prerequisites = { "tech_missiles_5" }
	component_set = "BATTLECRUISER_TORPEDO_1"
	projectile_gfx = "large_missile"
	tags = { weapon_type_explosive g_slot }
	ai_tags = { weapon_role_artillery artillery artillery_stealth energy_torpedoes energy_torpedoes_stealth }
	potential = {
		OR = {
			is_ship_class = shipclass_starbase
			is_ship_class = shipclass_military_station
			is_ship_size = Battlecruiser
		}
	}
	inline_script = "targeting/capital_ships"

	resources = {
		category = ship_components
		cost = {
			alloys = @l_t7_cost
		}		
		upkeep = {
			energy = @l_t7_upkeep_energy
			alloys = @l_t7_upkeep_alloys
		}
	}

	ai_weight = {
		weight = 1
	}
}

weapon_component_template = {
	key = "NSC_PD_MISSILE"
	size = point_defence
	type = point_defence
	
	icon = "GFX_ship_part_nsc_pd_missile"
	icon_frame = 1
	projectile_gfx = "nsc_pd_missile"
	
	power = -20
	damage = { min = 8 max = 12 }
	hull_damage = 1.0
	shield_damage = 0.75
	shield_penetration = 0.50
	armor_damage = 2.0
	armor_penetration = 0.75
	windup = { min = 0 max = 0 }
	total_fire_time = 20
	range = 40.0
	accuracy = 0.80
	tracking = 0.80
	
	point_defence_targets = { "missile" "strike_craft" }
	
	prerequisites = { "tech_pd_tracking_3" }
	
	component_set = "NSC_PD_MISSILE"
	
	tags = { weapon_type_point_defense weapon_type_explosive }
	
	ai_tags = { weapon_role_point_defense screen }

	resources = {
		category = ship_components
		cost = {
			alloys = 15
		}
		upkeep = {
			energy = 0.10
			alloys = 0.010
		}
	}

	ai_weight = {
		weight = 1
	}
}