 # Triggers are in Province scope. The From Scope contains the settlement holder (character)
 # start trigger is in title scope.
 
 #<tag> = {
 #	desc = description used in the tooltip of the building
 #	trigger = used for tech requirement of the building, set to 0 if no requirement so it can be build automatically on new games
 #	gold_cost = cost to build the building
 #	build_time = time to build, in days
 #	
 #	ai_creation_factor = weight that the AI uses to determine what building to build
 #	extra_tech_building_start = when starting a new game this building will be pre-built if the province has higher tech than the requirement + this + random 0-1
 #}
 
 # tribe
tribal = {
	
	tb_qanat_1 = {
		desc = ca_qanat_1_desc
		trigger = { TECH_CASTLE_CONSTRUCTION = 0 }
		prestige_cost = 100
		build_time = 547
		
		potential = {
			OR = {
				terrain = desert
			}
		}
		
		garrison_size = 0.010
		
		ai_creation_factor = 109
		
		extra_tech_building_start = 1
	}
	
	tb_qanat_2 = {
		desc = ca_qanat_1_desc
		trigger = { TECH_CASTLE_CONSTRUCTION = 0 }
		upgrades_from = tb_qanat_1
		prestige_cost = 200
		build_time = 730
		
		potential = {
			OR = {
				terrain = desert
			}
		}
		
		garrison_size = 0.015
		
		ai_creation_factor = 108
		
		convert_to_castle = ca_qanat_1

		extra_tech_building_start = 2
	}
	
	tb_carpenter_1 = { 
		desc = ca_carpenter_1_desc
		trigger = { TECH_CASTLE_CONSTRUCTION = 0 }
		prestige_cost = 100
		build_time = 547
		
		potential = {
			OR = {
				terrain = forest
				terrain = jungle
				terrain = woods
			}
		}
		
		light_infantry_offensive = 0.05
		archers_offensive = 0.05
		
		ai_creation_factor = 99

		extra_tech_building_start = 1
	}
	
	tb_carpenter_2 = { 
		desc = ca_carpenter_1_desc
		trigger = { TECH_CASTLE_CONSTRUCTION = 2 }
		upgrades_from = tb_carpenter_1
		prestige_cost = 200
		build_time = 730
		
		potential = {
			OR = {
				terrain = forest
				terrain = jungle
				terrain = woods
			}
		}
		
		light_infantry_offensive = 0.05
		archers_offensive = 0.05
		horse_archers_offensive = 0.10
		
		ai_creation_factor = 98
		
		convert_to_castle = ca_carpenter_1

		extra_tech_building_start = 2
	}
	
	tb_armourer_1 = { 
		desc = ca_armourer_1_desc
		trigger = { TECH_CASTLE_CONSTRUCTION = 0 }
		prestige_cost = 100
		build_time = 547
		
		potential = {
			OR = {
				terrain = plains
				terrain = farmlands
				terrain = steppe
			}
		}
		
		light_infantry_defensive = 0.05
		archers_defensive = 0.05
		
		ai_creation_factor = 99

		extra_tech_building_start = 1
	}
	
	tb_armourer_2 = { 
		desc = ca_armourer_1_desc
		trigger = { TECH_CASTLE_CONSTRUCTION = 2 }
		upgrades_from = tb_armourer_1
		prestige_cost = 200
		build_time = 730
		
		potential = {
			OR = {
				terrain = plains
				terrain = farmlands
				terrain = steppe
			}
		}
		
		light_infantry_defensive = 0.05
		archers_defensive = 0.05
		horse_archers_defensive = 0.10
		
		ai_creation_factor = 98
		
		convert_to_castle = ca_armourer_1

		extra_tech_building_start = 2
	}
	
	tb_forge_1 = { 
		desc = ca_forge_1_desc
		trigger = { TECH_CASTLE_CONSTRUCTION = 0 }
		prestige_cost = 100
		build_time = 547
		
		potential = {
			OR = {
				terrain = hills
				terrain = mountain
			}
		}
		
		light_infantry_offensive = 0.05
		
		ai_creation_factor = 99

		extra_tech_building_start = 1
	}
	
	tb_forge_2 = { 
		desc = ca_forge_1_desc
		trigger = { TECH_CASTLE_CONSTRUCTION = 2 }
		upgrades_from = tb_forge_1
		prestige_cost = 200
		build_time = 730
		
		potential = {
			OR = {
				terrain = hills
				terrain = mountain
			}
		}
		
		light_infantry_offensive = 0.05
		
		ai_creation_factor = 98
		
		convert_to_castle = ca_forge_1

		extra_tech_building_start = 2
	}
	
	

	
}
