tr_est_malice_adopt = {
	custom_tooltip = tr_est_malice_adopt_desc

	on_enabled = {	
		every_country = {
			limit = {
				has_opinion_modifier = { 
					modifier = opinion_insult
					who = root
				}
				Not = {
					has_modifier = mod_est_malice_adopt
				}
			}
			add_modifier = {
				modifier = "mod_est_malice_adopt"
				days = -1
			}
		}
	}
	
	tradition_swap = {
		name = tr_est_malice_adopt_alt
		trigger = {
			OR = {
				is_ai = yes
				has_valid_civic = civic_fanatic_purifiers
				has_valid_civic = civic_hive_devouring_swarm
				has_valid_civic = civic_machine_terminator
			}
		}	
		modifier = {
			country_naval_cap_mult = 0.15
		}
		weight = { factor = 1 }
	}	
}

tr_est_malice_finish = {
	modifier = {
		ship_weapon_damage = 0.10
		ascension_perks_add = 1
	}
}


tr_est_malice_1 = {
	custom_tooltip = tr_est_malice_1_desc

	modifier = {
		pop_category_slave_upkeep_mult = -0.50
	}

	tradition_swap = {
		custom_tooltip = tr_est_malice_1_no_slaves_desc
	
		name = tr_est_malice_1_no_slaves
		inherit_icon = yes
		trigger = {
			est_AI_no_passive_aggressive_traditons = no
			OR = {
				Not = { has_policy_flag = slavery_allowed }
				has_ethic = ethic_gestalt_consciousness
				has_civic = civic_fanatic_purifiers
			}
		}	
		weight = { factor = 1 }
	}	
	tradition_swap = {
		inherit_icon = yes
		name = tr_est_malice_1_no_slaves_passive_AI
		trigger = {
			est_AI_no_passive_aggressive_traditons = yes
			OR = {
				Not = { has_policy_flag = slavery_allowed }
				has_ethic = ethic_gestalt_consciousness
			}
		}	
		modifier = {
			army_damage_mult = 0.25			
		}
		weight = { factor = 1 }
	}	

	ai_weight = { factor = 5000 }
}

tr_est_malice_2 = {
	custom_tooltip = tr_est_malice_2_desc

	possible = { has_tradition = tr_est_malice_1 }

	on_enabled = {
		every_owned_pop = {
			limit = {
				is_enslaved = yes
				Not = {
					has_modifier = mod_est_malice_2
				}
			}
			add_modifier = {
				modifier = "mod_est_malice_2"
			}
		}
	}	

	modifier = {
		pop_cat_slave_political_power = -0.50
	}

	tradition_swap = {
		custom_tooltip = tr_est_malice_2_no_slaves_desc
	
		name = tr_est_malice_2_no_slaves
		trigger = {
			est_AI_no_passive_aggressive_traditons = no
			OR = {
				NOT = { has_policy_flag = slavery_allowed }
				has_ethic = ethic_gestalt_consciousness
				has_civic = civic_fanatic_purifiers
			}
		}	
		weight = { factor = 1 }
	}

	tradition_swap = {
		name = tr_est_malice_2_various_AI
		trigger = {
			Or = {
				And = {
					est_AI_no_passive_aggressive_traditons = yes
					Or = {
						Not = { has_policy_flag = slavery_allowed }
						has_ethic = ethic_gestalt_consciousness
					}
				}
				And = {
					is_ai = yes
					has_policy_flag = slavery_allowed
					Not = { has_ethic = ethic_gestalt_consciousness }
				}
			}
		}	
		modifier = {
			ship_weapon_damage = 0.05		
		}
		weight = { factor = 1 }
	}	

	ai_weight = { factor = 5000 }
}

tr_est_malice_3 = {
	modifier = {
		max_rivalries = 3
	}
	
	tradition_swap = {
		name = tr_est_malice_3_no_rivals
		trigger = { est_no_rivals = yes }	
		modifier = {
			army_damage_mult = 0.20
			army_collateral_damage_mult = 0.33
		}
		weight = { factor = 1 }
	}

	ai_weight = { factor = 5000 }
}

tr_est_malice_4 = {
	possible = {
		has_tradition = tr_est_malice_3
	}

	modifier = {
		rivalries_influence_produces_mult = 0.3
	}
	
	tradition_swap = {
		name = tr_est_malice_4_no_rivals
		inherit_icon = yes
		inherit_name = yes
		trigger = { est_no_rivals = yes }	
		modifier = {
			ship_fire_rate_mult = 0.05
		}
		weight = { factor = 1 }
	}

	ai_weight = { factor = 5000 }
}

tr_est_malice_5 = {
	custom_tooltip = tr_est_malice_5_desc

	possible = {
		has_tradition = tr_est_malice_2
		has_tradition = tr_est_malice_4
	}

	ai_weight = { factor = 5000 }
}