﻿# standard costs
@maa_buy_cost = 150
@maa_low_maintenance_cost = 1.0
@maa_high_maintenance_cost = 5.0

# Must be synced between files with the values located at "# Provisions Costs #".
@provisions_cost_infantry_cheap = 3
@provisions_cost_infantry_moderate = 7
@provisions_cost_infantry_expensive = 12
@provisions_cost_infantry_bankrupting = 15

@provisions_cost_cavalry_cheap = 7
@provisions_cost_cavalry_moderate = 15
@provisions_cost_cavalry_expensive = 21
@provisions_cost_cavalry_bankrupting = 30

@provisions_cost_special_cheap = 6
@provisions_cost_special_moderate = 12
@provisions_cost_special_expensive = 18
@provisions_cost_special_bankrupting = 24

light_footmen = {
	type = skirmishers
	
	damage = 10
	toughness = 16
	pursuit = 10
	screen = 16
	
	terrain_bonus = {
		forest = { damage = 4 toughness = 6 }
		taiga = { damage = 4 toughness = 6 }
		jungle = { damage = 4 toughness = 6 }
	}

	counters = {
		heavy_infantry = 1
	}

	can_recruit = {
		NOR = {
			government_has_flag = government_is_nomadic
			government_has_flag = government_is_herder
			culture = {
				OR = {
					has_cultural_tradition = tradition_ep3_imperial_tagmata
					has_cultural_tradition = tradition_roman_legacy 
					has_cultural_tradition = tradition_rashidun_army 
					has_cultural_tradition = tradition_sasanian_army
					has_innovation = innovation_bulgarian_army 
				}
			}
		}
	}

	should_show_when_unavailable = {
		government_allows = subject_men_at_arms
	}

	buy_cost = { gold = skirmisher_recruitment_cost }
	low_maintenance_cost = { gold = skirmisher_low_maint_cost }
	high_maintenance_cost = { gold = skirmisher_high_maint_cost }
	provision_cost = @provisions_cost_infantry_cheap

	holy_order_fallback = yes

	stack = 100
	ai_quality = { value = culture_ai_weight_skirmishers }
	illustration = { trigger = { is_japanese_maa = yes }      reference = japanese_skirmishers }
	illustration = { trigger = { is_emishi_maa = yes }        reference = emishi_skirmishers }	
	illustration = { trigger = { is_korean_maa   = yes }      reference = korean_skirmishers }
	illustration = { trigger = { is_tibetan_maa  = yes }      reference = tibetan_skirmishers }
	illustration = { trigger = { is_scottish_maa = yes }      reference = scottish_skirmishers }	
	illustration = { trigger = { is_scottish_late_maa = yes } reference = scottish_late_skirmishers }		
	illustration = { trigger = { is_irish_maa    = yes }      reference = irish_skirmishers }
	illustration = { trigger = { is_irish_late_maa    = yes } reference = irish_late_skirmishers }
	illustration = { trigger = { is_breton_maa   = yes }      reference = breton_skirmishers }	
	illustration = { trigger = { is_welsh_maa    = yes }      reference = welsh_skirmishers }
	illustration = { trigger = { is_welsh_maa    = yes }      reference = welsh_late_skirmishers }	
	illustration = { trigger = { is_english_maa  = yes }      reference = english_skirmishers }	
	illustration = { trigger = { is_norman_maa   = yes }      reference = norman_skirmishers }
	illustration = { trigger = { is_french_maa   = yes }      reference = french_skirmishers }
	illustration = { trigger = { is_spanish_maa  = yes }      reference = spanish_skirmishers }	
	illustration = { trigger = { is_spanish_late_maa  = yes } reference = spanish_late_skirmishers }		
	illustration = { trigger = { is_saxon_maa    = yes }      reference = saxon_skirmishers }
	illustration = { trigger = { is_anglosaxon_maa = yes }    reference = anglosaxon_skirmishers }
	illustration = { trigger = { is_italian_maa  = yes }      reference = italian_skirmishers }
	illustration = { trigger = { is_byzantine_maa = yes }     reference = byzantine_skirmishers }
	illustration = { trigger = { is_turkic_maa    = yes }     reference = turkic_skirmishers }
	illustration = { trigger = { is_mongol_maa    = yes }     reference = mongol_skirmishers }
	illustration = { trigger = { is_south_slavic_maa = yes } reference = south_slavic_skirmishers }
	illustration = { trigger = { is_south_slavic_late_maa = yes }  reference = south_slavic_late_skirmishers }	
	illustration = { trigger = { is_slavic_maa    = yes }     reference = slavic_skirmishers }
	illustration = { trigger = { is_westslavic_maa = yes }    reference = westslavic_skirmishers }
	illustration = { trigger = { is_westslavic_late_maa = yes }  reference = westslavic_late_skirmishers }	
	illustration = { trigger = { is_baltic_maa    = yes }     reference = baltic_skirmishers }
	illustration = { trigger = { is_baltic_late_maa = yes }    reference = baltic_late_skirmishers }	
	illustration = { trigger = { is_tungusic_maa    = yes }    reference = tungusic_skirmishers }	
	illustration = { trigger = { is_danish_late_maa    = yes } reference = danish_late_skirmishers }		
	illustration = { trigger = { is_north_late_maa     = yes } reference = north_late_skirmishers }		
	illustration = { trigger = { is_north_maa     = yes }     reference = north_skirmishers }
	illustration = { trigger = { is_holy_roman_maa    = yes } reference = holy_roman_skirmishers }
	illustration = { trigger = { is_holy_roman_late_maa = yes } reference = holy_roman_late_skirmishers }	
	illustration = { trigger = { is_frankish_maa    = yes }   reference = frankish_skirmishers }		
	illustration = { trigger = { is_arabian_maa   = yes }     reference = arabian_skirmishers }
	illustration = { trigger = { is_berber_maa    = yes }     reference = berber_skirmishers }
	illustration = { trigger = { is_african_maa   = yes }     reference = african_skirmishers }
	illustration = { trigger = { is_central_african_maa  = yes } reference = african_skirmishers }
	illustration = { trigger = { is_west_african_maa  = yes } reference = african_skirmishers }			
	illustration = { trigger = { is_east_african_maa  = yes } reference = east_african_skirmishers }		
	illustration = { trigger = { is_indonesian_maa  = yes }   reference = indonesian_skirmishers } 
	illustration = { trigger = { is_south_asian_maa  = yes }  reference = south_asian_skirmishers } 
	illustration = { trigger = { is_chinese_maa       = yes } reference = chinese_skirmishers }	
	illustration = { trigger = { is_asian_maa       = yes }   reference = asian_skirmishers }
	illustration = { trigger = { is_caucasian_maa  = yes }    reference = caucasian_skirmishers }
	illustration = { trigger = { is_persian_maa   = yes }     reference = persian_skirmishers }	
	illustration = { trigger = { is_indian_maa  = yes }       reference = indian_skirmishers }
	illustration = { trigger = { is_israelite_maa  = yes }    reference = israelite_skirmishers }
	illustration = { trigger = { is_cuman_maa  = yes }    	  reference = cuman_skirmishers }
	illustration = { trigger = { is_oghuz_maa  = yes }    	  reference = oghuz_skirmishers }	
	illustration = { trigger = { is_american_maa  = yes }     reference = american_skirmishers }		
	illustration = { reference = skirmishers }
}

bowmen = {
	type = archers
	
	damage = 25
	toughness = 10
	pursuit = 0
	screen = 0
	
	terrain_bonus = {
		hills = { damage = 10 toughness = 4 }
		forest = { toughness = 4 screen = 4 }
		taiga = { toughness = 4 screen = 4 }
	}

	counters = {
		skirmishers = 1
	}

	can_recruit = {
		NOR = {
			government_has_flag = government_is_nomadic
			government_has_flag = government_is_herder
			culture = {
				OR = {
					has_cultural_tradition = tradition_ep3_imperial_tagmata
					has_cultural_tradition = tradition_roman_legacy 
					has_cultural_tradition = tradition_rashidun_army 
					has_cultural_tradition = tradition_sasanian_army
				}
			}
		}
	}

	should_show_when_unavailable = {
		government_allows = subject_men_at_arms
	}

	buy_cost = { gold = bowmen_recruitment_cost }
	low_maintenance_cost = { gold = bowmen_low_maint_cost }
	high_maintenance_cost = { gold = bowmen_high_maint_cost }
	provision_cost = @provisions_cost_infantry_moderate

	holy_order_fallback = yes

	stack = 100
	ai_quality = { 
		value = culture_ai_weight_archers
		add = counter_synergy_ai_weight_archers
	}
	
	illustration = { trigger = { is_japanese_maa = yes }      reference = japanese_bowmen }
	illustration = { trigger = { is_emishi_maa = yes }        reference = emishi_bowmen }	
	illustration = { trigger = { is_korean_maa   = yes }      reference = korean_bowmen }
	illustration = { trigger = { is_tibetan_maa  = yes }      reference = tibetan_bowmen }
	illustration = { trigger = { is_scottish_maa = yes }      reference = scottish_bowmen }	
	illustration = { trigger = { is_scottish_late_maa = yes } reference = scottish_late_bowmen }		
	illustration = { trigger = { is_irish_maa    = yes }      reference = irish_bowmen }
	illustration = { trigger = { is_irish_late_maa    = yes } reference = irish_late_bowmen }
	illustration = { trigger = { is_breton_maa   = yes }      reference = breton_bowmen }	
	illustration = { trigger = { is_welsh_maa    = yes }      reference = welsh_bowmen }
	illustration = { trigger = { is_welsh_maa    = yes }      reference = welsh_late_bowmen }
	illustration = { trigger = { is_english_maa  = yes }      reference = english_bowmen }	
	illustration = { trigger = { is_norman_maa   = yes }      reference = norman_bowmen }
	illustration = { trigger = { is_french_maa   = yes }      reference = french_bowmen }
	illustration = { trigger = { is_spanish_maa  = yes }      reference = spanish_bowmen }	
	illustration = { trigger = { is_spanish_late_maa  = yes } reference = spanish_late_bowmen }		
	illustration = { trigger = { is_saxon_maa    = yes }      reference = saxon_bowmen }
	illustration = { trigger = { is_anglosaxon_maa = yes }    reference = anglosaxon_bowmen }
	illustration = { trigger = { is_italian_maa  = yes }      reference = italian_bowmen }
	illustration = { trigger = { is_byzantine_maa = yes }     reference = byzantine_bowmen }
	illustration = { trigger = { is_turkic_maa    = yes }     reference = turkic_bowmen }
	illustration = { trigger = { is_mongol_maa    = yes }     reference = mongol_bowmen }
	illustration = { trigger = { is_south_slavic_maa = yes } reference = south_slavic_bowmen }
	illustration = { trigger = { is_south_slavic_late_maa = yes }  reference = south_slavic_late_bowmen }	
	illustration = { trigger = { is_slavic_maa    = yes }     reference = slavic_bowmen }
	illustration = { trigger = { is_westslavic_maa = yes }    reference = westslavic_bowmen }
	illustration = { trigger = { is_westslavic_late_maa = yes }  reference = westslavic_late_bowmen }	
	illustration = { trigger = { is_baltic_maa    = yes }     reference = baltic_bowmen }
	illustration = { trigger = { is_baltic_late_maa = yes }    reference = baltic_late_bowmen }	
	illustration = { trigger = { is_tungusic_maa    = yes }    reference = tungusic_bowmen }	
	illustration = { trigger = { is_danish_late_maa    = yes } reference = danish_late_bowmen }			
	illustration = { trigger = { is_north_late_maa     = yes } reference = north_late_bowmen }	
	illustration = { trigger = { is_north_maa     = yes }     reference = north_bowmen }
	illustration = { trigger = { is_holy_roman_maa    = yes } reference = holy_roman_bowmen }
	illustration = { trigger = { is_holy_roman_late_maa = yes } reference = holy_roman_late_bowmen }	
	illustration = { trigger = { is_frankish_maa    = yes }   reference = frankish_bowmen }		
	illustration = { trigger = { is_arabian_maa   = yes }     reference = arabian_bowmen }
	illustration = { trigger = { is_berber_maa    = yes }     reference = berber_bowmen }
	illustration = { trigger = { is_african_maa   = yes }     reference = african_bowmen }
	illustration = { trigger = { is_central_african_maa  = yes } reference = african_bowmen }
	illustration = { trigger = { is_west_african_maa  = yes } reference = african_bowmen }			
	illustration = { trigger = { is_east_african_maa  = yes } reference = east_african_bowmen }		
	illustration = { trigger = { is_indonesian_maa  = yes }   reference = indonesian_bowmen } 
	illustration = { trigger = { is_south_asian_maa  = yes }  reference = south_asian_bowmen } 
	illustration = { trigger = { is_chinese_maa       = yes } reference = chinese_bowmen }	
	illustration = { trigger = { is_asian_maa       = yes }   reference = asian_bowmen }
	illustration = { trigger = { is_caucasian_maa  = yes }    reference = caucasian_bowmen }
	illustration = { trigger = { is_persian_maa   = yes }     reference = persian_bowmen }	
	illustration = { trigger = { is_indian_maa  = yes }       reference = indian_bowmen }
	illustration = { trigger = { is_israelite_maa  = yes }    reference = israelite_bowmen }
	illustration = { trigger = { is_cuman_maa  = yes }    	  reference = cuman_bowmen }
	illustration = { trigger = { is_oghuz_maa  = yes }    	  reference = oghuz_bowmen }	
	illustration = { trigger = { is_american_maa  = yes }     reference = american_bowmen }		
	illustration = { reference = bowmen }

}

light_horsemen = {
	type = light_cavalry
	
	damage = 22
	toughness = 15
	pursuit = 30
	screen = 30
	
	terrain_bonus = {
		plains = { damage = 15 }
		drylands = { damage = 15 }
		hills = { damage = -5 }
		mountains = { damage = -10 pursuit = -20 }
		desert_mountains = { damage = -15 pursuit = -20 }
		wetlands = { damage = -15 toughness = -10 pursuit = -30 screen = -30 }
	}
	
	counters = {
		archers = 1
	}

	can_recruit = {
		NOR = {
			government_has_flag = government_is_nomadic
			government_has_flag = government_is_herder
			culture = {
				OR = {
					has_cultural_tradition = tradition_ep3_imperial_tagmata
					has_cultural_tradition = tradition_roman_legacy 
					has_cultural_tradition = tradition_sasanian_army
				}
			}
		}
	}

	should_show_when_unavailable = {
		government_allows = subject_men_at_arms
		NOT = { has_access_to_maa = steppe_raiders }
	}

	access_through_subject = {
		NOT = { has_access_to_maa = steppe_raiders }
	}

	winter_bonus = {
		harsh_winter = { damage = -5 toughness = -2 }
	}

	buy_cost = { gold = light_cavalry_recruitment_cost }
	low_maintenance_cost = { gold = light_cavalry_low_maint_cost }
	high_maintenance_cost = { gold = light_cavalry_high_maint_cost }
	provision_cost = @provisions_cost_cavalry_cheap

	holy_order_fallback = yes

	stack = 100
	ai_quality = { 
		value = culture_ai_weight_light_cavalry
		add = counter_synergy_ai_weight_light_cavalry
	}
	illustration = { trigger = { is_japanese_maa = yes }      reference = japanese_light_cavalry }
	illustration = { trigger = { is_emishi_maa = yes }        reference = emishi_light_cavalry }	
	illustration = { trigger = { is_korean_maa   = yes }      reference = korean_light_cavalry }
	illustration = { trigger = { is_tibetan_maa  = yes }      reference = tibetan_light_cavalry }
	illustration = { trigger = { is_scottish_maa = yes }      reference = scottish_light_cavalry }	
	illustration = { trigger = { is_scottish_late_maa = yes } reference = scottish_late_light_cavalry }		
	illustration = { trigger = { is_irish_maa    = yes }      reference = irish_light_cavalry }
	illustration = { trigger = { is_irish_late_maa    = yes } reference = irish_late_light_cavalry }
	illustration = { trigger = { is_breton_maa   = yes }      reference = breton_light_cavalry }	
	illustration = { trigger = { is_welsh_maa    = yes }      reference = welsh_light_cavalry }
	illustration = { trigger = { is_welsh_maa    = yes }      reference = welsh_late_light_cavalry }	
	illustration = { trigger = { is_english_maa  = yes }      reference = english_light_cavalry }	
	illustration = { trigger = { is_norman_maa   = yes }      reference = norman_light_cavalry }
	illustration = { trigger = { is_french_maa   = yes }      reference = french_light_cavalry }
	illustration = { trigger = { is_spanish_maa  = yes }      reference = spanish_light_cavalry }	
	illustration = { trigger = { is_spanish_late_maa  = yes } reference = spanish_late_light_cavalry }		
	illustration = { trigger = { is_saxon_maa    = yes }      reference = saxon_light_cavalry }
	illustration = { trigger = { is_anglosaxon_maa = yes }    reference = anglosaxon_light_cavalry }
	illustration = { trigger = { is_italian_maa  = yes }      reference = italian_light_cavalry }
	illustration = { trigger = { is_byzantine_maa = yes }     reference = byzantine_light_cavalry }
	illustration = { trigger = { is_turkic_maa    = yes }     reference = turkic_light_cavalry }
	illustration = { trigger = { is_mongol_maa    = yes }     reference = mongol_light_cavalry }
	illustration = { trigger = { is_south_slavic_maa = yes } reference = south_slavic_light_cavalry }
	illustration = { trigger = { is_south_slavic_late_maa = yes }  reference = south_slavic_late_light_cavalry }	
	illustration = { trigger = { is_slavic_maa    = yes }     reference = slavic_light_cavalry }
	illustration = { trigger = { is_westslavic_maa = yes }    reference = westslavic_light_cavalry }
	illustration = { trigger = { is_westslavic_late_maa = yes }  reference = westslavic_late_light_cavalry }	
	illustration = { trigger = { is_baltic_maa    = yes }     reference = baltic_light_cavalry }
	illustration = { trigger = { is_baltic_late_maa = yes }    reference = baltic_late_light_cavalry }	
	illustration = { trigger = { is_tungusic_maa    = yes }    reference = tungusic_light_cavalry }	
	illustration = { trigger = { is_danish_late_maa    = yes } reference = danish_late_light_cavalry }			
	illustration = { trigger = { is_north_late_maa     = yes } reference = north_late_light_cavalry }	
	illustration = { trigger = { is_north_maa     = yes }     reference = north_light_cavalry }
	illustration = { trigger = { is_holy_roman_maa    = yes } reference = holy_roman_light_cavalry }
	illustration = { trigger = { is_holy_roman_late_maa = yes } reference = holy_roman_late_light_cavalry }	
	illustration = { trigger = { is_frankish_maa    = yes }   reference = frankish_light_cavalry }		
	illustration = { trigger = { is_arabian_maa   = yes }     reference = arabian_light_cavalry }
	illustration = { trigger = { is_berber_maa    = yes }     reference = berber_light_cavalry }
	illustration = { trigger = { is_african_maa   = yes }     reference = african_light_cavalry }
	illustration = { trigger = { is_central_african_maa  = yes } reference = african_light_cavalry }
	illustration = { trigger = { is_west_african_maa  = yes } reference = african_light_cavalry }			
	illustration = { trigger = { is_east_african_maa  = yes } reference = east_african_light_cavalry }		
	illustration = { trigger = { is_indonesian_maa  = yes }   reference = indonesian_light_cavalry } 
	illustration = { trigger = { is_south_asian_maa  = yes }  reference = south_asian_light_cavalry } 
	illustration = { trigger = { is_chinese_maa       = yes } reference = chinese_light_cavalry }	
	illustration = { trigger = { is_asian_maa       = yes }   reference = asian_light_cavalry }
	illustration = { trigger = { is_caucasian_maa  = yes }    reference = caucasian_light_cavalry }
	illustration = { trigger = { is_persian_maa   = yes }     reference = persian_light_cavalry }	
	illustration = { trigger = { is_indian_maa  = yes }       reference = indian_light_cavalry }
	illustration = { trigger = { is_israelite_maa  = yes }    reference = israelite_light_cavalry }
	illustration = { trigger = { is_cuman_maa  = yes }    	  reference = cuman_light_cavalry }
	illustration = { trigger = { is_oghuz_maa  = yes }    	  reference = oghuz_light_cavalry }	
	illustration = { trigger = { is_american_maa  = yes }     reference = american_light_cavalry }		
	illustration = { reference = light_cavalry }
}

pikemen_unit = {
	type = pikemen
	
	damage = 22
	toughness = 24
	pursuit = 0
	screen = 0
	
	terrain_bonus = {
		mountains = { toughness = 12 }
		desert_mountains = { toughness = 12 }
		hills = { toughness = 8 }
	}

	counters = {
		light_cavalry = 1
		heavy_cavalry = 1
		camel_cavalry = 1
		elephant_cavalry = 1
	}

	can_recruit = {
		NOR = {
			government_has_flag = government_is_nomadic
			government_has_flag = government_is_herder
			culture = {
				OR = {
					has_cultural_tradition = tradition_ep3_imperial_tagmata
					has_cultural_tradition = tradition_roman_legacy 
					has_cultural_tradition = tradition_sasanian_army
				}
			}
		}
	}

	should_show_when_unavailable = {
		government_allows = subject_men_at_arms
	}

	buy_cost = { gold = pikemen_recruitment_cost }
	low_maintenance_cost = { gold = pikemen_low_maint_cost }
	high_maintenance_cost = { gold = pikemen_high_maint_cost }
	provision_cost = @provisions_cost_infantry_expensive

	holy_order_fallback = yes

	stack = 100
	ai_quality = {
		value = culture_ai_weight_pikemen
		add = counter_synergy_ai_weight_pikemen
	}
	illustration = { trigger = { is_japanese_maa = yes }      reference = japanese_pikemen }
	illustration = { trigger = { is_emishi_maa = yes }        reference = emishi_pikemen }	
	illustration = { trigger = { is_korean_maa   = yes }      reference = korean_pikemen }
	illustration = { trigger = { is_tibetan_maa  = yes }      reference = tibetan_pikemen }
	illustration = { trigger = { is_scottish_maa = yes }      reference = scottish_pikemen }	
	illustration = { trigger = { is_scottish_late_maa = yes } reference = scottish_late_pikemen }		
	illustration = { trigger = { is_irish_maa    = yes }      reference = irish_pikemen }
	illustration = { trigger = { is_irish_late_maa    = yes } reference = irish_late_pikemen }
	illustration = { trigger = { is_breton_maa   = yes }      reference = breton_pikemen }	
	illustration = { trigger = { is_welsh_maa    = yes }      reference = welsh_pikemen }
	illustration = { trigger = { is_welsh_maa    = yes }      reference = welsh_late_pikemen }	
	illustration = { trigger = { is_english_maa  = yes }      reference = english_pikemen }	
	illustration = { trigger = { is_norman_maa   = yes }      reference = norman_pikemen }
	illustration = { trigger = { is_french_maa   = yes }      reference = french_pikemen }
	illustration = { trigger = { is_spanish_maa  = yes }      reference = spanish_pikemen }	
	illustration = { trigger = { is_spanish_late_maa  = yes } reference = spanish_late_pikemen }		
	illustration = { trigger = { is_saxon_maa    = yes }      reference = saxon_pikemen }
	illustration = { trigger = { is_anglosaxon_maa = yes }    reference = anglosaxon_pikemen }
	illustration = { trigger = { is_italian_maa  = yes }      reference = italian_pikemen }
	illustration = { trigger = { is_byzantine_maa = yes }     reference = byzantine_pikemen }
	illustration = { trigger = { is_turkic_maa    = yes }     reference = turkic_pikemen }
	illustration = { trigger = { is_mongol_maa    = yes }     reference = mongol_pikemen }
	illustration = { trigger = { is_south_slavic_maa = yes } reference = south_slavic_pikemen }
	illustration = { trigger = { is_south_slavic_late_maa = yes }  reference = south_slavic_late_pikemen }	
	illustration = { trigger = { is_slavic_maa    = yes }     reference = slavic_pikemen }
	illustration = { trigger = { is_westslavic_maa = yes }    reference = westslavic_pikemen }
	illustration = { trigger = { is_westslavic_late_maa = yes }  reference = westslavic_late_pikemen }	
	illustration = { trigger = { is_baltic_maa    = yes }     reference = baltic_pikemen }
	illustration = { trigger = { is_baltic_late_maa = yes }    reference = baltic_late_pikemen }	
	illustration = { trigger = { is_tungusic_maa    = yes }    reference = tungusic_pikemen }
	illustration = { trigger = { is_danish_late_maa    = yes } reference = danish_late_pikemen }	
	illustration = { trigger = { is_north_late_maa     = yes } reference = north_late_pikemen }			
	illustration = { trigger = { is_north_maa     = yes }     reference = north_pikemen }
	illustration = { trigger = { is_holy_roman_maa    = yes } reference = holy_roman_pikemen }
	illustration = { trigger = { is_holy_roman_late_maa = yes } reference = holy_roman_late_pikemen }	
	illustration = { trigger = { is_frankish_maa    = yes }   reference = frankish_pikemen }		
	illustration = { trigger = { is_arabian_maa   = yes }     reference = arabian_pikemen }
	illustration = { trigger = { is_berber_maa    = yes }     reference = berber_pikemen }
	illustration = { trigger = { is_african_maa   = yes }     reference = african_pikemen }
	illustration = { trigger = { is_central_african_maa  = yes } reference = african_pikemen }
	illustration = { trigger = { is_west_african_maa  = yes } reference = african_pikemen }			
	illustration = { trigger = { is_east_african_maa  = yes } reference = east_african_pikemen }		
	illustration = { trigger = { is_indonesian_maa  = yes }   reference = indonesian_pikemen } 
	illustration = { trigger = { is_south_asian_maa  = yes }  reference = south_asian_pikemen } 
	illustration = { trigger = { is_chinese_maa       = yes } reference = chinese_pikemen }	
	illustration = { trigger = { is_asian_maa       = yes }   reference = asian_pikemen }
	illustration = { trigger = { is_caucasian_maa  = yes }    reference = caucasian_pikemen }
	illustration = { trigger = { is_persian_maa   = yes }     reference = persian_pikemen }	
	illustration = { trigger = { is_indian_maa  = yes }       reference = indian_pikemen }
	illustration = { trigger = { is_israelite_maa  = yes }    reference = israelite_pikemen }
	illustration = { trigger = { is_cuman_maa  = yes }    	  reference = cuman_pikemen }
	illustration = { trigger = { is_oghuz_maa  = yes }    	  reference = oghuz_pikemen }	
	illustration = { trigger = { is_american_maa  = yes }     reference = american_pikemen }		
	illustration = { reference = pikemen }
}



#Tribal Era
armored_footmen = {
	type = heavy_infantry
	
	damage = 32
	toughness = 22
	pursuit = 0
	screen = 0
	
	counters = {
		pikemen = 1
	}

	can_recruit = {
		culture = {
			has_innovation = innovation_quilted_armor
		}
		NOT = {
			culture = { has_cultural_parameter = strength_in_numbers_heavy_maa_ban }
		}
		NOR = {
			government_has_flag = government_is_nomadic
			government_has_flag = government_is_herder
			culture = {
				OR = {
					has_cultural_tradition = tradition_ep3_imperial_tagmata
					has_cultural_tradition = tradition_roman_legacy 
				}
			}
		}
	}
	
	should_show_when_unavailable = {
		government_allows = subject_men_at_arms
	}

	buy_cost = { gold = heavy_infantry_recruitment_cost }
	low_maintenance_cost = { gold = heavy_infantry_low_maint_cost }
	high_maintenance_cost = { gold = heavy_infantry_high_maint_cost }
	provision_cost = @provisions_cost_infantry_moderate

	holy_order_fallback = yes

	stack = 100
	ai_quality = {
		value = culture_ai_weight_heavy_infantry
		add = counter_synergy_ai_weight_heavy_infantry
	}
	illustration = { trigger = { is_japanese_maa = yes }      reference = japanese_heavy_infantry }
	illustration = { trigger = { is_emishi_maa = yes }        reference = emishi_heavy_infantry }	
	illustration = { trigger = { is_korean_maa   = yes }      reference = korean_heavy_infantry }
	illustration = { trigger = { is_tibetan_maa  = yes }      reference = tibetan_heavy_infantry }
	illustration = { trigger = { is_scottish_maa = yes }      reference = scottish_heavy_infantry }	
	illustration = { trigger = { is_scottish_late_maa = yes } reference = scottish_late_heavy_infantry }		
	illustration = { trigger = { is_irish_maa    = yes }      reference = irish_heavy_infantry }
	illustration = { trigger = { is_irish_late_maa    = yes } reference = irish_late_heavy_infantry }
	illustration = { trigger = { is_breton_maa   = yes }      reference = breton_heavy_infantry }	
	illustration = { trigger = { is_welsh_maa    = yes }      reference = welsh_heavy_infantry }
	illustration = { trigger = { is_welsh_maa    = yes }      reference = welsh_late_heavy_infantry }	
	illustration = { trigger = { is_english_maa  = yes }      reference = english_heavy_infantry }	
	illustration = { trigger = { is_norman_maa   = yes }      reference = norman_heavy_infantry }
	illustration = { trigger = { is_french_maa   = yes }      reference = french_heavy_infantry }
	illustration = { trigger = { is_spanish_maa  = yes }      reference = spanish_heavy_infantry }	
	illustration = { trigger = { is_spanish_late_maa  = yes } reference = spanish_late_heavy_infantry }		
	illustration = { trigger = { is_saxon_maa    = yes }      reference = saxon_heavy_infantry }
	illustration = { trigger = { is_anglosaxon_maa = yes }    reference = anglosaxon_heavy_infantry }
	illustration = { trigger = { is_italian_maa  = yes }      reference = italian_heavy_infantry }
	illustration = { trigger = { is_byzantine_maa = yes }     reference = byzantine_heavy_infantry }
	illustration = { trigger = { is_turkic_maa    = yes }     reference = turkic_heavy_infantry }
	illustration = { trigger = { is_mongol_maa    = yes }     reference = mongol_heavy_infantry }
	illustration = { trigger = { is_south_slavic_maa = yes } reference = south_slavic_heavy_infantry }
	illustration = { trigger = { is_south_slavic_late_maa = yes }  reference = south_slavic_late_heavy_infantry }	
	illustration = { trigger = { is_slavic_maa    = yes }     reference = slavic_heavy_infantry }
	illustration = { trigger = { is_westslavic_maa = yes }    reference = westslavic_heavy_infantry }
	illustration = { trigger = { is_westslavic_late_maa = yes }  reference = westslavic_late_heavy_infantry }	
	illustration = { trigger = { is_baltic_maa    = yes }     reference = baltic_heavy_infantry }
	illustration = { trigger = { is_baltic_late_maa = yes }    reference = baltic_late_heavy_infantry }	
	illustration = { trigger = { is_tungusic_maa    = yes }    reference = tungusic_heavy_infantry }
	illustration = { trigger = { is_danish_late_maa    = yes } reference = danish_late_heavy_infantry }		
	illustration = { trigger = { is_north_late_maa     = yes } reference = north_late_heavy_infantry }		
	illustration = { trigger = { is_north_maa     = yes }     reference = north_heavy_infantry }
	illustration = { trigger = { is_holy_roman_maa    = yes } reference = holy_roman_heavy_infantry }
	illustration = { trigger = { is_holy_roman_late_maa = yes } reference = holy_roman_late_heavy_infantry }	
	illustration = { trigger = { is_frankish_maa    = yes }   reference = frankish_heavy_infantry }		
	illustration = { trigger = { is_arabian_maa   = yes }     reference = arabian_heavy_infantry }
	illustration = { trigger = { is_berber_maa    = yes }     reference = berber_heavy_infantry }
	illustration = { trigger = { is_african_maa   = yes }     reference = african_heavy_infantry }
	illustration = { trigger = { is_central_african_maa  = yes } reference = african_heavy_infantry }
	illustration = { trigger = { is_west_african_maa  = yes } reference = african_heavy_infantry }			
	illustration = { trigger = { is_east_african_maa  = yes } reference = east_african_heavy_infantry }		
	illustration = { trigger = { is_indonesian_maa  = yes }   reference = indonesian_heavy_infantry } 
	illustration = { trigger = { is_south_asian_maa  = yes }  reference = south_asian_heavy_infantry } 
	illustration = { trigger = { is_chinese_maa       = yes } reference = chinese_heavy_infantry }	
	illustration = { trigger = { is_asian_maa       = yes }   reference = asian_heavy_infantry }
	illustration = { trigger = { is_caucasian_maa  = yes }    reference = caucasian_heavy_infantry }
	illustration = { trigger = { is_persian_maa   = yes }     reference = persian_heavy_infantry }	
	illustration = { trigger = { is_indian_maa  = yes }       reference = indian_heavy_infantry }
	illustration = { trigger = { is_israelite_maa  = yes }    reference = israelite_heavy_infantry }
	illustration = { trigger = { is_cuman_maa  = yes }    	  reference = cuman_heavy_infantry }
	illustration = { trigger = { is_oghuz_maa  = yes }    	  reference = oghuz_heavy_infantry }	
	illustration = { trigger = { is_american_maa  = yes }     reference = american_heavy_infantry }		
	illustration = { reference = heavy_infantry }
}

onager = {
	type = siege_weapon
	fights_in_main_phase = no
	
	damage = 0
	toughness = 12
	
	siege_tier = 1
	siege_value = 0.2

	can_recruit = {
		culture = {
			has_innovation = innovation_catapult
		}
		NOR = {
			government_has_flag = government_is_nomadic
			government_has_flag = government_is_herder
		}
	}
	
	should_show_when_unavailable = {
		government_allows = subject_men_at_arms
	}

	buy_cost = { gold = onager_recruitment_cost }
	low_maintenance_cost = { gold = onager_low_maint_cost }
	high_maintenance_cost = { gold = onager_high_maint_cost }
	provision_cost = @provisions_cost_special_cheap
	
	stack = 10
	allowed_in_hired_troops = no
}

#Medieval Era
armored_horsemen = {
	type = heavy_cavalry
	
	damage = 100
	toughness = 35
	pursuit = 20
	screen = 0
	
	terrain_bonus = {
		plains = { damage = 30 }
		drylands = { damage = 30 }
		hills = { damage = -20 }
		mountains = { damage = -75 }
		desert_mountains = { damage = -75 }
		wetlands = { damage = -75 toughness = -10 pursuit = -10 }
	}

	counters = {
		archers = 1
	}

	can_recruit = {
		culture = {
			has_innovation = innovation_arched_saddle
		}
		NOR = {
			government_has_flag = government_is_nomadic
			government_has_flag = government_is_herder
		}
	}

	should_show_when_unavailable = {
		government_allows = subject_men_at_arms
		culture = { has_cultural_era_or_later = culture_era_early_medieval }
		NOT = { has_access_to_maa = nomad_lancers }
	}
	
	access_through_subject = {
		NOT = { has_access_to_maa = nomad_lancers }
	}

	winter_bonus = {
		normal_winter = { damage = -10 toughness = -5 }
		harsh_winter = { damage = -20 toughness = -10 }
	}

	buy_cost = { gold = heavy_cavalry_recruitment_cost }
	low_maintenance_cost = { gold = heavy_cavalry_low_maint_cost }
	high_maintenance_cost = { gold = heavy_cavalry_high_maint_cost }
	provision_cost = @provisions_cost_cavalry_expensive
	
	stack = 50
	ai_quality = { value = culture_ai_weight_heavy_cavalry }
	illustration = { trigger = { is_japanese_maa = yes }      reference = japanese_heavy_cavalry }
	illustration = { trigger = { is_emishi_maa = yes }        reference = emishi_heavy_cavalry }	
	illustration = { trigger = { is_korean_maa   = yes }      reference = korean_heavy_cavalry }
	illustration = { trigger = { is_tibetan_maa  = yes }      reference = tibetan_heavy_cavalry }
	illustration = { trigger = { is_scottish_maa = yes }      reference = scottish_heavy_cavalry }	
	illustration = { trigger = { is_scottish_late_maa = yes } reference = scottish_late_heavy_cavalry }		
	illustration = { trigger = { is_irish_maa    = yes }      reference = irish_heavy_cavalry }
	illustration = { trigger = { is_irish_late_maa    = yes } reference = irish_late_heavy_cavalry }
	illustration = { trigger = { is_breton_maa   = yes }      reference = breton_heavy_cavalry }	
	illustration = { trigger = { is_welsh_maa    = yes }      reference = welsh_heavy_cavalry }
	illustration = { trigger = { is_welsh_maa    = yes }      reference = welsh_late_heavy_cavalry }	
	illustration = { trigger = { is_english_maa  = yes }      reference = english_heavy_cavalry }	
	illustration = { trigger = { is_norman_maa   = yes }      reference = norman_heavy_cavalry }
	illustration = { trigger = { is_french_maa   = yes }      reference = french_heavy_cavalry }
	illustration = { trigger = { is_spanish_maa  = yes }      reference = spanish_heavy_cavalry }	
	illustration = { trigger = { is_spanish_late_maa  = yes } reference = spanish_late_heavy_cavalry }		
	illustration = { trigger = { is_saxon_maa    = yes }      reference = saxon_heavy_cavalry }
	illustration = { trigger = { is_anglosaxon_maa = yes }    reference = anglosaxon_heavy_cavalry }
	illustration = { trigger = { is_italian_maa  = yes }      reference = italian_heavy_cavalry }
	illustration = { trigger = { is_byzantine_maa = yes }     reference = byzantine_heavy_cavalry }
	illustration = { trigger = { is_turkic_maa    = yes }     reference = turkic_heavy_cavalry }
	illustration = { trigger = { is_mongol_maa    = yes }     reference = mongol_heavy_cavalry }
	illustration = { trigger = { is_south_slavic_maa = yes } reference = south_slavic_heavy_cavalry }
	illustration = { trigger = { is_south_slavic_late_maa = yes }  reference = south_slavic_late_heavy_cavalry }	
	illustration = { trigger = { is_slavic_maa    = yes }     reference = slavic_heavy_cavalry }
	illustration = { trigger = { is_westslavic_maa = yes }    reference = westslavic_heavy_cavalry }
	illustration = { trigger = { is_westslavic_late_maa = yes }  reference = westslavic_late_heavy_cavalry }	
	illustration = { trigger = { is_baltic_maa    = yes }     reference = baltic_heavy_cavalry }
	illustration = { trigger = { is_baltic_late_maa = yes }    reference = baltic_late_heavy_cavalry }	
	illustration = { trigger = { is_tungusic_maa    = yes }    reference = tungusic_heavy_cavalry }	
	illustration = { trigger = { is_danish_late_maa    = yes } reference = danish_late_heavy_cavalry }		
	illustration = { trigger = { is_north_late_maa     = yes } reference = north_late_heavy_cavalry }		
	illustration = { trigger = { is_north_maa     = yes }     reference = north_heavy_cavalry }
	illustration = { trigger = { is_holy_roman_maa    = yes } reference = holy_roman_heavy_cavalry }
	illustration = { trigger = { is_holy_roman_late_maa = yes } reference = holy_roman_late_heavy_cavalry }	
	illustration = { trigger = { is_frankish_maa    = yes }   reference = frankish_heavy_cavalry }		
	illustration = { trigger = { is_arabian_maa   = yes }     reference = arabian_heavy_cavalry }
	illustration = { trigger = { is_berber_maa    = yes }     reference = berber_heavy_cavalry }
	illustration = { trigger = { is_african_maa   = yes }     reference = african_heavy_cavalry }
	illustration = { trigger = { is_central_african_maa  = yes } reference = african_heavy_cavalry }
	illustration = { trigger = { is_west_african_maa  = yes } reference = african_heavy_cavalry }			
	illustration = { trigger = { is_east_african_maa  = yes } reference = east_african_heavy_cavalry }		
	illustration = { trigger = { is_indonesian_maa  = yes }   reference = indonesian_heavy_cavalry } 
	illustration = { trigger = { is_south_asian_maa  = yes }  reference = south_asian_heavy_cavalry } 
	illustration = { trigger = { is_chinese_maa       = yes } reference = chinese_heavy_cavalry }	
	illustration = { trigger = { is_asian_maa       = yes }   reference = asian_heavy_cavalry }
	illustration = { trigger = { is_caucasian_maa  = yes }    reference = caucasian_heavy_cavalry }
	illustration = { trigger = { is_persian_maa   = yes }     reference = persian_heavy_cavalry }	
	illustration = { trigger = { is_indian_maa  = yes }       reference = indian_heavy_cavalry }
	illustration = { trigger = { is_israelite_maa  = yes }    reference = israelite_heavy_cavalry }
	illustration = { trigger = { is_cuman_maa  = yes }    	  reference = cuman_heavy_cavalry }
	illustration = { trigger = { is_oghuz_maa  = yes }    	  reference = oghuz_heavy_cavalry }	
	illustration = { trigger = { is_american_maa  = yes }     reference = american_heavy_cavalry }		
	illustration = { reference = heavy_cavalry }
}

mangonel = {
	type = siege_weapon
	fights_in_main_phase = no
	
	damage = 0
	toughness = 12
	
	siege_tier = 2
	siege_value = 0.3

	can_recruit = {
		culture = {
			has_innovation = innovation_mangonel
		}
		NOR = {
			government_has_flag = government_is_nomadic
			government_has_flag = government_is_herder
		}
	}
	
	should_show_when_unavailable = {
		government_allows = subject_men_at_arms
		culture = { has_cultural_era_or_later = culture_era_early_medieval }
	}

	buy_cost = { gold = mangonel_recruitment_cost }
	low_maintenance_cost = { gold = mangonel_low_maint_cost }
	high_maintenance_cost = { gold = mangonel_high_maint_cost }
	provision_cost = @provisions_cost_special_moderate
	
	stack = 10
	allowed_in_hired_troops = no
}

#High Medieval Era
crossbowmen = {
	type = archers
	
	damage = 42
	toughness = 18
	pursuit = 0
	screen = 0
	
	terrain_bonus = {
		hills = { damage = 10 }
		plains = { toughness = -8 }
		drylands = { toughness = -8 }
		desert = { toughness = -8 }
	}

	counters = {
		heavy_infantry = 1
		heavy_cavalry = 1
		archer_cavalry = 0.5
	}

	can_recruit = {
		culture = {
			has_innovation = innovation_advanced_bowmaking
		}
		NOR = {
			government_has_flag = government_is_nomadic
			government_has_flag = government_is_herder
		}
	}

	should_show_when_unavailable = {
		government_allows = subject_men_at_arms
		culture = { has_cultural_era_or_later = culture_era_high_medieval }
	}

	buy_cost = { gold = crossbowmen_recruitment_cost }
	low_maintenance_cost = { gold = crossbowmen_low_maint_cost }
	high_maintenance_cost = { gold = crossbowmen_high_maint_cost }
	provision_cost = @provisions_cost_infantry_moderate

	ai_quality = {
		value = counter_synergy_ai_weight_archers
	}
	
	holy_order_fallback = yes
	
	stack = 100

	illustration = { trigger = { is_japanese_maa = yes }      reference = japanese_crossbowmen }
	illustration = { trigger = { is_emishi_maa = yes }        reference = emishi_crossbowmen }	
	illustration = { trigger = { is_korean_maa   = yes }      reference = korean_crossbowmen }
	illustration = { trigger = { is_tibetan_maa  = yes }      reference = tibetan_crossbowmen }
	illustration = { trigger = { is_scottish_maa = yes }      reference = scottish_crossbowmen }	
	illustration = { trigger = { is_scottish_late_maa = yes } reference = scottish_late_crossbowmen }		
	illustration = { trigger = { is_irish_maa    = yes }      reference = irish_crossbowmen }
	illustration = { trigger = { is_irish_late_maa    = yes } reference = irish_late_crossbowmen }
	illustration = { trigger = { is_breton_maa   = yes }      reference = breton_crossbowmen }	
	illustration = { trigger = { is_welsh_maa    = yes }      reference = welsh_crossbowmen }
	illustration = { trigger = { is_welsh_maa    = yes }      reference = welsh_late_crossbowmen }		
	illustration = { trigger = { is_english_maa  = yes }      reference = english_crossbowmen }	
	illustration = { trigger = { is_norman_maa   = yes }      reference = norman_crossbowmen }
	illustration = { trigger = { is_french_maa   = yes }      reference = french_crossbowmen }
	illustration = { trigger = { is_spanish_maa  = yes }      reference = spanish_crossbowmen }	
	illustration = { trigger = { is_spanish_late_maa  = yes } reference = spanish_late_crossbowmen }		
	illustration = { trigger = { is_saxon_maa    = yes }      reference = saxon_crossbowmen }
	illustration = { trigger = { is_anglosaxon_maa = yes }    reference = anglosaxon_crossbowmen }
	illustration = { trigger = { is_italian_maa  = yes }      reference = italian_crossbowmen }
	illustration = { trigger = { is_byzantine_maa = yes }     reference = byzantine_crossbowmen }
	illustration = { trigger = { is_turkic_maa    = yes }     reference = turkic_crossbowmen }
	illustration = { trigger = { is_mongol_maa    = yes }     reference = mongol_crossbowmen }
	illustration = { trigger = { is_south_slavic_maa = yes } reference = south_slavic_crossbowmen }
	illustration = { trigger = { is_south_slavic_late_maa = yes }  reference = south_slavic_late_crossbowmen }	
	illustration = { trigger = { is_slavic_maa    = yes }     reference = slavic_crossbowmen }
	illustration = { trigger = { is_westslavic_maa = yes }    reference = westslavic_crossbowmen }
	illustration = { trigger = { is_westslavic_late_maa = yes }  reference = westslavic_late_crossbowmen }	
	illustration = { trigger = { is_baltic_maa    = yes }     reference = baltic_crossbowmen }
	illustration = { trigger = { is_baltic_late_maa = yes }    reference = baltic_late_crossbowmen }	
	illustration = { trigger = { is_tungusic_maa    = yes }    reference = tungusic_crossbowmen }
	illustration = { trigger = { is_danish_late_maa    = yes } reference = danish_late_crossbowmen }		
	illustration = { trigger = { is_north_late_maa     = yes } reference = north_late_crossbowmen }		
	illustration = { trigger = { is_north_maa     = yes }     reference = north_crossbowmen }
	illustration = { trigger = { is_holy_roman_maa    = yes } reference = holy_roman_crossbowmen }
	illustration = { trigger = { is_holy_roman_late_maa = yes } reference = holy_roman_late_crossbowmen }	
	illustration = { trigger = { is_frankish_maa    = yes }   reference = frankish_crossbowmen }		
	illustration = { trigger = { is_arabian_maa   = yes }     reference = arabian_crossbowmen }
	illustration = { trigger = { is_berber_maa    = yes }     reference = berber_crossbowmen }
	illustration = { trigger = { is_african_maa   = yes }     reference = african_crossbowmen }
	illustration = { trigger = { is_central_african_maa  = yes } reference = african_crossbowmen }
	illustration = { trigger = { is_west_african_maa  = yes } reference = african_crossbowmen }			
	illustration = { trigger = { is_east_african_maa  = yes } reference = east_african_crossbowmen }		
	illustration = { trigger = { is_indonesian_maa  = yes }   reference = indonesian_crossbowmen } 
	illustration = { trigger = { is_south_asian_maa  = yes }  reference = south_asian_crossbowmen } 
	illustration = { trigger = { is_chinese_maa       = yes } reference = chinese_crossbowmen }	
	illustration = { trigger = { is_asian_maa       = yes }   reference = asian_crossbowmen }
	illustration = { trigger = { is_caucasian_maa  = yes }    reference = caucasian_crossbowmen }
	illustration = { trigger = { is_persian_maa   = yes }     reference = persian_crossbowmen }	
	illustration = { trigger = { is_indian_maa  = yes }       reference = indian_crossbowmen }
	illustration = { trigger = { is_israelite_maa  = yes }    reference = israelite_crossbowmen }
	illustration = { trigger = { is_cuman_maa  = yes }    	  reference = cuman_crossbowmen }
	illustration = { trigger = { is_oghuz_maa  = yes }    	  reference = oghuz_crossbowmen }	
	illustration = { trigger = { is_american_maa  = yes }     reference = american_crossbowmen }		
	illustration = { reference = crossbowmen }	
}

trebuchet = {
	type = siege_weapon
	fights_in_main_phase = no
	
	damage = 0
	toughness = 12
	
	siege_tier = 3
	siege_value = 0.4

	can_recruit = {
		culture = {
			has_innovation = innovation_trebuchet
		}
		NOR = {
			government_has_flag = government_is_nomadic
			government_has_flag = government_is_herder
		}
	}
	
	should_show_when_unavailable = {
		government_allows = subject_men_at_arms
		culture = { has_cultural_era_or_later = culture_era_high_medieval }
	}

	buy_cost = { gold = trebuchet_recruitment_cost }
	low_maintenance_cost = { gold = trebuchet_low_maint_cost }
	high_maintenance_cost = { gold = trebuchet_high_maint_cost }
	provision_cost = @provisions_cost_special_expensive
	
	stack = 10
	allowed_in_hired_troops = no

}

#Late Medieval Era
bombard = {
	type = siege_weapon
	fights_in_main_phase = no
	
	damage = 0
	toughness = 12
	
	siege_tier = 4
	siege_value = 0.6

	can_recruit = {
		culture = {
			has_cultural_parameter = unlock_late_medieval_gunpowder_units
			NOR = {
				has_cultural_pillar = heritage_chinese
				has_cultural_pillar = heritage_korean
				has_cultural_pillar = heritage_japonic
			}
		}
		NOR = {
			government_has_flag = government_is_nomadic
			government_has_flag = government_is_herder
		}
	}
	
	should_show_when_unavailable = {
		government_allows = subject_men_at_arms
		culture = { has_cultural_era_or_later = culture_era_late_medieval }
	}

	buy_cost = { gold = bombard_recruitment_cost }
	low_maintenance_cost = { gold = bombard_low_maint_cost }
	high_maintenance_cost = { gold = bombard_high_maint_cost }
	provision_cost = @provisions_cost_special_bankrupting
	
	stack = 10
	allowed_in_hired_troops = no
}

handgunners = {
	type = gunpowder

	damage = 52
	toughness = 12
	pursuit = 0
	screen = 5

	can_recruit = {
		gunpowder_raise_limit_existing_gunpowder_units < gunpowder_raise_limit_existing_gunpowder_buildings	# one powder magazine must be owned to support three handgunner regiments, regardless of maa size
		culture = { has_cultural_parameter = unlock_late_medieval_gunpowder_units }
	}

	terrain_bonus = {
		wetlands = { damage = -10 }
		floodplains = { damage = -5 }
	}

	counters = {
		heavy_infantry = 1
	}

	buy_cost = { gold = handgunner_recruitment_cost }
	low_maintenance_cost = { gold = handgunner_low_maint_cost }
	high_maintenance_cost = { gold = handgunner_high_maint_cost }
	provision_cost = @provisions_cost_infantry_moderate

	ai_quality = {
		value = counter_synergy_ai_weight_gunpowder
	}

	stack = 100

	illustration = { trigger = { is_slavic_maa  = yes }       reference = handgonne_slavic }		
	illustration = { trigger = { is_japanese_maa = yes }      reference = handgonne_japanese }
	illustration = { trigger = { is_emishi_maa = yes }        reference = handgonne_japanese }		
	illustration = { trigger = { is_korean_maa   = yes }      reference = handgonne_asian }
	illustration = { trigger = { is_tibetan_maa  = yes }      reference = handgonne_asian }
	illustration = { trigger = { is_persian_maa   = yes }     reference = handgonne_arabian }
	illustration = { trigger = { is_turkic_maa    = yes }     reference = handgonne_turkic }
	illustration = { trigger = { is_mongol_maa    = yes }     reference = handgonne_turkic }
	illustration = { trigger = { is_arabian_maa   = yes }     reference = handgonne_arabian }
	illustration = { trigger = { is_berber_maa    = yes }     reference = handgonne_arabian }
	illustration = { trigger = { is_african_maa   = yes }     reference = handgonne_african }
	illustration = { trigger = { is_central_african_maa  = yes } reference = handgonne_african }		
	illustration = { trigger = { is_east_african_maa  = yes } reference = handgonne_african }	
	illustration = { trigger = { is_west_african_maa  = yes } reference = handgonne_african }		
	illustration = { trigger = { is_indonesian_maa  = yes }   reference = handgonne_asian } 
	illustration = { trigger = { is_south_asian_maa  = yes }  reference = handgonne_asian }
	illustration = { trigger = { is_asian_maa       = yes }   reference = handgonne_asian }
	illustration = { trigger = { is_chinese_maa       = yes } reference = handgonne_chinese }		
	illustration = { trigger = { is_cuman_maa  = yes }    	  reference = handgonne_turkic }
	illustration = { trigger = { is_indian_maa  = yes }       reference = handgonne_indian }
	illustration = { trigger = { is_oghuz_maa  = yes }    	  reference = handgonne_arabian }
	illustration = { trigger = { is_american_maa  = yes }     reference = handgonne_american }		
	illustration = { reference = handgonne }

}

# Special
house_guard = {
	type = heavy_infantry
	can_recruit = {
		exists = dynasty
		dynasty = {
			has_dynasty_perk = warfare_legacy_5
		}
		NOT = {
			culture = { has_cultural_parameter = strength_in_numbers_heavy_maa_ban }
		}
	}
	
	damage = 40
	toughness = 32
	pursuit = 0
	screen = 24
	
	counters = {
		pikemen = 2
		archers = 2
	}
	
	buy_cost = { gold = 50 }
	low_maintenance_cost = { gold = 0 }
	high_maintenance_cost = { gold = 1 }
	provision_cost = @provisions_cost_infantry_expensive
	
	max_regiments = 1
	
	stack = 100
	ai_quality = { value = 100 }
	
	illustration = { trigger = { is_japanese_maa = yes }      reference = japanese_house_guard }
	illustration = { trigger = { is_emishi_maa = yes }        reference = emishi_house_guard }	
	illustration = { trigger = { is_korean_maa   = yes }      reference = korean_house_guard }
	illustration = { trigger = { is_tibetan_maa  = yes }      reference = tibetan_house_guard }
	illustration = { trigger = { is_scottish_maa = yes }      reference = scottish_house_guard }	
	illustration = { trigger = { is_scottish_late_maa = yes } reference = scottish_late_house_guard }		
	illustration = { trigger = { is_irish_maa    = yes }      reference = irish_house_guard }
	illustration = { trigger = { is_irish_late_maa    = yes } reference = irish_late_house_guard }
	illustration = { trigger = { is_breton_maa   = yes }      reference = breton_house_guard }	
	illustration = { trigger = { is_welsh_maa    = yes }      reference = welsh_house_guard }
	illustration = { trigger = { is_english_maa  = yes }      reference = english_house_guard }	
	illustration = { trigger = { is_norman_maa   = yes }      reference = norman_house_guard }
	illustration = { trigger = { is_french_maa   = yes }      reference = french_house_guard }
	illustration = { trigger = { is_spanish_maa  = yes }      reference = spanish_house_guard }	
	illustration = { trigger = { is_spanish_late_maa  = yes } reference = spanish_late_house_guard }		
	illustration = { trigger = { is_saxon_maa    = yes }      reference = saxon_house_guard }
	illustration = { trigger = { is_anglosaxon_maa = yes }    reference = anglosaxon_house_guard }
	illustration = { trigger = { is_italian_maa  = yes }      reference = italian_house_guard }
	illustration = { trigger = { is_byzantine_maa = yes }     reference = byzantine_house_guard }
	illustration = { trigger = { is_turkic_maa    = yes }     reference = turkic_house_guard }
	illustration = { trigger = { is_mongol_maa    = yes }     reference = mongol_house_guard }
	illustration = { trigger = { is_south_slavic_maa = yes } reference = south_slavic_house_guard }
	illustration = { trigger = { is_south_slavic_late_maa = yes }  reference = south_slavic_late_house_guard }	
	illustration = { trigger = { is_slavic_maa    = yes }     reference = slavic_house_guard }
	illustration = { trigger = { is_westslavic_maa = yes }    reference = westslavic_house_guard }
	illustration = { trigger = { is_westslavic_late_maa = yes }  reference = westslavic_late_house_guard }	
	illustration = { trigger = { is_baltic_maa    = yes }     reference = baltic_house_guard }
	illustration = { trigger = { is_baltic_late_maa = yes }    reference = baltic_late_house_guard }	
	illustration = { trigger = { is_tungusic_maa    = yes }    reference = tungusic_house_guard }	
	illustration = { trigger = { is_danish_late_maa    = yes } reference = danish_late_house_guard }	
	illustration = { trigger = { is_north_late_maa     = yes } reference = north_late_house_guard }			
	illustration = { trigger = { is_north_maa     = yes }     reference = north_house_guard }
	illustration = { trigger = { is_holy_roman_maa    = yes } reference = holy_roman_house_guard }
	illustration = { trigger = { is_holy_roman_late_maa = yes } reference = holy_roman_late_house_guard }	
	illustration = { trigger = { is_frankish_maa    = yes }   reference = frankish_house_guard }		
	illustration = { trigger = { is_arabian_maa   = yes }     reference = arabian_house_guard }
	illustration = { trigger = { is_berber_maa    = yes }     reference = berber_house_guard }
	illustration = { trigger = { is_african_maa   = yes }     reference = african_house_guard }
	illustration = { trigger = { is_central_african_maa  = yes } reference = african_house_guard }
	illustration = { trigger = { is_west_african_maa  = yes } reference = african_house_guard }			
	illustration = { trigger = { is_east_african_maa  = yes } reference = east_african_house_guard }		
	illustration = { trigger = { is_indonesian_maa  = yes }   reference = indonesian_house_guard } 
	illustration = { trigger = { is_south_asian_maa  = yes }  reference = south_asian_house_guard } 
	illustration = { trigger = { is_chinese_maa       = yes } reference = chinese_house_guard }	
	illustration = { trigger = { is_asian_maa       = yes }   reference = asian_house_guard }
	illustration = { trigger = { is_caucasian_maa  = yes }    reference = caucasian_house_guard }
	illustration = { trigger = { is_persian_maa   = yes }     reference = persian_house_guard }	
	illustration = { trigger = { is_indian_maa  = yes }       reference = indian_house_guard }
	illustration = { trigger = { is_israelite_maa  = yes }    reference = israelite_house_guard }
	illustration = { trigger = { is_cuman_maa  = yes }    	  reference = cuman_house_guard }
	illustration = { trigger = { is_oghuz_maa  = yes }    	  reference = oghuz_house_guard }	
	illustration = { trigger = { is_american_maa  = yes }     reference = american_house_guard }		
}
