########################################
# Flavor Events for Aztecs
#
# written by Henrik Lohmander
########################################

namespace = flavor_azt
normal_or_historical_nations = yes

# The Great Pyramid of Tenochtitlan
country_event = {
	id = flavor_azt.1
	title = flavor_azt.1.t
	desc = flavor_azt.1.d
	picture = GREAT_BUILDING_eventPicture
	goto = 852
	fire_only_once = yes
	
	trigger = {
		tag = AZT
		owns = 852 #Mexico
		num_of_cities = 3
		NOT = { is_year = 1450 }
	}
	
	mean_time_to_happen = {
		months = 12
	}
	
	option = {
		name = flavor_azt.1.a #All our subjects must contribute to the Pyramid!
		set_ruler_flag = temple_expansion
		custom_tooltip = flavor_azt.1.a.tt #Our provinces will pay for part of the cost of the Pyramid.
		hidden_effect = {
			every_owned_province = {
				limit = { not = { is_capital = yes } }
				random_list = {
					80 = {
						add_province_modifier = {
							name = azt_contribution_to_great_temple
							duration = -1
						}
					}
					20 = {
						spawn_rebels = {
							type = noble_rebels
							size = 1
							win = yes
						}
					}
				}
			}
			country_event = { id = flavor_azt.2 days = 120 }
		}
	}
	option = {
		name = flavor_azt.1.b #Let us use our own resources for this project.
		add_adm_power = -75
		add_dip_power = -75
		set_ruler_flag = temple_expansion
		if = {
			limit = {
				has_dlc = "Leviathan"
			}
			852 = {
				add_great_project_tier = {
					type = tenochtitlan
					tier = 1
				}
			}
		}
		else = {
			852 = {
				add_province_modifier = {
					name = azt_templo_mayor
					duration = -1
				}
			}
		}
	}
}

#Reaction to Pyramid Project
country_event = {
	id = flavor_azt.2
	title = flavor_azt.2.t
	desc = flavor_azt.2.d
	picture = GREAT_BUILDING_eventPicture
	
	fire_only_once = yes
	is_triggered_only = yes
	
	option = {
		name = flavor_azt.2.a #Ok.
		trigger = {
			num_of_owned_provinces_with = {
				value = 2
				has_province_modifier = azt_contribution_to_great_temple
			}
		}
		custom_tooltip = flavor_azt.2.a.tt #The great contributions we have received have resulted in an impressive addition to the Pyramid.
		every_owned_province = {
			limit = { has_province_modifier = azt_contribution_to_great_temple }
			remove_province_modifier = azt_contribution_to_great_temple
		}
		add_adm_power = -25
		add_dip_power = -25
		add_prestige = 10
		add_legitimacy = 5
		852 = {
			add_province_modifier = {
				name = azt_templo_mayor
				duration = -1
			}
			set_great_project_tier_3 = {
				type = tenochtitlan
			}
		}
	}
	option = {
		name = flavor_azt.2.b #Ok.
		trigger = {
			NOT = {
				num_of_owned_provinces_with = {
					value = 2
					has_province_modifier = azt_contribution_to_great_temple
				}
			}
			any_owned_province = {
				has_province_modifier = azt_contribution_to_great_temple
			}
		}
		custom_tooltip = flavor_azt.2.b.tt #The contributions from our provinces has paid for part of the new Pyramid.
		every_owned_province = {
			limit = { has_province_modifier = azt_contribution_to_great_temple }
			remove_province_modifier = azt_contribution_to_great_temple
		}
		add_adm_power = -35
		add_dip_power = -35
		add_prestige = 5
		add_legitimacy = 5
		852 = {
			add_province_modifier = {
				name = azt_templo_mayor
				duration = -1
			}
			set_great_project_tier_3 = {
				type = tenochtitlan
			}
		}
	}
	option = {
		name = flavor_azt.2.c #Ok.
		trigger = {
			NOT = {
				any_owned_province = {
					has_province_modifier = azt_contribution_to_great_temple
				}
			}
		}
		custom_tooltip = flavor_azt.2.c.tt #The Pyramid is effectively paid for by only the central government and other city states in its immediate surroundings.
		add_adm_power = -75
		add_dip_power = -75
		852 = {
			add_province_modifier = {
				name = azt_templo_mayor
				duration = -1
			}
			set_great_project_tier_3 = {
				type = tenochtitlan
			}
		}
	}
}

# Tlacaelel
country_event = {
	id = flavor_azt.3
	title = flavor_azt.3.t
	desc = flavor_azt.3.d
	picture = ADVISOR_eventPicture
	
	fire_only_once = yes
	
	trigger = {
		tag = AZT
		is_at_war = no
		NOT = { is_year = 1487 }
	}
	
	mean_time_to_happen = {
		months = 90
	}
	
	option = {
		name = flavor_azt.3.a
		add_prestige = 10
		add_adm_power = 75
		add_mil_power = 75
	}
}

# Sumptuary Laws & Warrior Culture
country_event = {
	id = flavor_azt.4
	title = flavor_azt.4.t
	desc = flavor_azt.4.d
	picture = MILITARY_CAMP_eventPicture
	
	fire_only_once = yes
	
	trigger = {
		tag = AZT
		NOT = { is_year = 1460 }
	}
	
	mean_time_to_happen = {
		months = 48
	}
	
	option = {
		name = flavor_azt.4.a #Implement the Sumptuary Laws.
		add_adm_power = -100
		PA_random_army_exp_between_2_and_10_effect = yes    #PA: replaced flat gain with random dynamic gain. -- 200e200w
		add_country_modifier = {
			name = azt_sumptuary_laws
			duration = -1
		}
	}
	option = {
		name = flavor_azt.4.b #We do not need such laws, tradition will remain our guideline.
		add_stability_or_adm_power = yes
		add_legitimacy = 15
	}
}

# The Famine Year of the One Rabbit (1454)
country_event = {
	id = flavor_azt.5
	title = flavor_azt.5.t
	desc = flavor_azt.5.d
	picture = FAMINE_eventPicture
	
	fire_only_once = yes
	
	trigger = {
		tag = AZT
		is_year = 1450
		NOT = { is_year = 1460 }
	}
	
	mean_time_to_happen = {
		months = 30
	}
	
	option = {
		name = flavor_azt.5.a #Allow People to Resettle
		add_stability = -1
		capital_scope = {
			add_base_tax = -1
		}
		add_country_modifier = {
			name = azt_one_rabit
			duration = 365
		}
		set_country_flag = azt_had_year_of_famine
	}
	option = {
		name = flavor_azt.5.b #Hold them against their will
		add_stability = -1
		capital_scope = {
			add_unrest = 10
		}
		add_country_modifier = {
			name = azt_one_rabit
			duration = 365
		}
		set_country_flag = azt_had_year_of_famine
	}
}

# Begining of a new Cycle.
country_event = {
	id = flavor_azt.6
	title = flavor_azt.6.t
	desc = flavor_azt.6.d
	picture = COMET_SIGHTED_eventPicture
	
	fire_only_once = yes
	
	trigger = {
		tag = AZT
		has_country_flag = azt_had_year_of_famine
		NOT = { has_country_modifier = azt_one_rabit }
	}
	
	mean_time_to_happen = {
		months = 1
	}
	
	option = {
		name = flavor_azt.6.a #For thus it is ended; thus sickness and famine have left us (in the words of the Florentine Codex)
		add_stability_or_adm_power = yes
		if = {
			limit = {
				has_dlc = "El Dorado"
			}
			add_doom = -5
		}
		add_country_modifier = {
			name = azt_recovery
			duration = 365
		}
	}
}

# The Power Balance of the Triple Alliance
country_event = {
	id = flavor_azt.7
	title = flavor_azt.7.t
	desc = flavor_azt.7.d
	picture = REFORM_eventPicture
	
	fire_only_once = yes
	
	trigger = {
		tag = AZT
		num_of_cities = 10
		is_year = 1470
		NOT = { is_year = 1500 }
	}
	
	mean_time_to_happen = {
		months = 90
	}
	
	option = {
		name = flavor_azt.7.a #Continue to centralize power in Tenochtitlan.
		add_stability_or_adm_power = yes
		add_prestige = 5
	}
	option = {
		name = flavor_azt.7.b #Attempt to empower Texcoco to a greater degree.
		add_stability = -1
		add_country_modifier = {
			name = azt_texcoco_rising
			duration = -1
		}
	}
}

# Legal Reform of Nezahualcoyotl
country_event = {
	id = flavor_azt.8
	title = flavor_azt.8.t
	desc = flavor_azt.8.d
	picture = REFORM_eventPicture
	
	fire_only_once = yes
	
	trigger = {
		tag = AZT
		num_of_cities = 10
		is_year = 1470
		NOT = { is_year = 1500 }
	}
	
	mean_time_to_happen = {
		months = 90
	}
	
	option = {
		name = flavor_azt.8.a #Let us implement these laws immediately!
		add_adm_power = -100
		add_country_modifier = {
			name = nezahualcoyotls_laws
			duration = -1
		}
	}
	option = {
		name = flavor_azt.8.b #Why meddle with that which has worked for generations?
		add_stability_or_adm_power = yes
		add_legitimacy = 15
	}
}

# Altepetl Revolt (repeating)
# City states tended to avoid when the central power showed weakness
country_event = {
	id = flavor_azt.9
	title = flavor_azt.9.t
	desc = flavor_azt.9.d
	picture = ANGRY_MOB_eventPicture
	
	trigger = {
		tag = AZT
		num_of_cities = 8
		NOT = { adm_tech = 5 }
		OR = {
			NOT = { stability = 1 }
			war_exhaustion = 5
			NOT = { legitimacy = 50 }
		}
		any_owned_province = {
			can_spawn_rebels = nationalist_rebels
		}
	}
	
	mean_time_to_happen = {
		months = 120
	}
	
	#Choices loosely based upon Nezahualcoyotl's laws
	option = {
		name = flavor_azt.9.a #Attempt to conspire with the elders of the city to stop this 
		random_list = {
				50 = {
					country_event = { id = flavor_azt.10 days = 60 } 
				}
				50 = {
					country_event = { id = flavor_azt.11 days = 60 } 
				}
			}
	}
	option = {
		name = flavor_azt.9.b #Prepare a military expedition to depose the leader of the city.
		random_owned_province = {
			limit = {
				is_capital = no
				controlled_by = ROOT
				can_spawn_rebels = nationalist_rebels
			}
			spawn_rebels = {
				type = nationalist_rebels
				size = 1
				win = yes
			}
		}
	}
}

# Rebellion Averted
country_event = {
	id = flavor_azt.10
	title = flavor_azt.10.t
	desc = flavor_azt.10.d
	picture = MILITARY_CAMP_eventPicture
	
	is_triggered_only = yes
	
	option = {
		name = flavor_azt.10.a #
		add_prestige = 5
	}
}

# Rebellion Grows
country_event = {
	id = flavor_azt.11
	title = flavor_azt.11.t
	desc = flavor_azt.11.d
	picture = ANGRY_MOB_eventPicture
	
	is_triggered_only = yes
	
	option = {
		name = flavor_azt.11.a
		random_owned_province = {
			limit = {
				is_capital = no
				controlled_by = ROOT
			}
			spawn_rebels = {
				type = nationalist_rebels
				size = 1
			}
		}
		random_owned_province = {
			limit = {
				is_capital = no
				controlled_by = ROOT
				can_spawn_rebels = nationalist_rebels
			}
			spawn_rebels = {
				type = nationalist_rebels
				size = 1
				win = yes
			}
		}
	}
}

# Aztec Merchants Harassed.
country_event = {
	id = flavor_azt.12
	title = flavor_azt.12.t
	desc = flavor_azt.12.d
	picture = MERCHANTS_TALKING_eventPicture
	
	trigger = {
		tag = AZT
		is_neighbor_of = TOT
		NOT = { alliance_with = TOT }
		NOT = { is_subject_of = TOT }
		NOT = { TOT = { is_subject_of = AZT } }
		is_year = 1450
		NOT = { is_year = 1470 }
		NOT = {
			has_casus_belli = {
				type = cb_trade_war_triggered
				target = TOT
			}
		}
	}
	
	mean_time_to_happen = {
		months = 60
	}
	
	option = {
		name = flavor_azt.12.a #They will regret this.
		add_casus_belli = {
			target = TOT
			type = cb_trade_war_triggered
			months = 60
		}
	}
}

# European Diseases
country_event = {
	id = flavor_azt.13
	title = flavor_azt.13.t
	desc = flavor_azt.13.d
	picture = PLAGUE_eventPicture
	
	trigger = {
		NOT = { has_country_flag = european_diseases_struck }
		capital_scope = {
			continent = north_america
		}
		NOT = { has_institution = feudalism }
		any_known_country = {
			OR = {
				capital_scope = {
					continent = europe
				}
				colonial_parent = {
					capital_scope = {
						continent = europe
					}
				}
			}
			OR = {
				any_owned_province = {
					continent = north_america
				}
				war_with = ROOT
			}
		}
	}
	
	immediate = {
		hidden_effect = {
			random_owned_province = {
				limit = {
					OR = {
						is_capital = no
						owner = { NOT = { num_of_cities = 2 } }
					}
				}
				set_province_flag = NA_smallpox_here
				every_neighbor_province = {
					limit = {
						owned_by = ROOT
					}
					set_province_flag = NA_smallpox_here
				}
			}
			set_country_flag = european_diseases_struck
		}
	}
	
	mean_time_to_happen = {
		months = 120
		
		modifier = {
			factor = 0.1
			any_known_country = {
				capital_scope = {
					continent = europe
				}
				war_with = ROOT
			}
		}
	}
	
	option = {
		name = flavor_azt.13.a #Have the gods forsaken us?
		every_province = {
			limit = { has_province_flag = NA_smallpox_here }
			add_province_modifier = {
				name = inc_smallpox_outbreak
				duration = 360
			}
			set_province_flag = had_smallpox_at_one_point
			clr_province_flag = NA_smallpox_here
		}
	}
}

# Cocoliztli
country_event = {
	id = flavor_azt.14
	title = flavor_azt.14.t
	desc = flavor_azt.14.d
	picture = PLAGUE_eventPicture
	
	fire_only_once = yes
	
	trigger = {
		culture_group = central_american
		has_country_flag = european_diseases_struck
		is_year = 1545
		NOT = { is_year = 1576 }
		NOT = {
			any_owned_province = {
				has_province_modifier = inc_smallpox_outbreak
			}
		}
	}
	
	mean_time_to_happen = {
		months = 93
	}
	
	option = {
		name = flavor_azt.14.a #
		add_stability = -2
		add_country_modifier = {
			name = azt_cocoliztli
			duration = 730
		}
	}
}

#Smallpox Epidemic
country_event = {
	id = flavor_azt.15
	title = flavor_azt.15.t
	desc = flavor_azt.15.d
	picture = PLAGUE_eventPicture
	
	trigger = {
		capital_scope = { continent = north_america }
		has_country_flag = european_diseases_struck
		NOT = {
			had_country_flag = { flag = european_diseases_struck days = 5475 }
		}
		NOT = { 
			any_owned_province = {
				has_province_modifier = inc_smallpox_outbreak
			}
		}
	}
	
	immediate = {
		hidden_effect = {
			random_owned_province = {
				limit = { is_capital = no }
				set_province_flag = NA_smallpox_here
				every_neighbor_province = { set_province_flag = NA_smallpox_here }
			}
		}
	}
	
	mean_time_to_happen = {
		months = 60
	}
	
	option = { #Horrible
		name = flavor_azt.15.a
		every_province = {
			limit = { has_province_flag = NA_smallpox_here }
			add_province_modifier = {
				name = inc_smallpox_outbreak
				duration = 365
			}
			set_province_flag = had_smallpox_at_one_point
			clr_province_flag = NA_smallpox_here
		}
	}
}

#Disloyal Altepetls - Invading Europeans
country_event = {
	id = flavor_azt.16
	title = flavor_azt.16.t
	desc = flavor_azt.16.d
	picture = ANGRY_MOB_eventPicture
	
	fire_only_once = yes
	
	trigger = {
		tag = AZT
		OR = {
			AND ={
				religion = nahuatl
				has_dlc = "El Dorado"
				is_religion_reformed = no
			}
			NOT = { has_institution = feudalism }
		}
		any_known_country = {
			capital_scope = { continent = europe }
			war_with = AZT
			OR = {
				war_score_against = {
					who = AZT
					value = 50
				}
				AZT = {
					capital_scope = { controlled_by = PREV }
				}
			}
		}
		is_random_new_world = no
	}
	
	immediate = {
		hidden_effect = {
			random_owned_province = {
				limit = {
					is_capital = no
					controlled_by = ROOT
					can_spawn_rebels = nationalist_rebels
				}
				set_province_flag = altepl_joins_invader
			}
			random_owned_province = {
				limit = {
					is_capital = no
					NOT = { has_province_flag = altepl_joins_invader }
					can_spawn_rebels = nationalist_rebels
					controlled_by = ROOT
				}
				set_province_flag = altepl_joins_invader
			}
			random_owned_province = {
				limit = {
					is_capital = no
					NOT = { has_province_flag = altepl_joins_invader }
					can_spawn_rebels = nationalist_rebels
					controlled_by = ROOT
				}
				set_province_flag = altepl_joins_invader
			}
			random_owned_province = {
				limit = {
					is_capital = no
					NOT = { has_province_flag = altepl_joins_invader }
					can_spawn_rebels = nationalist_rebels
					controlled_by = ROOT
				}
				set_province_flag = altepl_joins_invader
			}
		}
	}
	
	mean_time_to_happen = {
		months = 2
	}
	
	option = { #Rebel Scum
		name = flavor_azt.16.a
		random_known_country = {
			limit = {
				capital_scope = { continent = europe }
				war_with = AZT
				OR = {
					war_score_against = {
						who = AZT
						value = 50
					}
					AZT = {
						capital_scope = { controlled_by = PREV }
					}
				}
			}
			country_event = { id = flavor_azt.17 }
		}
		tooltip = {
			every_owned_province = {
				limit = { has_province_flag = altepl_joins_invader }
				create_revolt = 1
			}
		}
	}
}

#Disloyal Altepetls
country_event = {
	id = flavor_azt.17
	title = flavor_azt.17.t
	desc = flavor_azt.17.d
	picture = ANGRY_MOB_eventPicture
	
	is_triggered_only = yes
	
	option = { #Great
		name = flavor_azt.17.a
		
		every_province = {
			limit = {
				has_province_flag = altepl_joins_invader
				can_spawn_rebels = nationalist_rebels
			}
			spawn_rebels = {
				type = nationalist_rebels
				size = 1
				win = yes
				friend = PREV
			}
		}
		every_province = {
			limit = {
				has_province_flag = altepl_joins_invader
				NOT = { can_spawn_rebels = nationalist_rebels }
			}
			spawn_rebels = {
				type = nationalist_rebels
				size = 1
				win = yes
				friend = PREV
			}
		}
	}
}

#The Temples of Cholula
country_event = {
	id = flavor_azt.18
	title = flavor_azt.18.t
	desc = flavor_azt.18.d
	picture = GREAT_BUILDING_eventPicture
	
	trigger = {
		NOT = { religion = nahuatl }
		owns = 2644
		2644 = {
			has_province_modifier = cholula_temples
		}
	}
	
	mean_time_to_happen = {
		months = 12
	}
	
	option = { #Destroy the Temples
		name = flavor_azt.18.a
		ai_chance = { factor = 1 }
		add_years_of_income = 0.01
		2644 = {
			remove_province_modifier = cholula_temples
			add_unrest = 5
		}
	}
	
	option = { #This is a fascinating religion, let us embrace it instead.
		ai_chance = { factor = 1 }
		name = flavor_azt.18.b
		trigger = {
			religion_group = pagan
			is_colonial_nation = no
			NOT = { religion = inti }
			NOT = { religion = mesoamerican_religion }
		}
		change_religion = nahuatl
		if = {
			limit = { government = native }
			change_government = tribal
			#set_legacy_government = tribal_despotism_legacy
		}
	}
	option = { #Let them continue worship there.
		name = flavor_azt.18.c
		trigger = { full_idea_group = humanist_ideas }
		ai_chance = { factor = 0 }
		add_stability = -1
		2644 = {
			remove_province_modifier = cholula_temples
			add_base_tax = 1
		}
	}
	
}

#Rulers of the Lake
country_event = {
	id = flavor_azt.19
	title = flavor_azt.19.t
	desc = flavor_azt.19.d
	picture = GREAT_BUILDING_eventPicture
	
	is_triggered_only = yes
	
	option = { #The reign of Montezuma has started
		name = flavor_azt.19.a
		ai_chance = { factor = 1 }
		
		add_ruler_modifier = {
			name = azt_rise_of_montezuma
			duration = -1
		}
		custom_tooltip = AZT_MONTEZUMA_DESCRIPTION
	}
}

#Conflict Ender
country_event = {
	id = flavor_azt.20
	title = flavor_azt.20.t
	desc = flavor_azt.20.d
	picture = AZTEC_WARRIOR_eventPicture
	
	is_triggered_only = yes
	
	option = { #Our conflict with Tlaxcala is now over
		name = flavor_azt.20.a
		ai_chance = { factor = 1 }
		
		custom_tooltip = AZT_MODIFY_RISE_OF_MONTEZUMA
		hidden_effect = {
			remove_country_modifier = azt_rise_of_montezuma
			add_ruler_modifier = {
				name = azt_rise_of_montezuma_2
				duration = -1
			}
		}
	}
}

#Cloud Splitter
country_event = {
	id = flavor_azt.21
	title = flavor_azt.21.t
	desc = flavor_azt.21.d
	picture = CIVIL_WAR_eventPicture
	
	is_triggered_only = yes
	
	option = { #We have divided them, now it is time we rule them
		name = flavor_azt.21.a
		ai_chance = { factor = 1 }
		
		change_ruler_stat = {
			type = mil
			amount = 1
		}
		custom_tooltip = " "
		custom_tooltip = AZT_MODIFY_RISE_OF_MONTEZUMA_2
		hidden_effect = {
			remove_country_modifier = azt_rise_of_montezuma_2
			add_ruler_modifier = {
				name = azt_rise_of_montezuma_3
				duration = -1
			}
		}
	}
}

#Blood-Spiller
country_event = {
	id = flavor_azt.22
	title = flavor_azt.22.t
	desc = flavor_azt.22.d
	picture = HUMAN_SACRIFICE_eventPicture
	
	is_triggered_only = yes
	
	option = { #Let the blood of our enemies grant the Gods more power
		name = flavor_azt.22.a
		ai_chance = { factor = 1 }
		
		change_ruler_stat = {
			type = adm
			amount = 1
		}

		change_ruler_stat = {
			type = dip
			amount = 2
		}
	}
}

#Wings of Light
country_event = {
	id = flavor_azt.23
	title = flavor_azt.23.t
	desc = flavor_azt.23.d
	picture = GREAT_MAN_eventPicture
	
	is_triggered_only = yes
	
	option = { #We are now the sole rulers of Mesoamerica
		name = flavor_azt.23.a
		ai_chance = { factor = 1 }
		
		change_ruler_stat = {
			type = adm
			amount = 1
		}
		custom_tooltip = SEPERATOR_TOOLTIP
		change_ruler_stat = {
			type = dip
			amount = 1
		}
		
		custom_tooltip = SEPERATOR_TOOLTIP
		
		custom_tooltip = AZT_MODIFY_RISE_OF_MONTEZUMA_3
		hidden_effect = {
			remove_country_modifier = azt_rise_of_montezuma_3
			add_ruler_modifier = {
				name = azt_rise_of_montezuma_4
				duration = -1
			}
		}
	}
}

#Choosing a Patron Deity
country_event = {
	id = flavor_azt.24
	title = flavor_azt.24.t
	desc = flavor_azt.24.d
	picture = HUIZTILOPOCHTLI_eventPicture
	
	is_triggered_only = yes
	
	option = { #Huitzilopochtli
		name = flavor_azt.24.a
		ai_chance = { factor = 1 }
		
		trigger = {
			OR = {
				has_country_flag = azt_tezcatlipoca_deity
				has_country_flag = azt_quetzacoatl_deity
				has_country_flag = azt_tlaloc_deity
			}
		}
		
		clr_country_flag = azt_tezcatlipoca_deity
		clr_country_flag = azt_quetzacoatl_deity
		clr_country_flag = azt_tlaloc_deity
		
		custom_tooltip = AZT_MODIFY_MECHANIC_HUITZILOPOCHTLI
	}
	
	option = { #Tezcatlipoca
		name = flavor_azt.24.b
		ai_chance = { factor = 1 }
		
		trigger = {
			NOT = {
				has_country_flag = azt_tezcatlipoca_deity
			}
		}
		
		clr_country_flag = azt_tlaloc_deity
		clr_country_flag = azt_quetzacoatl_deity
		
		set_country_flag = azt_tezcatlipoca_deity
		
		custom_tooltip = AZT_MODIFY_MECHANIC_TEZCATLIPOCA
	}
	
	option = { #Tlaloc
		name = flavor_azt.24.c
		ai_chance = { factor = 1 }
		
		trigger = {
			NOT = {
				has_country_flag = azt_tlaloc_deity
			}
		}
		
		clr_country_flag = azt_tezcatlipoca_deity
		clr_country_flag = azt_quetzacoatl_deity
		
		set_country_flag = azt_tlaloc_deity
		
		custom_tooltip = AZT_MODIFY_MECHANIC_TLALOC
	}
	
	option = { #Quetzacoatl
		name = flavor_azt.24.dd
		ai_chance = { factor = 1 }
		
		trigger = {
			NOT = {
				has_country_flag = azt_quetzacoatl_deity
			}
		}
		
		clr_country_flag = azt_tlaloc_deity
		clr_country_flag = azt_tezcatlipoca_deity
		
		set_country_flag = azt_quetzacoatl_deity
		
		custom_tooltip = AZT_MODIFY_MECHANIC_QUETZACOATL
	}
}

#Fate of the Alliance
country_event = {
	id = flavor_azt.25
	title = flavor_azt.25.t
	desc = flavor_azt.25.d
	picture = GREAT_BUILDING_eventPicture
	
	is_triggered_only = yes
	
	option = { #Tenochtitlan Reigns Supreme
		name = flavor_azt.25.a
		ai_chance = { factor = 1 }
		
		remove_estate_privilege = estate_nobles_AZT_triple_alliance
		change_estate_land_share = {
			estate = estate_nobles
			share = -10
		}
	}
	
	option = { #Let us retain this alliance
		name = flavor_azt.25.b
		ai_chance = { factor = 1 }
		
		custom_tooltip = AZT_MODIFY_TRIPLE_ALLIANCE_PRIVILEGE
		set_country_flag = azt_triple_alliance_buff
		
		custom_tooltip = SEPERATOR_TOOLTIP
		
		custom_tooltip = AZT_GAIN_DEVELOPMENT_PER_SUBJECT
		hidden_effect = {
			every_subject_country = {
				overlord = {
					capital_scope = {
						random_list = {
							33 = {
								add_base_tax = 1
							}
							33 = {
								add_base_production = 1
							}
							33 = {
								add_base_manpower = 1
							}
						}
					}
				}
			}
		}
	}
}