naval_capital_battleship = {
	category = naval
	
	blocked_for = {
		JAP
	}
	
	available_for = {
	}
	
	roles = {
		naval_capital_bb
		naval_capital_shbb
	}
	
	priority = {
		factor = 500
		modifier = {
			factor = 0
			num_of_naval_factories < 12
		}
		modifier = {
			factor = 0.2
			has_navy_size = {
			    size < 35
			}
		}
	}
	
	capital_battleship_1 = {
		
		priority = {
			factor = 400
		}

		role_icon_index = 1
		
		enable = { 
			has_tech = early_engine
			not = { 
				has_tech = basic_ship_hull_heavy
				has_tech = improved_ship_hull_heavy
				has_tech = advanced_ship_hull_heavy
			}
		}
		
		target_variant = {
			match_value = 1000.0
			
			type = nrm_ship_hull_capital_1
			modules = {
				fixed_ship_hullform_slot = nrm_ship_hullform_capital_1
				fixed_ship_engine_slot = nrm_capital_engine_075
				fixed_ship_armor_layout_slot = nrm_armour_layout_BB
				fixed_ship_armor_slot < nrm_capital_armour_12_3
				fixed_ship_damagecontrol_slot = nrm_damagecontrol
				fixed_ship_range_slot = nrm_range_capital_2
				fixed_ship_radar_slot = nrm_radar_fc
				fixed_ship_fire_control_system_slot = nrm_fire_control
				fixed_ship_fire_control_system_aa_slot = nrm_fire_control_aa
				fixed_ship_battery_slot = nrm_capital_battery_12_2x4
				fixed_ship_secondary_slot = nrm_capital_secondary_SB_6_x12
				fixed_ship_tertiary_slot = nrm_capital_tertiary_HA_5_x08
				custom_slot_1 = nrm_support_capital_AA
				custom_slot_2 = {
					any_of = { nrm_support_capital_FP nrm_support_capital_HAA nrm_support_capital_AA }
				}
				custom_slot_3 = {
					any_of = { nrm_support_capital_HAA nrm_support_capital_AA }
				}
				custom_slot_4 = {
					any_of = { nrm_support_capital_HAA nrm_support_capital_AA }
				}
				custom_slot_5 = {
					any_of = { nrm_support_capital_HAA nrm_support_capital_AA }
				}
				custom_slot_6 = nrm_support_capital_AA
			}
		}
		
		allowed_modules = {
		}
	}
	
	capital_battleship_1_upgrade = {
		
		priority = {
			factor = 20
			modifier = {
				factor = 20
				has_war = yes
			}
		}

		role_icon_index = 1
		
		enable = { 
			has_tech = early_engine
			not = { 
				has_tech = basic_ship_hull_heavy
				has_tech = improved_ship_hull_heavy
				has_tech = advanced_ship_hull_heavy
			}
		}
		
		target_variant = {
			match_value = 1100.0
			
			type = nrm_ship_hull_capital_1
			modules = {
				fixed_ship_hullform_slot = { module = nrm_ship_hullform_capital_1 upgrade = current }
				fixed_ship_engine_slot = { module = nrm_capital_engine_070 upgrade = current }
				fixed_ship_armor_layout_slot = { module = nrm_armour_layout_BB upgrade = current }
				fixed_ship_armor_slot = { module < nrm_capital_armour_12_3 upgrade = current }
				fixed_ship_damagecontrol_slot = { module = nrm_damagecontrol upgrade = current }
				fixed_ship_range_slot = {
					any_of = { nrm_range_capital_2 }
					upgrade = current
				}
				fixed_ship_radar_slot = nrm_radar_fc
				fixed_ship_fire_control_system_slot = nrm_fire_control
				fixed_ship_fire_control_system_aa_slot = nrm_fire_control_aa
				fixed_ship_battery_slot = { module = nrm_capital_battery_12_2x4 upgrade = current }
				fixed_ship_secondary_slot = { module = nrm_capital_secondary_SB_6_x12 upgrade = current }
				fixed_ship_tertiary_slot = { module = nrm_capital_tertiary_HA_5_x08 upgrade = current }
				custom_slot_1 = nrm_support_capital_AA
				custom_slot_2 = {
					any_of = { nrm_support_capital_FP nrm_support_capital_HAA nrm_support_capital_AA }
				}
				custom_slot_3 = {
					any_of = { nrm_support_capital_HAA nrm_support_capital_AA }
				}
				custom_slot_4 = {
					any_of = { nrm_support_capital_HAA nrm_support_capital_AA }
				}
				custom_slot_5 = {
					any_of = { nrm_support_capital_HAA nrm_support_capital_AA }
				}
				custom_slot_6 = nrm_support_capital_AA
			}
		}
		
		allowed_modules = {
		}
	}
	
	capital_battleship_2 = {
		
		priority = {
			factor = 400
		}

		role_icon_index = 1
		
		enable = { 
			has_tech = early_engine
			has_tech = basic_ship_hull_heavy
			has_tech = basic_heavy_battery_2
			not = { 
				has_tech = improved_ship_hull_heavy
				has_tech = advanced_ship_hull_heavy
			}
		}
		
		target_variant = {
			match_value = 2000.0
			
			type = nrm_ship_hull_capital_2
			modules = {
				fixed_ship_hullform_slot = nrm_ship_hullform_capital_2
				fixed_ship_engine_slot = nrm_capital_engine_080
				fixed_ship_armor_layout_slot = nrm_armour_layout_BB
				fixed_ship_armor_slot < nrm_capital_armour_12_3
				fixed_ship_damagecontrol_slot = nrm_damagecontrol
				fixed_ship_range_slot = nrm_range_capital_2
				fixed_ship_radar_slot = nrm_radar_fc
				fixed_ship_fire_control_system_slot = nrm_fire_control
				fixed_ship_fire_control_system_aa_slot = nrm_fire_control_aa
				fixed_ship_battery_slot = nrm_capital_battery_14_2x4
				fixed_ship_secondary_slot = {
					any_of = { nrm_capital_tertiary_DP_5_x08 nrm_capital_secondary_SB_6_x12 }
				} 
				fixed_ship_tertiary_slot = {
					any_of = { nrm_capital_tertiary_DP_5_x08 nrm_capital_tertiary_HA_5_x12 }
				}
				custom_slot_1 = nrm_support_capital_AA
				custom_slot_2 = {
					any_of = { nrm_support_capital_FP nrm_support_capital_HAA nrm_support_capital_AA }
				}
				custom_slot_3 = {
					any_of = { nrm_support_capital_HAA nrm_support_capital_AA }
				}
				custom_slot_4 = {
					any_of = { nrm_support_capital_HAA nrm_support_capital_AA }
				}
				custom_slot_5 = {
					any_of = { nrm_support_capital_HAA nrm_support_capital_AA }
				}
				custom_slot_6 = nrm_support_capital_AA
			}
		}
		
		allowed_modules = {
		}
	}
	
	capital_battleship_2_upgrade = {
		
		priority = {
			factor = 20
			modifier = {
				factor = 20
				has_war = yes
			}
		}

		role_icon_index = 1
		
		enable = { 
			has_tech = early_engine
			has_tech = basic_ship_hull_heavy
			has_tech = basic_heavy_battery_2
			not = { 
				has_tech = improved_ship_hull_heavy
				has_tech = advanced_ship_hull_heavy
			}
		}
		
		target_variant = {
			match_value = 2100.0
			
			type = nrm_ship_hull_capital_2
			modules = {
				fixed_ship_hullform_slot = { module = nrm_ship_hullform_capital_2 upgrade = current }
				fixed_ship_engine_slot = { module = nrm_capital_engine_080 upgrade = current }
				fixed_ship_armor_layout_slot = { module = nrm_armour_layout_BB upgrade = current }
				fixed_ship_armor_slot = { module < nrm_capital_armour_12_3 upgrade = current }
				fixed_ship_damagecontrol_slot = { module = nrm_damagecontrol upgrade = current }
				fixed_ship_range_slot = {
					any_of = { nrm_range_capital_2 }
					upgrade = current
				}
				fixed_ship_radar_slot = nrm_radar_fc
				fixed_ship_fire_control_system_slot = nrm_fire_control
				fixed_ship_fire_control_system_aa_slot = nrm_fire_control_aa
				fixed_ship_battery_slot = { module = nrm_capital_battery_14_2x4 upgrade = current }
				fixed_ship_secondary_slot = {
					any_of = { nrm_capital_tertiary_DP_5_x08 nrm_capital_secondary_SB_6_x12 }
					upgrade = current
				} 
				fixed_ship_tertiary_slot = {
					any_of = { nrm_capital_tertiary_DP_5_x08 nrm_capital_tertiary_HA_5_x12 }
					upgrade = current
				}
				custom_slot_1 = nrm_support_capital_AA
				custom_slot_2 = {
					any_of = { nrm_support_capital_FP nrm_support_capital_HAA nrm_support_capital_AA }
				}
				custom_slot_3 = {
					any_of = { nrm_support_capital_HAA nrm_support_capital_AA }
				}
				custom_slot_4 = {
					any_of = { nrm_support_capital_HAA nrm_support_capital_AA }
				}
				custom_slot_5 = {
					any_of = { nrm_support_capital_HAA nrm_support_capital_AA }
				}
				custom_slot_6 = nrm_support_capital_AA
			}
		}
		
		allowed_modules = {
		}
	}
	
	capital_battleship_3 = {
		
		priority = {
			factor = 400
		}

		role_icon_index = 1
		
		enable = { 
			has_tech = early_engine
			has_tech = basic_heavy_battery_2
			not = { 
				has_tech = advanced_ship_hull_heavy
			}
		}
		
		target_variant = {
			match_value = 3000.0
			
			type = nrm_ship_hull_capital_3
			modules = {
				fixed_ship_hullform_slot = nrm_ship_hullform_capital_3
				fixed_ship_engine_slot = nrm_capital_engine_100
				fixed_ship_armor_layout_slot = nrm_armour_layout_BB
				fixed_ship_armor_slot = nrm_capital_armour_12
				fixed_ship_damagecontrol_slot = nrm_damagecontrol
				fixed_ship_range_slot = nrm_range_capital_2
				fixed_ship_radar_slot = nrm_radar_fc
				fixed_ship_fire_control_system_slot = nrm_fire_control
				fixed_ship_fire_control_system_aa_slot = nrm_fire_control_aa
				fixed_ship_battery_slot = nrm_capital_battery_14_3x3
				fixed_ship_secondary_slot = {
					any_of = { nrm_capital_tertiary_DP_5_x12 nrm_capital_secondary_SB_6_x12 }
				} 
				fixed_ship_tertiary_slot = {
					any_of = { nrm_capital_tertiary_DP_5_x08 nrm_capital_tertiary_HA_5_x12 }
				}
				custom_slot_1 = nrm_support_capital_AA
				custom_slot_2 = {
					any_of = { nrm_support_capital_FP nrm_support_capital_HAA nrm_support_capital_AA }
				}
				custom_slot_3 = {
					any_of = { nrm_support_capital_HAA nrm_support_capital_AA }
				}
				custom_slot_4 = {
					any_of = { nrm_support_capital_HAA nrm_support_capital_AA }
				}
				custom_slot_5 = {
					any_of = { nrm_support_capital_HAA nrm_support_capital_AA }
				}
				custom_slot_6 = nrm_support_capital_AA
			}
		}
		
		allowed_modules = {
		}
	}
	
	capital_battleship_3_upgrade = {
		
		priority = {
			factor = 20
			modifier = {
				factor = 20
				has_war = yes
			}
		}

		role_icon_index = 1
		
		enable = { 
			has_tech = early_engine
			has_tech = basic_heavy_battery_2
			not = { 
				has_tech = advanced_ship_hull_heavy
			}
		}
		
		target_variant = {
			match_value = 3100.0
			
			type = nrm_ship_hull_capital_3
			modules = {
				fixed_ship_hullform_slot = { module = nrm_ship_hullform_capital_3 upgrade = current }
				fixed_ship_engine_slot = { module = nrm_capital_engine_100 upgrade = current }
				fixed_ship_armor_layout_slot = { module = nrm_armour_layout_BB upgrade = current }
				fixed_ship_armor_slot = { module = nrm_capital_armour_12 upgrade = current }
				fixed_ship_damagecontrol_slot = { module = nrm_damagecontrol upgrade = current }
				fixed_ship_range_slot = {
					any_of = { nrm_range_capital_2 }
					upgrade = current
				}
				fixed_ship_radar_slot = nrm_radar_fc
				fixed_ship_fire_control_system_slot = nrm_fire_control
				fixed_ship_fire_control_system_aa_slot = nrm_fire_control_aa
				fixed_ship_battery_slot = { module = nrm_capital_battery_14_3x3 upgrade = current }
				fixed_ship_secondary_slot = {
					any_of = { nrm_capital_tertiary_DP_5_x12 nrm_capital_secondary_SB_6_x12 }
					upgrade = current
				} 
				fixed_ship_tertiary_slot = {
					any_of = { nrm_capital_tertiary_DP_5_x08 nrm_capital_tertiary_HA_5_x12 }
					upgrade = current
				}
				custom_slot_1 = nrm_support_capital_AA
				custom_slot_2 = {
					any_of = { nrm_support_capital_FP nrm_support_capital_HAA nrm_support_capital_AA }
				}
				custom_slot_3 = {
					any_of = { nrm_support_capital_HAA nrm_support_capital_AA }
				}
				custom_slot_4 = {
					any_of = { nrm_support_capital_HAA nrm_support_capital_AA }
				}
				custom_slot_5 = {
					any_of = { nrm_support_capital_HAA nrm_support_capital_AA }
				}
				custom_slot_6 = nrm_support_capital_AA
			}
		}
		
		allowed_modules = {
		}
	}
	
	capital_battleship_4 = {
		
		priority = {
			factor = 100
		}

		role_icon_index = 1
		
		enable = { 
			has_tech = early_engine
			has_tech = basic_heavy_battery_2
			not = { 
				has_tech = advanced_ship_hull_heavy
				has_tech = basic_heavy_battery_3
			}
		}
		
		target_variant = {
			match_value = 4000.0
			
			type = nrm_ship_hull_capital_4
			modules = {
				fixed_ship_hullform_slot = nrm_ship_hullform_capital_4
				fixed_ship_engine_slot = nrm_capital_engine_120
				fixed_ship_armor_layout_slot = nrm_armour_layout_BB
				fixed_ship_armor_slot = nrm_capital_armour_13
				fixed_ship_damagecontrol_slot = nrm_damagecontrol
				fixed_ship_range_slot = nrm_range_capital_3
				fixed_ship_radar_slot = nrm_radar_fc
				fixed_ship_fire_control_system_slot = nrm_fire_control
				fixed_ship_fire_control_system_aa_slot = nrm_fire_control_aa
				fixed_ship_battery_slot = nrm_capital_battery_14_3x3
				fixed_ship_secondary_slot = {
					any_of = { nrm_capital_tertiary_DP_5_x12 nrm_capital_secondary_SB_6_x12 }
				} 
				fixed_ship_tertiary_slot = {
					any_of = { nrm_capital_tertiary_DP_5_x12 nrm_capital_tertiary_HA_5_x16 }
				}
				custom_slot_1 = nrm_support_capital_AA
				custom_slot_2 = {
					any_of = { nrm_support_capital_FP nrm_support_capital_HAA nrm_support_capital_AA }
				}
				custom_slot_3 = {
					any_of = { nrm_support_capital_HAA nrm_support_capital_AA }
				}
				custom_slot_4 = {
					any_of = { nrm_support_capital_HAA nrm_support_capital_AA }
				}
				custom_slot_5 = {
					any_of = { nrm_support_capital_HAA nrm_support_capital_AA }
				}
				custom_slot_6 = nrm_support_capital_AA
			}
		}
		
		allowed_modules = {
		}
	}
	
	capital_battleship_4_upgrade = {
		
		priority = {
			factor = 20
			modifier = {
				factor = 20
				has_war = yes
			}
		}

		role_icon_index = 1
		
		enable = { 
			has_tech = early_engine
			has_tech = basic_heavy_battery_2
			not = { 
				has_tech = advanced_ship_hull_heavy
				has_tech = basic_heavy_battery_3
			}
		}
		
		target_variant = {
			match_value = 4100.0
			
			type = nrm_ship_hull_capital_4
			modules = {
				fixed_ship_hullform_slot = { module = nrm_ship_hullform_capital_4 upgrade = current }
				fixed_ship_engine_slot = { module = nrm_capital_engine_120 upgrade = current }
				fixed_ship_armor_layout_slot = { module = nrm_armour_layout_BB upgrade = current }
				fixed_ship_armor_slot = { module = nrm_capital_armour_13 upgrade = current }
				fixed_ship_damagecontrol_slot = { module = nrm_damagecontrol upgrade = current }
				fixed_ship_range_slot = {
					any_of = { nrm_range_capital_3 }
					upgrade = current
				}
				fixed_ship_radar_slot = nrm_radar_fc
				fixed_ship_fire_control_system_slot = nrm_fire_control
				fixed_ship_fire_control_system_aa_slot = nrm_fire_control_aa
				fixed_ship_battery_slot = { module = nrm_capital_battery_14_3x3 upgrade = current }
				fixed_ship_secondary_slot = {
					any_of = { nrm_capital_tertiary_DP_5_x12 nrm_capital_secondary_SB_6_x12 }
					upgrade = current
				} 
				fixed_ship_tertiary_slot = {
					any_of = { nrm_capital_tertiary_DP_5_x12 nrm_capital_tertiary_HA_5_x16 }
					upgrade = current
				}
				custom_slot_1 = nrm_support_capital_AA
				custom_slot_2 = {
					any_of = { nrm_support_capital_FP nrm_support_capital_HAA nrm_support_capital_AA }
				}
				custom_slot_3 = {
					any_of = { nrm_support_capital_HAA nrm_support_capital_AA }
				}
				custom_slot_4 = {
					any_of = { nrm_support_capital_HAA nrm_support_capital_AA }
				}
				custom_slot_5 = {
					any_of = { nrm_support_capital_HAA nrm_support_capital_AA }
				}
				custom_slot_6 = nrm_support_capital_AA
			}
		}
		
		allowed_modules = {
		}
	}
	
	capital_battleship_4h = {
		
		priority = {
			factor = 100
		}

		role_icon_index = 1
		
		enable = { 
			has_tech = early_engine
			has_tech = basic_heavy_battery_3
		}
		
		target_variant = {
			match_value = 4500.0
			
			type = nrm_ship_hull_capital_4
			modules = {
				fixed_ship_hullform_slot = nrm_ship_hullform_capital_4
				fixed_ship_engine_slot = nrm_capital_engine_130
				fixed_ship_armor_layout_slot = nrm_armour_layout_BB
				fixed_ship_armor_slot = nrm_capital_armour_12
				fixed_ship_damagecontrol_slot = nrm_damagecontrol
				fixed_ship_range_slot = nrm_range_capital_3
				fixed_ship_radar_slot = nrm_radar_fc
				fixed_ship_fire_control_system_slot = nrm_fire_control
				fixed_ship_fire_control_system_aa_slot = nrm_fire_control_aa
				fixed_ship_battery_slot = nrm_capital_battery_16_3x3
				fixed_ship_secondary_slot = {
					any_of = { nrm_capital_tertiary_DP_5_x12 nrm_capital_secondary_SB_6_x12 }
				} 
				fixed_ship_tertiary_slot = {
					any_of = { nrm_capital_tertiary_DP_5_x12 nrm_capital_tertiary_HA_5_x16 }
				}
				custom_slot_1 = nrm_support_capital_AA
				custom_slot_2 = {
					any_of = { nrm_support_capital_FP nrm_support_capital_HAA nrm_support_capital_AA }
				}
				custom_slot_3 = {
					any_of = { nrm_support_capital_HAA nrm_support_capital_AA }
				}
				custom_slot_4 = {
					any_of = { nrm_support_capital_HAA nrm_support_capital_AA }
				}
				custom_slot_5 = {
					any_of = { nrm_support_capital_HAA nrm_support_capital_AA }
				}
				custom_slot_6 = nrm_support_capital_AA
			}
		}
		
		allowed_modules = {
		}
	}
	
	capital_battleship_4h_upgrade = {
		
		priority = {
			factor = 20
			modifier = {
				factor = 20
				has_war = yes
			}
		}

		role_icon_index = 1
		
		enable = { 
			has_tech = early_engine
			has_tech = basic_heavy_battery_3
		}
		
		target_variant = {
			match_value = 4600.0
			
			type = nrm_ship_hull_capital_4
			modules = {
				fixed_ship_hullform_slot = { module = nrm_ship_hullform_capital_4 upgrade = current }
				fixed_ship_engine_slot = { module = nrm_capital_engine_130 upgrade = current }
				fixed_ship_armor_layout_slot = { module = nrm_armour_layout_BB upgrade = current }
				fixed_ship_armor_slot = { module = nrm_capital_armour_12 upgrade = current }
				fixed_ship_damagecontrol_slot = { module = nrm_damagecontrol upgrade = current }
				fixed_ship_range_slot = {
					any_of = { nrm_range_capital_3 }
					upgrade = current
				}
				fixed_ship_radar_slot = nrm_radar_fc
				fixed_ship_fire_control_system_slot = nrm_fire_control
				fixed_ship_fire_control_system_aa_slot = nrm_fire_control_aa
				fixed_ship_battery_slot = { module = nrm_capital_battery_16_3x3 upgrade = current }
				fixed_ship_secondary_slot = {
					any_of = { nrm_capital_tertiary_DP_5_x12 nrm_capital_secondary_SB_6_x12 }
					upgrade = current
				} 
				fixed_ship_tertiary_slot = {
					any_of = { nrm_capital_tertiary_DP_5_x12 nrm_capital_tertiary_HA_5_x16 }
					upgrade = current
				}
				custom_slot_1 = nrm_support_capital_AA
				custom_slot_2 = {
					any_of = { nrm_support_capital_FP nrm_support_capital_HAA nrm_support_capital_AA }
				}
				custom_slot_3 = {
					any_of = { nrm_support_capital_HAA nrm_support_capital_AA }
				}
				custom_slot_4 = {
					any_of = { nrm_support_capital_HAA nrm_support_capital_AA }
				}
				custom_slot_5 = {
					any_of = { nrm_support_capital_HAA nrm_support_capital_AA }
				}
				custom_slot_6 = nrm_support_capital_AA
			}
		}
		
		allowed_modules = {
		}
	}
}