 # 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
 #}
 
 # Castle
castle = {
	# All cultural buildings follow the same pattern:
	# tech required is 0, 1, 2, 4 for the levels of the buildings
	# cost is 200 + 100 per level
	# 60 maintenance of troops + 20 per level
	# + 0.15 bonus in either offensive, defensive or morale sometimes split over different units or stats same on all levels
	
	# Culture building names MUST start with ca_culture

	#Copchaec Cavaller (Just french for Cavalry :/)
	ca_culture_norman_cuman_1 = {
		desc = ca_culture_norman_cuman_1_desc
		potential = {
			OR = {
				culture = normancuman
				has_building = ca_culture_norman_cuman_1
			}
		}
		is_active_trigger = {
			ROOT = {
				culture = normancuman
			}
		} 
		trigger = { 
			TECH_CASTLE_CONSTRUCTION = 0 
			ROOT = {
				culture = normancuman
			}
		}
		prerequisites = { ca_wall_2 }
		gold_cost = 200
		build_time = 730
		knights = 10
		knights_offensive = 0.05
		light_cavalry = 15
		light_cavalry_offensive = 0.05
		light_cavalry_defensive = 0.05
		light_cavalry_morale = 0.05
		ai_creation_factor = 101
		
		extra_tech_building_start = 0.8
	}
	ca_culture_norman_cuman_2 = {
		desc = ca_culture_norman_cuman_1_desc
		potential = {
			OR = {
				culture = normancuman
				has_building = ca_culture_norman_cuman_1
				has_building = ca_culture_norman_cuman_2
			}
		}
		is_active_trigger = {
			ROOT = {
				culture = normancuman
			}
		} 
		trigger = { 
			TECH_CASTLE_CONSTRUCTION = 1 
			ROOT = {
				culture = normancuman
			}
		}
		upgrades_from = ca_culture_norman_cuman_1
		gold_cost = 300
		build_time = 1095
		knights = 15
		knights_offensive = 0.05
		light_cavalry = 20
		light_cavalry_offensive = 0.05
		light_cavalry_defensive = 0.05
		light_cavalry_morale = 0.05
		ai_creation_factor = 100
		
		extra_tech_building_start = 0.8
	}
	ca_culture_norman_cuman_3 = {
		desc = ca_culture_norman_cuman_1_desc
		potential = {
			OR = {
				culture = normancuman
				has_building = ca_culture_norman_cuman_1
				has_building = ca_culture_norman_cuman_2
				has_building = ca_culture_norman_cuman_3
			}
		}
		is_active_trigger = {
			ROOT = {
				culture = normancuman
			}
		} 
		trigger = { 
			TECH_CASTLE_CONSTRUCTION = 2 
			ROOT = {
				culture = normancuman
			}
		}
		upgrades_from = ca_culture_norman_cuman_2
		gold_cost = 400
		build_time = 2190
		knights = 20
		knights_offensive = 0.05
		light_cavalry = 25
		light_cavalry_offensive = 0.05
		light_cavalry_defensive = 0.05
		light_cavalry_morale = 0.05
		ai_creation_factor = 99
		
		extra_tech_building_start = 0.8
	}
	ca_culture_norman_cuman_4 = {
		desc = ca_culture_norman_cuman_1_desc
		potential = {
			OR = {
				culture = normancuman
				has_building = ca_culture_norman_cuman_1
				has_building = ca_culture_norman_cuman_2
				has_building = ca_culture_norman_cuman_3
				has_building = ca_culture_norman_cuman_4
			}
		}
		is_active_trigger = {
			ROOT = {
				culture = normancuman
			}
		} 
		trigger = { 
			TECH_CASTLE_CONSTRUCTION = 4 
			ROOT = {
				culture = normancuman
			}
		}
		upgrades_from = ca_culture_norman_cuman_3
		gold_cost = 500
		build_time = 2190
		knights = 25
		knights_offensive = 0.05
		light_cavalry = 30
		light_cavalry_offensive = 0.05
		light_cavalry_defensive = 0.05
		light_cavalry_morale = 0.05
		ai_creation_factor = 98
		
		extra_tech_building_start = 0.8
	}
}
