# befriend
# conquer
# antagonize
# build_ship
# build_army
# unit_ratio
# build_building
# research_tech
# garrison
# protect
# influence

war_cooperation = {
	enable = {
		tag = STG
		has_war_together_with = EQS
		EQS = { has_war_with = CHN }
	}
	abort = {
		EQS = { exists = no }
	}

	ai_strategy = {
		type = alliance
		id = "EQS"
		value = 200
	}
	ai_strategy = {
		type = protect
		id = "EQS"
		value = 200
	}
}
changeling_threat = {
	enable = {
		tag = STG
		has_war_with = CHN
	}
	abort = {
	OR = {
		CHN = { exists = no }
		CHN = { is_subject_of = EQS }
		}
	}

	ai_strategy = {
		type = conquer
		id = "CHN"
		value = 200
	}
	ai_strategy = {
		type = antagonize
		id = "CHN"
		value = 200
	}
}
revolution_in_crystal_empire = {
	enable = {
		tag = STG
		CRY = {
			has_completed_focus = CRY_comrevolution
		}
	}
	abort = {
	OR = {
		CHN = { exists = no }
		CHN = { is_subject_of = EQS }
		}
	}
	ai_strategy = {
		type = support
		id = "CRY"
		value = 200
	}
	ai_strategy = {
		type = conquer
		id = "CHN"
		value = 200
	}
	ai_strategy = {
		type = antagonize
		id = "CHN"
		value = 200
	}
}
STG_unit_production = {
	enable = {
		original_tag = STG
	}
	abort = {
		always = no
	}

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


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

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

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

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

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

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

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

	ai_strategy = {
		type = role_ratio
		id = pegasi
		value = 5
	}

	ai_strategy = {
		type = role_ratio
		id = infantry
		value = 20 #because doctrine 70
	}

	ai_strategy = {
		type = role_ratio
		id = magical_infantry
		value = 5
	}

	#Air unit factors
	ai_strategy = {
		type = unit_ratio
		id = fighter
		value = 70
	}

	ai_strategy = {
		type = unit_ratio
		id = cas
		value = -35 #because doctrine this = 15
	}

	ai_strategy = {
		type = unit_ratio
		id = tactical_bomber
		value = 5
	}

	ai_strategy = {
		type = unit_ratio
		id = strategic_bomber
		value = 5
	}

	ai_strategy = {
		type = unit_ratio
		id = naval_bomber
		value = 5
	}


	# Naval unit factors
	ai_strategy = {
		type = unit_ratio
		id = capital_ship
		value = -35
	}

	ai_strategy = {
		type = unit_ratio
		id = submarine
		value = -150 #because doctrine this = 50
	}

	ai_strategy = {
		type = unit_ratio
		id = screen_ship
		value = -20
	}

	ai_strategy = {
		type = unit_ratio
		id = convoy
		value = 20
	}

	ai_strategy = {
		type = equipment_production_factor
		id = fighter
		value = 20
	}

	ai_strategy = {
		type = equipment_production_factor
		id = infantry
		value = 30
	}

	ai_strategy = {
		type = equipment_production_factor
		id = artillery
		value = 30
	}

	ai_strategy = {
		type = equipment_production_factor
		id = armor
		value = 10
	}
}

STG_template_design_1 = {
	enable = {
		original_tag = STG
		date < 1011.1.1
	}
	abort = {
		date > 1011.1.1
	}

	ai_strategy = {
		type = template_prio
		id = motorized
		value = 10
	}

	ai_strategy = {
		type = template_prio
		id = cavalry
		value = -100
	}

	ai_strategy = {
		type = template_prio
		id = light_armor
		value = 50
	}

	ai_strategy = {
		type = template_prio
		id = medium_armor
		value = -10
	}

	ai_strategy = {
		type = template_prio
		id = heavy_armor
		value = -50
	}

	ai_strategy = {
		type = template_prio
		id = paratroopers
		value = -50
	}

	ai_strategy = {
		type = template_prio
		id = infantry
		value = 50
	}
}

STG_template_design_2 = {
	enable = {
		original_tag = STG
		date > 1011.1.1
	}

	ai_strategy = {
		type = template_prio
		id = mechanized
		value = 20
	}

	ai_strategy = {
		type = template_prio
		id = cavalry
		value = -100
	}

	ai_strategy = {
		type = template_prio
		id = light_armor
		value = 10
	}

	ai_strategy = {
		type = template_prio
		id = medium_armor
		value = 50
	}

	ai_strategy = {
		type = template_prio
		id = modern_armor
		value = 60
	}

	ai_strategy = {
		type = template_prio
		id = heavy_armor
		value = 20
	}

	ai_strategy = {
		type = template_prio
		id = paratroopers
		value = -50
	}

	ai_strategy = {
		type = template_prio
		id = infantry
		value = 10
	}
}
