﻿# standard costs
@maa_buy_cost = 150
@maa_low_maintenance_cost = 1.0
@maa_high_maintenance_cost = 5.0
@cultural_maa_extra_ai_score = 80 # Equivalent to having 8 extra regiments beyond what the code scoring would indicate (see NEGATIVE_SCORE_PER_EXISTING_REGIMENT)

# 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

ayrudzi = {
	type = light_cavalry

	damage = 50
	toughness = 30
	pursuit = 20
	screen = 30

	terrain_bonus = {
		hills = { damage = 30 toughness = 20 }
		mountains = { damage = 20 toughness = 10 }
		drylands = { damage = 10 }
		plains = { damage = 10 }
		wetlands = { damage = -30 toughness = -20 pursuit = -20 screen = -25 }
		jungle = { damage = -30 toughness = -20 pursuit = -20 screen = -25 }
	}

	counters = {
		archers = 1
		archer_cavalry = 0.5
	}

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

	can_recruit = {
		valid_for_maa_trigger = { PARAMETER = unlock_maa_ayrudzi }
	}

	buy_cost = { gold = ayrudzi_recruitment_cost }
	low_maintenance_cost = { gold = ayrudzi_low_maint_cost }
	high_maintenance_cost = { gold = ayrudzi_high_maint_cost }
	provision_cost = @provisions_cost_cavalry_cheap

	stack = 50
	ai_quality = {
		value = @cultural_maa_extra_ai_score
		add = counter_synergy_ai_weight_light_cavalry
	}
	icon = ayrudzi
}

conrois = {
	type = heavy_cavalry

	damage = 100
	toughness = 25
	pursuit = 10
	screen = 0

	terrain_bonus = {
		plains = { damage = 30 }
		drylands = { damage = 30 }
		farmlands = { damage = 30 }
		hills = { damage = -20 }
		mountains = { damage = -75 }
		desert_mountains = { damage = -75 }
		wetlands = { damage = -75 toughness = -10 pursuit = -10 }
		jungle = { damage = -75 toughness = -10 pursuit = -10 }
	}

	counters = {
		archers = 1
		light_cavalry = 1
	}

	can_recruit = {
		valid_for_maa_trigger = { PARAMETER = unlock_maa_conrois }
		NOT = {
			culture = { has_cultural_parameter = strength_in_numbers_heavy_maa_ban }
		}
	}

	winter_bonus = {
		normal_winter = { damage = -15 toughness = -5 }
		harsh_winter = { damage = -25 toughness = -10 }
	}

	buy_cost = { gold = conrois_recruitment_cost }
	low_maintenance_cost = { gold = conrois_low_maint_cost }
	high_maintenance_cost = { gold = conrois_high_maint_cost }
	provision_cost = @provisions_cost_cavalry_cheap

	stack = 50
	ai_quality = { value = @[cultural_maa_extra_ai_score + 35 ] }
	icon = conrois
}

akritai = {
	type = skirmishers

	damage = 10
	toughness = 14
	pursuit = 12
	screen = 18

	terrain_bonus = {
		mountains = { damage = 10 toughness = 10 }
		desert_mountains = { damage = 6 toughness = 6 }
		hills = { damage = 6 toughness = 6 }
		forest = { toughness = 4 }
		wetlands = { toughness = 4 }
	}

	counters = {
		heavy_infantry = 1
	}

	can_recruit = {
		valid_for_maa_trigger = { PARAMETER = unlock_maa_akritai }
	}

	buy_cost = { gold = akritai_recruitment_cost }
	low_maintenance_cost = { gold = akritai_low_maint_cost }
	high_maintenance_cost = { gold = akritai_high_maint_cost }
	provision_cost = @provisions_cost_infantry_cheap

	stack = 100
	ai_quality = { value = @[cultural_maa_extra_ai_score - 90] }
	icon = akritai
}

ballistrai = {
	type = archers

	damage = 35
	toughness = 12
	pursuit = 0
	screen = 0

	siege_value = 0.1

	terrain_bonus = {
		farmlands = { damage = 8 toughness = 6 }
		plains = { damage = 8 }
		hills = { damage = 8 }
	}

	counters = {
		pikemen = 0.5
		peasant_militia = 1
		heavy_infantry = 0.5
	}

	can_recruit = {
		valid_for_maa_trigger = { PARAMETER = unlock_maa_ballistrai }
	}

	buy_cost = { gold = ballistrai_recruitment_cost }
	low_maintenance_cost = { gold = ballistrai_low_maint_cost }
	high_maintenance_cost = { gold = ballistrai_high_maint_cost }
	provision_cost = @provisions_cost_special_moderate

	stack = 50
	ai_quality = { value = @[cultural_maa_extra_ai_score + 200] }
	icon = ballistrai
}

skoutatoi = {
	type = pikemen

	damage = 22
	toughness = 26
	pursuit = 0
	screen = 20

	terrain_bonus = {
		mountains = { toughness = 8 }
		desert_mountains = { toughness = 8 }
		hills = { toughness = 8 }
		plains = { damage = 8 }
	}

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

	can_recruit = {
		valid_for_maa_trigger = { PARAMETER = unlock_maa_skoutatoi }
	}

	buy_cost = { gold = skoutatoi_recruitment_cost }
	low_maintenance_cost = { gold = skoutatoi_low_maint_cost }
	high_maintenance_cost = { gold = skoutatoi_high_maint_cost }
	provision_cost = @provisions_cost_infantry_moderate

	stack = 100
	ai_quality = {
		value = @[cultural_maa_extra_ai_score + 20]
		add = counter_synergy_ai_weight_pikemen
	}
	icon = skoutatoi
}

varangian_guards = {
	type = heavy_infantry

	damage = 45
	toughness = 32
	pursuit = 10
	screen = 5

	can_recruit = {
		exists = scope:title
		scope:title = {
			has_variable = founded_varangian_guard
		}
		NOT = {
			culture = { has_cultural_parameter = strength_in_numbers_heavy_maa_ban }
		}
	}

	terrain_bonus = {
		farmlands = { damage = 12 toughness = 8 }
		plains = { damage = 6 toughness = 4 }
		hills = { damage = 6 toughness = 4 }
	}
	
	counters = {
		pikemen = 1
		peasant_militia = 2
		heavy_cavalry = 1
	}

	winter_bonus = {
		normal_winter = { toughness = 6 screen = 6 }
		harsh_winter = { toughness = 6 screen = 6 }
	}

	buy_cost = { gold = varangian_guards_recruitment_cost }
	low_maintenance_cost = { gold = varangian_guards_low_maint_cost }
	high_maintenance_cost = { gold = varangian_guards_high_maint_cost }
	provision_cost = @provisions_cost_infantry_moderate

	stack = 100
	ai_quality = {
		value = @[cultural_maa_extra_ai_score + 40]
		add = counter_synergy_ai_weight_heavy_infantry
	}
	icon = varangian_guard
}

handpicked_faithful = {
	type = heavy_infantry

	damage = 38
	toughness = 28
	pursuit = 5
	screen = 5

	can_recruit = {
		domicile ?= { has_domicile_parameter = camp_unlocks_handpicked_faithful_maa_type }
		NOT = {
			culture = { has_cultural_parameter = strength_in_numbers_heavy_maa_ban }
		}
	}

	terrain_bonus = {
		hills = { damage = 6 toughness = 4 }
		forest = { damage = 6 toughness = 4 }
		jungle = { damage = 6 toughness = 4 }
	}

	counters = {
		pikemen = 1
		peasant_militia = 2
		heavy_cavalry = 1
	}

	buy_cost = { gold = handpicked_faithful_recruitment_cost }
	low_maintenance_cost = { gold = handpicked_faithful_low_maint_cost }
	high_maintenance_cost = { gold = handpicked_faithful_high_maint_cost }
	provision_cost = @provisions_cost_infantry_moderate

	stack = 100
	ai_quality = {
		value = @[cultural_maa_extra_ai_score + 50]
		add = counter_synergy_ai_weight_heavy_infantry
	}
	icon = heavy_infantry
}

maa_bandits = {
	type = skirmishers

	special_recruit_only = yes

	damage = 15
	toughness = 20
	pursuit = 20
	screen = 25

	terrain_bonus = {
		forest = { damage = 4 toughness = 6 }
		hills = { damage = 4 toughness = 6 }
		jungle = { damage = 4 toughness = 6 }
	}
	
	counters = {
		heavy_infantry = 1
		archers = 1
	}

	buy_cost = { gold = jomsviking_pirates_recruitment_cost }
	low_maintenance_cost = { gold = jomsviking_pirates_low_maint_cost }
	high_maintenance_cost = { gold = jomsviking_pirates_high_maint_cost }
	provision_cost = @provisions_cost_infantry_cheap
	
	stack = 50
	ai_quality = { value = @cultural_maa_extra_ai_score }
	icon = skirmishers
}

maa_poachers = {
	type = archers

	special_recruit_only = yes

	damage = 30
	toughness = 15
	pursuit = 10
	screen = 10
	
	terrain_bonus = {
		hills = { damage = 10 toughness = 6 }
		forest = { toughness = 10 screen = 10 }
		jungle = { toughness = 10 screen = 10 }
	}

	counters = {
		skirmishers = 1
	}

	buy_cost = { gold = jomsviking_pirates_recruitment_cost }
	low_maintenance_cost = { gold = jomsviking_pirates_low_maint_cost }
	high_maintenance_cost = { gold = jomsviking_pirates_high_maint_cost }
	provision_cost = @provisions_cost_infantry_cheap
	
	stack = 50
	ai_quality = { value = @cultural_maa_extra_ai_score }
	icon = bowmen
}

maa_marauders = {
	type = light_cavalry

	special_recruit_only = yes

	damage = 30
	toughness = 15
	pursuit = 40
	screen = 30
	
	terrain_bonus = {
		plains = { damage = 15 }
		drylands = { damage = 15 }
		farmlands = { damage = 25 }
	}
	
	counters = {
		archers = 1
	}

	buy_cost = { gold = jomsviking_pirates_recruitment_cost }
	low_maintenance_cost = { gold = jomsviking_pirates_low_maint_cost }
	high_maintenance_cost = { gold = jomsviking_pirates_high_maint_cost }
	provision_cost = @provisions_cost_infantry_moderate
	
	stack = 50
	ai_quality = { value = @cultural_maa_extra_ai_score }
	icon = light_cavalry
}

maa_thieves = {
	type = pikemen

	special_recruit_only = yes

	damage = 30
	toughness = 20
	pursuit = 10
	screen = 10
	
	terrain_bonus = {
		mountains = { toughness = 15 }
		desert_mountains = { toughness = 15 }
		hills = { toughness = 10 }
	}

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

	buy_cost = { gold = jomsviking_pirates_recruitment_cost }
	low_maintenance_cost = { gold = jomsviking_pirates_low_maint_cost }
	high_maintenance_cost = { gold = jomsviking_pirates_high_maint_cost }
	provision_cost = @provisions_cost_infantry_cheap
	
	stack = 50
	ai_quality = { value = @cultural_maa_extra_ai_score }
	icon = pikemen
}
