icon = GFX_district_specialization_foundry
base_buildtime = @zone_buildtime

potential = { # planet scope
	exists = owner
	owner = {
		is_wilderness_empire = no
		has_technology = tech_basic_industry
	}
}

resources = {
	category = planet_zones
	inline_script = {
		script = buildings/nomadic_cost_switcher
		REGULAR_RESOURCE = minerals
		NOMADIC_RESOURCE = alloys
		COST = @zone_cost
		NOMADIC_COST_MULT = 0.5
	}
}

inline_script = {
	script = jobs/zone_foundry_add
	AMOUNT = $AMOUNT$
	AMOUNT2 = $LARGE_AMOUNT$
}

included_building_sets = {
	fortress
	industrial
}

planet_modifier = {
	zone_building_slots_add = 3
	planet_metallurgists_alloys_produces_add = 0.75
	ship_armor_from_metallurgists = @arkship_zone_armor_from_metallurgists
	ship_hardening_from_metallurgists = @arkship_zone_hardening_from_metallurgists
}

# Non-catalytic empires pay the extra foundry upkeep in minerals
triggered_planet_modifier = {
	potential = {
		industrial_jobs_are_catalytic_trigger = no
	}
	modifier = {
		planet_metallurgists_minerals_upkeep_add = 1.5
	}
}

# Catalytic Processing empires pay it in food instead, at the same 1.5x ratio the base job uses when swapping minerals for food
triggered_planet_modifier = {
	potential = {
		industrial_jobs_are_catalytic_trigger = yes
	}
	modifier = {
		planet_metallurgists_food_upkeep_add = 2.25
	}
}

ai_priority = 5
