############################################################################################################
#	Expert AI mod - division production
############################################################################################################

EAI_PROD_ARMY_default_army_production_strategy = {
	enable = { always = yes }
	abort_when_not_enabled = yes

	ai_strategy = { type = role_ratio                          id = area_defense                 value = 0 }
	ai_strategy = { type = role_ratio                          id = suppression                  value = 0 }

	ai_strategy = { type = role_ratio                          id = infantry                     value = 100 }
	ai_strategy = { type = role_ratio                          id = mass_infantry                value = 0 }
	# ai_strategy = { type = role_ratio                          id = anti_tank                    value = 0 }
	ai_strategy = { type = role_ratio                          id = marine                       value = 0 }
	ai_strategy = { type = role_ratio                          id = mountaineer                  value = 0 }

	ai_strategy = { type = role_ratio                          id = armor                        value = 0 }

	ai_strategy = { type = role_ratio                          id = motorized                    value = 0 }
}

########################################################
#	MOBILE WARFARE
########################################################

EAI_PROD_ARMY_MW_armor_army_production_strategy = {
	enable = { has_country_flag = EAI_MW_armor_army_production_strategy }
	abort_when_not_enabled = yes

	ai_strategy = { type = role_ratio                          id = armor                        value = 35 }
}

EAI_PROD_ARMY_MW_motorized_army_production_strategy = {
	enable = { has_country_flag = EAI_MW_motorized_army_production_strategy }
	abort_when_not_enabled = yes

	ai_strategy = { type = role_ratio                          id = infantry                     value = -15 }
	ai_strategy = { type = role_ratio                          id = motorized                    value = 15 }
}

########################################################
#	SUPERIOR FIREPOWER
########################################################

EAI_PROD_ARMY_SF_armor_army_production_strategy = {
	enable = { has_country_flag = EAI_SF_armor_army_production_strategy }
	abort_when_not_enabled = yes

	ai_strategy = { type = role_ratio                          id = armor                        value = 35 }
}

EAI_PROD_ARMY_SF_motorized_army_production_strategy = {
	enable = { has_country_flag = EAI_SF_motorized_army_production_strategy }
	abort_when_not_enabled = yes

	ai_strategy = { type = role_ratio                          id = infantry                     value = -15 }
	ai_strategy = { type = role_ratio                          id = motorized                    value = 15 }
}

########################################################
#	GRAND BATTLEPLAN
########################################################

EAI_PROD_ARMY_GB_armor_army_production_strategy = {
	enable = { has_country_flag = EAI_GB_armor_army_production_strategy }
	abort_when_not_enabled = yes

	ai_strategy = { type = role_ratio                          id = armor                        value = 35 }
}

EAI_PROD_ARMY_GB_motorized_army_production_strategy = {
	enable = { has_country_flag = EAI_GB_motorized_army_production_strategy }
	abort_when_not_enabled = yes

	ai_strategy = { type = role_ratio                          id = infantry                     value = -15 }
	ai_strategy = { type = role_ratio                          id = motorized                    value = 15 }
}

########################################################
#	MASS ASSAULT
########################################################

EAI_PROD_ARMY_MA_armor_army_production_strategy = {
	enable = { has_country_flag = EAI_MA_armor_army_production_strategy }
	abort_when_not_enabled = yes

	ai_strategy = { type = role_ratio                          id = armor                        value = 20 }
}

EAI_PROD_ARMY_MA_motorized_army_production_strategy = {
	enable = { has_country_flag = EAI_MA_motorized_army_production_strategy }
	abort_when_not_enabled = yes

	ai_strategy = { type = role_ratio                          id = infantry                     value = -15 }
	ai_strategy = { type = role_ratio                          id = motorized                    value = 15 }
}

########################################################
#	Mass infantry
########################################################

EAI_PROD_ARMY_mass_infantry_strategy = {
	enable = { has_country_flag = EAI_MASS_INFANTRY_TEMPLATE }
	abort_when_not_enabled = yes

	ai_strategy = { type = role_ratio id = mass_infantry value = 100 }
	ai_strategy = { type = role_ratio id = infantry value = -100 }
}

########################################################
#	Armor
########################################################

# EAI_PROD_ARMY_force_build_armor_majors = {
# 	enable = {
# 		is_major = yes
# 		EAI_armor_equipment_production = yes
# 		has_army_size = { type = armor size < 30 }
# 	}
# 	abort_when_not_enabled = yes

# 	ai_strategy = { type = build_army id = armor value = 30 }
# }

# EAI_PROD_ARMY_force_build_armor_difficulty_bonus = {
# 	enable = {
# 		has_variable = EAI_difficulty_bonus
# 		EAI_armor_equipment_production = yes
# 		has_army_size = { type = armor size < 50 }
# 	}
# 	abort_when_not_enabled = yes

# 	ai_strategy = { type = build_army id = armor value = 50 }
# }

########################################################
#	ATTACHMENTS
########################################################

EAI_PROD_ARMY_motorized_attachment_army_production_strategy = {
	enable = { has_country_flag = EAI_motorized_attachment_army_production_strategy }
	abort_when_not_enabled = yes

	ai_strategy = { type = role_ratio                          id = infantry                     value = -6 }
	ai_strategy = { type = role_ratio                          id = motorized                    value = 6 }
}

EAI_PROD_ARMY_medium_armor_attachment_army_production_strategy = {
	enable = { has_country_flag = EAI_medium_armor_attachment_army_production_strategy }
	abort_when_not_enabled = yes

	ai_strategy = { type = role_ratio                          id = infantry                     value = -6 }
	ai_strategy = { type = role_ratio                          id = armor                        value = 6 }
}

########################################################
#	SPEC OPS
########################################################

EAI_PROD_ARMY_marine_spec_ops_army_production_strategy = {
	enable = {
		OR = {
			has_country_flag = EAI_TEMPLATE_marine_template_upgrade
			has_country_flag = EAI_TEMPLATE_amphibious_template_upgrade
		}
		check_variable = { EAI_FOCUS/LAND/spec_ops = global.EAI_MAR_SPEC_OPS }
		NOT = { has_country_flag = EAI_default_army_production_strategy_reset_2 }
	}
	
	abort_when_not_enabled = yes

	ai_strategy = { type = build_army                          id = marine                       value = 500 }
}

EAI_PROD_ARMY_mountaineer_spec_ops_army_production_strategy = {
	enable = {
		has_country_flag = EAI_TEMPLATE_mountaineer_template_upgrade
		check_variable = { EAI_FOCUS/LAND/spec_ops = global.EAI_MNT_SPEC_OPS }
		NOT = { has_country_flag = EAI_default_army_production_strategy_reset_2 }
	}
	
	abort_when_not_enabled = yes

	ai_strategy = { type = build_army                          id = mountaineer                  value = 100 }
}

##################################################
#	Garrison
##################################################

EAI_PROD_ARMY_garrison_2 = { enable = { has_country_flag = { flag = EAI_garrison_divisions value = 2 } } abort_when_not_enabled = yes ai_strategy = { type = build_army id = area_defense value = 2 } }
EAI_PROD_ARMY_garrison_4 = { enable = { has_country_flag = { flag = EAI_garrison_divisions value = 4 } } abort_when_not_enabled = yes ai_strategy = { type = build_army id = area_defense value = 4 } }
EAI_PROD_ARMY_garrison_6 = { enable = { has_country_flag = { flag = EAI_garrison_divisions value = 6 } } abort_when_not_enabled = yes ai_strategy = { type = build_army id = area_defense value = 6 } }
EAI_PROD_ARMY_garrison_8 = { enable = { has_country_flag = { flag = EAI_garrison_divisions value = 8 } } abort_when_not_enabled = yes ai_strategy = { type = build_army id = area_defense value = 8 } }
EAI_PROD_ARMY_garrison_10 = { enable = { has_country_flag = { flag = EAI_garrison_divisions value = 10 } } abort_when_not_enabled = yes ai_strategy = { type = build_army id = area_defense value = 10 } }
EAI_PROD_ARMY_garrison_12 = { enable = { has_country_flag = { flag = EAI_garrison_divisions value = 12 } } abort_when_not_enabled = yes ai_strategy = { type = build_army id = area_defense value = 12 } }
EAI_PROD_ARMY_garrison_14 = { enable = { has_country_flag = { flag = EAI_garrison_divisions value = 14 } } abort_when_not_enabled = yes ai_strategy = { type = build_army id = area_defense value = 14 } }
EAI_PROD_ARMY_garrison_16 = { enable = { has_country_flag = { flag = EAI_garrison_divisions value = 16 } } abort_when_not_enabled = yes ai_strategy = { type = build_army id = area_defense value = 16 } }
EAI_PROD_ARMY_garrison_18 = { enable = { has_country_flag = { flag = EAI_garrison_divisions value = 18 } } abort_when_not_enabled = yes ai_strategy = { type = build_army id = area_defense value = 18 } }
EAI_PROD_ARMY_garrison_20 = { enable = { has_country_flag = { flag = EAI_garrison_divisions value = 20 } } abort_when_not_enabled = yes ai_strategy = { type = build_army id = area_defense value = 20 } }
EAI_PROD_ARMY_garrison_25 = { enable = { has_country_flag = { flag = EAI_garrison_divisions value = 25 } } abort_when_not_enabled = yes ai_strategy = { type = build_army id = area_defense value = 25 } }
EAI_PROD_ARMY_garrison_30 = { enable = { has_country_flag = { flag = EAI_garrison_divisions value = 30 } } abort_when_not_enabled = yes ai_strategy = { type = build_army id = area_defense value = 30 } }
EAI_PROD_ARMY_garrison_35 = { enable = { has_country_flag = { flag = EAI_garrison_divisions value = 35 } } abort_when_not_enabled = yes ai_strategy = { type = build_army id = area_defense value = 35 } }
EAI_PROD_ARMY_garrison_40 = { enable = { has_country_flag = { flag = EAI_garrison_divisions value = 40 } } abort_when_not_enabled = yes ai_strategy = { type = build_army id = area_defense value = 40 } }
EAI_PROD_ARMY_garrison_45 = { enable = { has_country_flag = { flag = EAI_garrison_divisions value = 45 } } abort_when_not_enabled = yes ai_strategy = { type = build_army id = area_defense value = 45 } }
EAI_PROD_ARMY_garrison_50 = { enable = { has_country_flag = { flag = EAI_garrison_divisions value = 50 } } abort_when_not_enabled = yes ai_strategy = { type = build_army id = area_defense value = 50 } }
EAI_PROD_ARMY_garrison_60 = { enable = { has_country_flag = { flag = EAI_garrison_divisions value = 60 } } abort_when_not_enabled = yes ai_strategy = { type = build_army id = area_defense value = 60 } }
EAI_PROD_ARMY_garrison_70 = { enable = { has_country_flag = { flag = EAI_garrison_divisions value = 70 } } abort_when_not_enabled = yes ai_strategy = { type = build_army id = area_defense value = 70 } }
EAI_PROD_ARMY_garrison_80 = { enable = { has_country_flag = { flag = EAI_garrison_divisions value = 80 } } abort_when_not_enabled = yes ai_strategy = { type = build_army id = area_defense value = 80 } }
EAI_PROD_ARMY_garrison_90 = { enable = { has_country_flag = { flag = EAI_garrison_divisions value = 90 } } abort_when_not_enabled = yes ai_strategy = { type = build_army id = area_defense value = 90 } }
EAI_PROD_ARMY_garrison_100 = { enable = { has_country_flag = { flag = EAI_garrison_divisions value = 100 } } abort_when_not_enabled = yes ai_strategy = { type = build_army id = area_defense value = 100 } }