bm_anti_ship_missile_project = {
	specialization = specialization_naval
	icon = GFX_sp_anti_ship_missile
	project_tags = {
		sp_tag_rocket
		sp_tag_guided_bomb
	}

	resource_cost = {
		resources = {
			steel = 3
			chromium = 2
		}
	}

	breakthrough_cost = {
		specialization_naval = {
			base = 3
			modifier = {
				add = -2
				has_tech = modern_ship_torpedo_launcher
			}
		}
	}

	prototype_time = sp_time.prototype.long
	complexity = sp_complexity.small

	allowed = {
		has_dlc = "Man the Guns"
	}

	visible = {
		NOT = {
			has_global_flag = wia_baby_mode
		}
	}
	
	available = {
		if = {
			limit = {
				FROM = {
					is_ai = yes
				}
			}
			FROM = {
				always = no
			}
		}
		else = {
			FROM = {
				has_tech = sp_rockets_improved_guidance
				has_tech = advanced_ship_torpedo_launcher
			}
		}
	}

	generic_prototype_rewards = {
		bm_progress_reward_low
		bm_progress_reward_medium
		bm_progress_reward_high
		bm_progress_loss_low
		bm_progress_loss_medium
		bm_progress_loss_high
		bm_naval_breakthrough_reward_low
		bm_naval_breakthrough_reward_medium
		bm_naval_breakthrough_reward_high
		bm_naval_scientist_xp_reward_low
		bm_naval_scientist_xp_reward_medium
		bm_naval_scientist_xp_reward_high
		bm_naval_scientist_xp_reward_very_high
	}

	project_output = {
		country_effects = {
			hidden_effect = {
				custom_effect_tooltip = bm_anti_ship_missile_desc_tt
			}
			custom_effect_tooltip = {
				localization_key = bm_anti_ship_missile_project_missile_tt
				ICON = GFX_bm_anti_ship_missile_icon
				NAME = bm_anti_ship_missile_project
				DESC = bm_anti_ship_missile_desc_tt
			}
			custom_effect_tooltip = bm_divider
			custom_effect_tooltip = {
				localization_key = bm_anti_ship_missile_project_module_tt
				ICON = GFX_bm_anti_ship_launcher_module_icon
				NAME = bm_anti_ship_launcher_1
				DESC = bm_anti_ship_launcher_1_desc
			}
			custom_effect_tooltip = bm_divider_2
			custom_effect_tooltip = {
				localization_key = bm_anti_ship_missile_project_tip_tt
				TECH_1 = modern_ship_torpedo_launcher
			}
		}

		enable_equipment_modules = {
			bm_anti_ship_launcher_1
		}
	}

	unique_prototype_rewards = {
		bm_anti_ship_missile_project_reward = {
			fire_only_once = yes

			threshold = {
				min = 10
				max = 100
			}

			weight = {
				base = 20
			}

			option = {
				token = bm_anti_ship_missile_project_option_1

				iteration_output = {
					country_effects = {
						add_design_template_bonus = {
							name = bm_anti_ship_missile_project_template_bonus_1
							uses = 1
							cost_factor = 1
							equipment = ship_hull_light_3
							equipment = ship_hull_light_4
						}						
					}
				}
			}
			option = {
				token = bm_anti_ship_missile_project_option_2

				iteration_output = {
					country_effects = {
						add_design_template_bonus = {
							name = bm_anti_ship_missile_project_template_bonus_2
							uses = 1
							cost_factor = 1
							equipment = ship_hull_cruiser_3
							equipment = ship_hull_cruiser_4
						}						
					}
				}
			}
		}
	}
}