# Carnal sins
country_event = {
	id = 9450
	title = "EVTNAME9450"
	desc = "EVTDESC9450"
	picture = RELIGION_eventPicture
	
	trigger = {
		papacy_active = yes
		has_heir = no
		has_regency = no
		is_female = no
		is_lesser_in_union = no
		religion = catholic
		government = monarchy
		dip = 2
	}
	
	mean_time_to_happen = {
		months = 400
		
		modifier = {
			factor = 0.5
			dip = 4
		}
	}
	
	option = {
		name = "EVTOPTA9450"
		define_heir = {
			dynasty = ROOT
			claim = 30
		}
		add_papal_influence = -5
		add_reform_desire = 0.01
	}
	option = {
		name = "EVTOPTB9450"
		add_papal_influence = 2
	}
}

# A beloved heir dies
country_event = {
	id = 9451
	title = "EVTNAME9451"
	desc = "EVTDESC9451"
	picture = DEATH_OF_HEIR_eventPicture
	
	trigger = {
		has_heir = yes
		heir_claim = 90
		is_female = no
		NOT = {
			is_lesser_in_union = yes
		}
		has_regency = no
		government = monarchy
	}
	
	mean_time_to_happen = {
		months = 3600
	}
	
	option = {
		name = "EVTOPTA9451"
		kill_heir = yes
		random_owned_province = {
			limit = {
				NOT = {
					has_building = temple
				}
			}
			add_building = temple
		}
	}
	
	option = {
		name = "EVTOPTB9451"
		kill_heir = yes
		define_heir = {
			dynasty = ROOT
			claim = 30
		}
	}
}

# Palace Coup
country_event = {
	id = 9452
	title = "EVTNAME9452"
	desc = "EVTDESC9452"
	picture = ASSASSINATION_eventPicture
	
	trigger = {
		has_heir = yes
		heir_age = 15
		heir_claim = 90
		NOT = {
			is_lesser_in_union = yes
			stability = -2
		}
		has_regency = no
		government = monarchy
	}
	
	mean_time_to_happen = {
		months = 200
		modifier = {
			factor = 0.5
			is_at_war = yes
		}
	}
	
	option = {
		name = "EVTOPTA9452"
		kill_ruler = yes
		add_country_modifier = {
			name = "illegitimate_ruler"
			duration = 1825
		}
	}
	
	option = {
		name = "EVTOPTB9452"
		kill_heir = yes
	}
}

# The Weeping Song
country_event = {
	id = 9453
	title = "EVTNAME9453"
	desc = "EVTDESC9453"
	picture = COURT_eventPicture
	
	trigger = {
		has_heir = yes
		has_wartaxes = yes
		treasury = 40
		war_exhaustion = 4
		has_regency = no
		government = monarchy
	}
	
	mean_time_to_happen = {
		months = 25
	}
	
	option = {
		name = "EVTOPTA9453"
		add_treasury = -40
		add_war_exhaustion = -2
	}
	
	option = {
		name = "EVTOPTB9453"
		add_manpower = 1
	}
}

# Springtime
country_event = {
	id = 9454
	title = "EVTNAME9454"
	desc = "EVTDESC9454"
	picture = COURT_eventPicture
	
	trigger = {
		government = monarchy
		is_month = 3
		NOT = { is_month = 6 }
		has_heir = no
		is_female = no
		is_lesser_in_union = no
		has_regency = no
		any_known_country = {
			religion = ROOT
			government = monarchy
			is_lesser_in_union = no
		}
	}
	
	mean_time_to_happen = {
		months = 400
	}
	
	option = {
		name = "EVTOPTA9454"
		define_heir = {
			dynasty = ROOT
			claim = 30
		}
	}
	option = {
		name = "EVTOPTB9454"
		random_known_country = {
			limit = {
				religion = ROOT
				government = monarchy
				is_lesser_in_union = no
			}
			create_marriage = ROOT
		}
	}
}

# Soirée
country_event = {
	id = 9455
	title = "EVTNAME9455"
	desc = "EVTDESC9455"
	picture = COURT_eventPicture
	
	trigger = {
		has_heir = no
		is_lesser_in_union = no
		government = monarchy
		has_regency = no
	}
	
	mean_time_to_happen = {
		months = 800
	}
	
	option = {
		name = "EVTOPTA9455"
		define_heir = {
			dynasty = ROOT
			claim = 30
		}
		add_prestige = -10
	}
	option = {
		name = "EVTOPTB9455"
		random_list = {
			10 = { create_advisor = theologian }
			10 = { create_advisor = artist }
			10 = { create_advisor = philosopher }
		}
		add_prestige = -5
	}
}

# Heir Falls ill
country_event = {
	id = 9456
	title = "EVTNAME9456"
	desc = "EVTDESC9456"
	picture = PLAGUE_eventPicture
	
	trigger = {
		has_heir = yes
		government = monarchy
		is_lesser_in_union = no
	}
	
	mean_time_to_happen = {
		months = 2400
	}
	option = {
		name = "EVTOPTA9456"
		add_years_of_income = -0.2
		random_list = {
			50 = { kill_heir = yes}
			50 = { add_legitimacy = 5}
		}
	}
	
	option = {
		name = "EVTOPTB9456"
		random_list = {
			75 = { kill_heir = yes}
			25 = { add_legitimacy = 30}
		}
		
	}
}

# Child in the Reeds
country_event = {
	id = 9457
	title = "EVTNAME9457"
	desc = "EVTDESC9457"
	picture = NEW_HEIR_eventPicture
	
	trigger = {
		NOT = {
			has_heir = yes
			is_lesser_in_union = yes
		}
		government = monarchy
		religion_group = christian
	}
	
	mean_time_to_happen = {
		months = 1500
		modifier = {
			factor = 0.7
			is_defender_of_faith = yes
		}
	}
	
	option = {
		name = "EVTOPTA9457"
		define_heir = {
			claim = 20
			dynasty = ROOT
			adm = 1
			dip = 1
			mil = 1
		}
		add_prestige = -5
		add_country_modifier = {
			name = adopted_heir
			duration = 1825
		}
	}
	option = {
		name = "EVTOPTB9457"
		add_treasury = 5
	}
}

# Tournament
country_event = {
	id = 9458
	title = "EVTNAME9458"
	desc = "EVTDESC9458"
	picture = TOURNAMENT_eventPicture
	
	trigger = {
		has_heir = yes
		heir_age = 15
		NOT = {
			is_year = 1450
			is_lesser_in_union = yes
		}
		NOT = {
			has_country_flag = last_jousting_tournament_held
		}
		army_tradition =  20
		technology_group = western
	}
	
	mean_time_to_happen = {
		months = 2400
		modifier = {
			factor = 0.9
			army_tradition = 40
		}
	}
	
	option = {
		name = "EVTOPTA9458"
		random_list = {
			50 = { add_years_of_income = 0.05 }
			45 = { add_legitimacy = 20}
			5 = { kill_heir = yes}
		}
	}
	
	option = {
		name = "EVTOPTB9458"
		add_adm_power = 20
	}
	
	option = {
		name = "EVTOPTC9458"
		add_prestige = 5
	}
}


# Hunting accident
country_event = {
	id = 9459
	title = "EVTNAME9459"
	desc = "EVTDESC9459"
	picture = DEATH_OF_HEIR_eventPicture
	
	trigger = {
		has_heir = yes
		heir_age = 15
		is_lesser_in_union = no
	}
	mean_time_to_happen = {
		months = 2700
	}
	option = {
		name = "EVTOPTA9459"
		kill_heir = yes
		add_stability = -1
	}
	option = {
		name = "EVTOPTB9459"
		kill_heir = yes
		add_prestige = -25
	}
}


# Heir goes out at night
country_event = {
	id = 9460
	title = "EVTNAME9460"
	desc = "EVTDESC9460"
	picture = COURT_eventPicture
	
	trigger = {
		capital_scope = { continent = europe }
		religion_group = christian
		has_heir = yes
		heir_age = 15
		is_lesser_in_union = no
	}
	
	mean_time_to_happen = {
		months = 1000
		
	}
	option = {
		name = "EVTOPTA9460"
		add_prestige = -5
	}
	
	option = {
		name = "EVTOPTB9460"
		add_heir_claim = -20
	}
}

# Scheming Bureaucracy
country_event = {
	id = 9462
	title = "EVTNAME9462"
	desc = "EVTDESC9462"
	picture = DEBATE_REPUBLICAN_eventPicture
	
	trigger = {
		government = monarchy
		is_subject = no
		adm_tech = 20
		adm_power = 200
		has_factions = no
	}
	
	mean_time_to_happen = {
		months = 10000
	}
	
	option = {
		name = "EVTOPTA9462"
		ai_chance = { factor = 99 }
		add_adm_power = -100
		add_stability = -1
	}
	option = {
		name = "EVTOPTB9462"
		ai_chance = { factor = 1 }
		kill_ruler = yes
		add_stability = -6
		change_government = bureaucratic_despotism
	}
}

# The Family
country_event = {
	id = 9463
	title = "EVTNAME9463"
	desc = "EVTDESC9463"
	picture = GOOD_WITH_MONARCH_eventPicture
	
	trigger = {
		stability = 3
		treasury = 100
		government = monarchy
		has_regency = no
		any_known_country = {
			dynasty = ROOT
			government = monarchy
			NOT = { stability = -2 }
			NOT = { senior_union_with = ROOT }
			NOT = { junior_union_with = ROOT }
		}
	}
	
	mean_time_to_happen = {
		months = 18
	}
	
	option = {
		name = "EVTOPTA9463"
		random_country = {
			limit = {
				dynasty = ROOT
				government = monarchy
				NOT = { stability = -2 }
				NOT = { senior_union_with = ROOT }
				NOT = { junior_union_with = ROOT }
			}
			country_event = { id = 9476 }
			add_opinion = { who = ROOT modifier = opinion_dynastic_helper }
		}
		add_treasury = -100
		add_prestige = 10
	}
	option = {
		name = "EVTOPTB9463"
		random_country = {
			limit = { 
				dynasty = ROOT
				government = monarchy
				NOT = { stability = -2 }
				NOT = { senior_union_with = ROOT }
				NOT = { junior_union_with = ROOT }
			}
			country_event  = { id = 9477 }
			add_opinion = { who = ROOT modifier = opinion_ignore_dynasty }
		}
	}
}

# Regent usurps throne
country_event = {
	id = 9468
	title = "EVTNAME9468"
	desc = "EVTDESC9468"
	picture = DEATH_OF_HEIR_eventPicture
	
	trigger = {
		stability = 3
		NOT = {
			overextension_percentage = 0.05
			is_lesser_in_union = yes
		}
		government = monarchy
		has_regency = yes
		legitimacy = 100
		has_heir = yes
	}
	
	mean_time_to_happen = {
		months = 700
	}
	
	option = {
		name = "EVTOPTA9468"
		kill_heir = yes
		define_ruler = {
			adm = 0
			dip = 0
			mil = 0
		}
		add_stability = -3
		add_legitimacy = -90
		add_country_modifier = {
			name = "plutocracy_modifier"
			duration = 7300
		}
		add_country_modifier = {
			name = "centralization_modifier"
			duration = 3650
		}
	}
	option = {
		name = "EVTOPTB9468"
		add_stability = -1
	}
}

# Born under a star
country_event = {
	id = 9469
	title = "EVTNAME9469"
	desc = "EVTDESC9469"
	picture = NEW_HEIR_eventPicture
	
	trigger = {
		government = monarchy
		technology_group = western
		is_lesser_in_union = no
		has_heir = no
		has_regency = no
	}
	
	mean_time_to_happen = {
		months = 2000
	}
	
	option = {
		name = "EVTOPTA9469"
		define_heir = {
			dynasty = ROOT
			name = "Alexander"
			claim = 100
			mil = 6
		}
	}
	option = {
		name = "EVTOPTB9469"
		define_heir = {
			dynasty = ROOT
			name = "Caesar"
			claim = 100
			adm = 6
		}
	}
	option = {
		name = "EVTOPTC9469"
		define_heir = {
			dynasty = ROOT
			name = "Johan"
			claim = 100
			dip = 6
		}
	}	
}

# Heir is of our Dynasty
country_event = {
	id = 9470
	title = "EVTNAME9470"
	desc = "EVTDESC9470"
	picture = NEW_HEIR_eventPicture
	
	trigger = {
		government = monarchy
		has_regency = no
		is_lesser_in_union = no
		num_of_royal_marriages = 4
		any_country = {
			government = monarchy
			marriage_with = ROOT
			has_heir = no
			is_lesser_in_union = no
		}
	}
	
	mean_time_to_happen = {
		months = 1500
		modifier = {
			factor = 0.9
			num_of_royal_marriages = 6
		}
	}
	
	option = {
		name = "EVTOPTA9470"
		trigger = {
			NOT = { dynasty = "von Habsburg" }
		}
		random_country = {
			limit = {
				government = monarchy
				marriage_with = ROOT
				has_heir = no
			}
			define_heir = {
				dynasty = ROOT
			}
		}
	}
	option = {
		name = "EVTOPTB9470"
		trigger = {
			dynasty = "von Habsburg"
		}
		random_country = {
			limit = {
				government = monarchy
				marriage_with = ROOT
				has_heir = no
			}
			define_heir = {
				dynasty = ROOT
			}
		}
	}
}

# The Family Opt 1
country_event = {
	id = 9476
	title = "EVTNAME9476"
	desc = "EVTDESC9476"
	picture = DIPLOMACY_eventPicture
	
	is_triggered_only = yes
	
	option = {
		name = "EVTOPTA9476"
		add_treasury = 100
		random_list = {
			10 = {
				add_stability = 1
			}
			10 = {
				add_stability = 2
			}
			
			10 = { 
				add_stability = 3
			}
		}
	}
}

# The Family Opt 2
country_event = {
	id = 9477
	title = "EVTNAME9477"
	desc = "EVTDESC9477"
	picture = DIPLOMACY_eventPicture
	
	is_triggered_only = yes
	
	option = {
		name = "EVTOPTA9476"
		random_list = {
			10 = {
				add_stability = 1
			}
			10 = {
				kill_ruler = yes
			}
			10 = {
				add_stability = -2
			}
		}
	}
}

# Fear and Loathing 1/3
province_event = {
	id = 9481
	title = "EVTNAME9481"
	desc = "EVTDESC9481"
	picture = ASSASSINATION_eventPicture
	
	trigger = {
		papacy_active = yes
		is_capital = yes
		owner = {
			has_regency = no
			has_heir = yes
			religion_group = christian
			is_lesser_in_union = no
			NOT = { has_country_flag = murdering_bastard }
			NOT = { has_country_flag = contained_insanity }
			NOT = { heir_age = 3 }
		}
	}
	
	mean_time_to_happen = {
		months = 4000
	}
	
	option = {
		name = "EVTOPTA9481"
		owner = {
			kill_heir = yes
			set_country_flag = murdering_bastard
		}
	}
	
	option = {
		name = "EVTOPTB9481"
		owner = {
			add_papal_influence = 5
			set_country_flag = contained_insanity
		}
	}
}

# Fear and Loathing 2/3
country_event = {
	id = 9482
	title = "EVTNAME9482"
	desc = "EVTDESC9482"
	picture = DEATH_OF_HEIR_eventPicture
	
	trigger = {
		has_country_flag = murdering_bastard
		NOT = { has_country_flag = contained_insanity }
		has_regency = no
		is_lesser_in_union = no
	}
	
	mean_time_to_happen = {
		months = 12
	}
	
	option = {
		name = "EVTOPTA9482"
		kill_ruler = yes
		clr_country_flag = murdering_bastard
	}
	
	option = {
		name = "EVTOPTB9482"
		add_prestige = -5
		add_treasury = -100
		set_country_flag = contained_insanity
	}
}

# Fear and Loathing 3/3
country_event = {
	id = 9483
	title = "EVTNAME9483"
	desc = "EVTDESC9483"
	picture = DEATH_OF_HEIR_eventPicture

	trigger = {
		has_country_flag = contained_insanity
		has_regency = no
		is_lesser_in_union = no
	}
	
	mean_time_to_happen = {
		months = 300
	}
	
	option = {
		name = "EVTOPTA9483"
		add_stability = -3
		add_treasury = -100
		add_prestige = -20
		clr_country_flag = contained_insanity
	}
	
	option = {
		name = "EVTOPTB9483"
		kill_ruler = yes
		add_country_modifier = {
			name = "relief_from"
			duration = 3650
		}
		clr_country_flag = contained_insanity
	}
}

# Fear and Loathing removal on ruler death, ontriggered
country_event = {
	id = 9492
	title = "EVTNAME9492"
	desc = "EVTDESC9492"
	picture = DEATH_OF_HEIR_eventPicture
	
	trigger = {
		OR = {
			has_country_flag = contained_insanity
			has_country_flag = murdering_bastard
		}
	}
	
	is_triggered_only = yes
	
	option = {
		name = "EVTOPTA9492"
		add_country_modifier = {
			name = "relief_from"
			duration = 3650
		}
		clr_country_flag = contained_insanity
		clr_country_flag = murdering_bastard
	}
}

# Wedding bells
country_event = {
	id = 9484
	title = "EVTNAME9484"
	desc = "EVTDESC9484"
	picture = GOOD_WITH_MONARCH_eventPicture
	
	trigger = {
		prestige = 30
		government = monarchy
		is_lesser_in_union = no
		is_at_war = no
		NOT = {
			has_regency = yes
			has_heir = yes
			is_female = yes
			num_of_royal_marriages = 1
			overextension_percentage = 0.01
		}
	}
	
	mean_time_to_happen = {
		months = 500
	}
	
	option = {
		name = "EVTOPTA9484"   #Time to settle down
		random_country = {
			limit = {
				religion = ROOT
				government = monarchy
				NOT = {
					is_lesser_in_union = yes
				}
			}
			create_marriage = ROOT
		}
	}
	
	option = {
		name = "EVTOPTB9484"  #No
		add_prestige = 5
		add_country_modifier = {
			name = "sought_after_bachelor"
			duration = -1
		}
	}
}

# A modest proposal
country_event = {
	id = 9485
	title = "EVTNAME9485"
	desc = "EVTDESC9485"
	picture = DIPLOMACY_eventPicture
	
	trigger = {
		any_known_country = {
			has_country_modifier = sought_after_bachelor
			is_lesser_in_union = no
			government = monarchy
			religion_group = ROOT
		}
		government = monarchy
		is_lesser_in_union = no
	}
	
	mean_time_to_happen = {
		months = 400
	}
	
	option = {
		name = "EVTOPTA9485"
		random_country = {
			limit = {
				has_country_modifier = sought_after_bachelor
				religion_group = ROOT
			}
			random_list = {
				20 = { country_event = { id = 9486 } }
				80 = { country_event = { id = 9487 } }
			}
		}
		add_treasury = -15
		add_dip_power = -10
	}
	
	option = {
		name = "EVTOPTB9485"
		add_treasury = 10
		add_adm_power = 10
	}
}

# Wedding bells
country_event = {
	id = 9486
	title = "EVTNAME9486"
	desc = "EVTDESC9486"
	picture = GOOD_WITH_MONARCH_eventPicture
	
	is_triggered_only = yes
	
	option = {
		name = "EVTOPTA9486"
		create_marriage = FROM
		add_opinion = { who = FROM modifier = opinion_marriage_offer }
		remove_country_modifier = sought_after_bachelor
	}
	
	option = {
		name = "EVTOPTB9486"
		reverse_add_opinion = { who = FROM modifier = opinion_witchcraft }
		random_list = {
			10 = { kill_ruler = yes }
			10 = { add_prestige = -5 }
		}
	}
}

# Wedding bells
country_event = {
	id = 9487
	title = "EVTNAME9487"
	desc = "EVTDESC9487"
	picture = GOOD_WITH_MONARCH_eventPicture
	
	is_triggered_only = yes
	
	option = {
		name = "EVTOPTA9487"
		create_marriage = FROM
		add_opinion = { who = FROM modifier = opinion_united_dynasties }
		remove_country_modifier = sought_after_bachelor
	}
	
	option = {
		name = "EVTOPTB9487"
		reverse_add_opinion = { who = FROM modifier = opinion_refused_marriage }
		random_list = {
			10 = { kill_ruler = yes }
			10 = { add_prestige = -5 }
		}
	}
}

#Last war was a failure
country_event = {
	id = 9488
	title = "EVTNAME9488"
	desc = "EVTDESC9488"
	picture = MILITARY_CAMP_eventPicture
	
	trigger = {
		government = monarchy
		has_heir = yes
		heir_age = 20
		any_known_country = {
			truce_with = ROOT
		}
		is_at_war = no
		is_lesser_in_union = no
		war_exhaustion = 12
	}
	
	mean_time_to_happen = {
		months = 300
	}
	
	option = {
		name = "EVTOPTA9488"
		kill_ruler = yes
		add_war_exhaustion = -4
		add_stability = 1
	}
	
	option = {
		name = "EVTOPTB9488"
		kill_heir = yes
		add_war_exhaustion = -2
	}
}

# The Moon
province_event = {
	id = 9489
	title = "EVTNAME9489"
	desc = "EVTDESC9489"
	picture = IMPORTANT_STATUE_eventPicture
	
	trigger = {
		has_building = glorious_monument
		owner = {
			war_exhaustion = 4
			adm = 3
		}
	}
	
	mean_time_to_happen = {
		months = 300
	}
	
	option = {
		name = "EVTOPTA9489"
		owner = {
			add_prestige = 5
		}
	}
	
	option = {
		name = "EVTOPTB9489"
		owner = {
			add_adm_power = 25
		}
	}
}

# Seeing the real you
country_event = {
	id = 9490
	title = "EVTNAME9490"
	desc = "EVTDESC9490"
	picture = NEW_HEIR_eventPicture
	
	trigger = {
		is_lesser_in_union = no
		government = monarchy
		has_heir = no
		is_female = no
		num_of_royal_marriages = 1
		NOT = {
			has_country_modifier = a_woman_scorned
		}
	}
	
	mean_time_to_happen = {
		months = 1400
	}
	
	option = {
		name = "EVTOPTA9490"
		define_heir = {
			dynasty = ROOT
		}
	}
	
	option = {
		name = "EVTOPTB9490"
		add_years_of_income = 0.2
		add_country_modifier = {
			name = "a_woman_scorned"
			duration = 1825
		}
	}
}
