# Join the HRE
province_event = {

	id = 1051
	
	trigger = {
		hre = no
		religion_group = christian
		emperor = { relation = { who = THIS value = 100 } }
		any_neighbor_province = {
			hre = yes
		}
		owner = {
			is_emperor = no
			religion_group = christian
		}
	}

	mean_time_to_happen = {
		
		months = 300
		
		modifier = {
			factor = 0.8
			emperor = { relation = { who = THIS value = 100 } }
		}
		modifier = {
			factor = 0.7
			emperor = { relation = { who = THIS value = 150 } }
		}
		modifier = {
			factor = 0.9
			any_neighbor_country = {
				elector = yes
			}
		}
		modifier = {
			factor = 0.9
			emperor = { religion = THIS }
		}
		modifier = {
			factor = 1.1
			emperor = { NOT = { religion = THIS } }
		}
		modifier = {
			factor = 0.9
			owner = {
				advisor = diplomat
			}
		}
		modifier = {
			factor = 1.1
			owner = {
				NOT = { advisor = diplomat }
			}
		}
		modifier = {
			factor = 0.9
			owner = {
				diplomat = 5
			}
		}		
	}

	title = "EVTNAME1051"
	desc = "EVTDESC1051"

	option = {				# Prepare to join
		name = "EVTOPTA1051"
		ai_chance = { factor = 80 }
		hre = yes
		owner = { prestige = 0.02 }
		emperor = { relation = { who = THIS value = 100 } }
	}
	option = {				# Stay neutral
		name = "EVTOPTB1051"
		ai_chance = { factor = 20 }
		owner = { prestige = -0.02 }
		emperor = { relation = { who = THIS value = -100 } }
	}
}


# Leave the HRE
province_event = {

	id = 1052
	
	trigger = {
		hre = yes
		emperor = { 
			NOT = { relation = { who = THIS value = 0 } }
		}
		owner = {
			is_emperor = no
			capital_scope = {
				hre = no
			}
		}

	}

	mean_time_to_happen = {
	
		months = 450

		modifier = {
			factor = 0.5
			any_neighbor_province = {
				hre = no
			}
		}
		modifier = {
			factor = 0.5
			owner = {
				NOT = { religion_group = christian }
			}
		}		
		modifier = {
			factor = 0.9
			emperor = {
				NOT = { relation = { who = THIS value = -50 } }
			}
		}
		modifier = {
			factor = 0.8
			emperor = {
				NOT = { relation = { who = THIS value = -100 } }
			}
		}
		modifier = {
			factor = 0.9
			emperor = { 
				NOT = { religion = THIS }
			}
		}
		modifier = {
			factor = 1.1
			emperor = { 
				religion = THIS
			}
		}		
		modifier = {
			factor = 0.9
			owner = { badboy = 0.30 }
		}
		modifier = {
			factor = 0.9
			owner = { badboy = 0.45 }
		}
		modifier = {
			factor = 0.9
			owner = { NOT = { stability = 0 } }
		}
		modifier = {
			factor = 1.1
			owner = { stability = 1 }
		}
	}

	title = "EVTNAME1052"
	desc = "EVTDESC1052"

	option = {				# Leave the Empire
		name = "EVTOPTA1052"
		ai_chance = { factor = 10 }
		hre = no
		emperor = {
			relation = { who = THIS value = -100 }
		}
	}
	option = {				# Attempt to improve relations
		name = "EVTOPTB1052"
		ai_chance = { factor = 90 }
		emperor = { 
			relation = { who = THIS value = 50 }
		}
	}
}



# Leave the HRE
province_event = {

	id = 1053
	
	trigger = {
		hre = yes
		emperor = { 
			NOT = { relation = { who = THIS value = 0 } }
		}
		owner = {
			badboy = 0.30
			is_emperor = no
		}
	}

	mean_time_to_happen = {
	
		months = 300

		modifier = {
			factor = 0.5
			owner = {
				NOT = { religion_group = christian }
			}
		}		
		modifier = {
			factor = 0.9
			emperor = {
				NOT = { relation = { who = THIS value = -50 } }
			}
		}
		modifier = {
			factor = 0.8
			emperor = {
				NOT = { relation = { who = THIS value = -100 } }
			}
		}
		modifier = {
			factor = 0.9
			any_neighbor_province = {
				NOT = { relation = { who = THIS value = 0 } }
			}
		}
		modifier = {
			factor = 0.9
			emperor = { 
				NOT = { religion = THIS }
			}
		}
		modifier = {
			factor = 1.1
			emperor = { 
				religion = THIS
			}
		}
		modifier = {
			factor = 0.9
			owner = { NOT = { stability = 0 } }
		}
		modifier = {
			factor = 1.1
			owner = { stability = 1 }
		}
		modifier = {
			factor = 1.15
			owner = { stability = 3 }
		}
	}

	title = "EVTNAME1053"
	desc = "EVTDESC1053"

	option = {				# Leave the Empire
		name = "EVTOPTA1053"
		ai_chance = { factor = 10 }
		hre = no
		emperor = {
			relation = { who = THIS value = -100 }
		}
	}
	option = {				# Attempt to improve relations
		name = "EVTOPTB1053"
		ai_chance = { factor = 90 }
		emperor = { 
			relation = { who = THIS value = 50 }
		}
	}
}



# Become an elector
country_event = {

	id = 1054
	
	trigger = {
		NOT = { num_of_electors = 8 }
		elector = no
		is_emperor = no
		capital_scope = { hre = yes }
	}

	mean_time_to_happen = {
	
		months = 60

		modifier = {
			factor = 0.6
			NOT = { num_of_electors = 6 }
		}
		modifier = {
			factor = 0.4
			NOT = { num_of_electors = 4 }
		}
		modifier = {
			factor = 0.2
			NOT = { num_of_electors = 2 }
		}
		modifier = {
			factor = 0.9
			emperor = { relation = { who = THIS value = 50 } }
		}
		modifier = {
			factor = 0.9
			emperor = { relation = { who = THIS value = 100 } }
		}
		modifier = {
			factor = 0.9
			emperor = { relation = { who = THIS value = 150 } }
		}
		modifier = {
			factor = 0.9
			any_neighbor_country = {
				is_emperor = yes
			}
		}
		modifier = {
			factor = 0.9
			religion = catholic
		}
		modifier = {
			factor = 1.1
			NOT = { religion = catholic }
		}
		modifier = {
			factor = 0.9
			stability = 1
		}
		modifier = {
			factor = 1.1
			NOT = { stability = 0 }
		}
	}

	title = "EVTNAME1054"
	desc = "EVTDESC1054"

	option = {
		name = "EVTOPTA1054"		# An offer too good to pass
		ai_chance = { factor = 90 }
		elector = yes
		prestige = 0.05
		emperor = { relation = { who = THIS value = 100 } }
	}
	option = {
		name = "EVTOPTB1054"		# Unfortunately we have to decline
		ai_chance = { factor = 10 }
		prestige = -0.03
		emperor = { relation = { who = THIS value = -100 } }

	}
}

# Remove elector
country_event = {

	id = 1055
	
	trigger = {
		elector = yes
		is_emperor = no
		num_of_electors = 7
		emperor = { 
			NOT = { relation = { who = THIS value = 0 } }
		}
		any_neighbor_country = {
			elector = yes
			NOT = { relation = { who = THIS value = 0 } }			
		}
	}

	mean_time_to_happen = {
	
		months = 300
		
		modifier = {
			factor = 0.9
			emperor = { 
				NOT = { relation = { who = THIS value = -50 } }
			}
		}
		modifier = {
			factor = 0.9
			emperor = {
				NOT = { relation = { who = THIS value = -100 } }
			}
		}
		modifier = {
			factor = 0.9
			emperor = {
				NOT = { relation = { who = THIS value = -150 } }
			}
		}
		modifier = {
			factor = 0.9
			emperor = { 
				NOT = { religion = THIS }
			}
		}
		modifier = {
			factor = 1.1
			emperor = { 
				religion = THIS
			}
		}
		modifier = {
			factor = 0.8
			badboy = 0.30
		}
		modifier = {
			factor = 0.9
			NOT = { stability = 0 }
		}
		modifier = {
			factor = 1.1
			stability = 0
		}
	}

	title = "EVTNAME1055"
	desc = "EVTDESC1055"

	option = {
		name = "EVTOPTA1055"		# Try to mend the situation
		ai_chance = { factor = 80 }
		elector = no
		prestige = -0.02
		emperor = { relation = { who = THIS value = -50 } }
	}
	option = {
		name = "EVTOPTB1055"		# We won't forget this!
		ai_chance = { factor = 20 }
		elector = no
		prestige = -0.01
		emperor = { relation = { who = THIS value = -100 } }
	}
}


# Remove elector
country_event = {

	id = 1056
	
	trigger = {
		elector = yes
		is_emperor = no
		num_of_electors = 7
		emperor = {
			NOT = { relation = { who = THIS value = 0 } }
		}
		badboy = 0.30
	}

	mean_time_to_happen = {
	
		months = 300
		
		modifier = {
			factor = 0.9
			emperor = { 
				NOT = { relation = { who = THIS value = -50 } }
			}
		}
		modifier = {
			factor = 0.9
			emperor = {
				NOT = { relation = { who = THIS value = -100 } }
			}
		}
		modifier = {
			factor = 0.9
			emperor = { 
				NOT = { relation = { who = THIS value = -150 } }
			}
		}
		modifier = {
			factor = 0.9
			badboy = 0.45
		}
		modifier = {
			factor = 0.9
			badboy = 0.60
		}
		modifier = {
			factor = 0.9
			NOT = { stability = 0 }
		}
		modifier = {
			factor = 1.1
			stability = 0
		}
	}

	title = "EVTNAME1056"
	desc = "EVTDESC1056"

	option = {
		name = "EVTOPTA1056"		# Try to mend the situation
		ai_chance = { factor = 80 }
		elector = no
		prestige = -0.02
		emperor = { relation = { who = THIS value = -50 } }
	}
	option = {
		name = "EVTOPTB1056"		# We won't forget this!
		ai_chance = { factor = 20 }
		elector = no
		prestige = -0.01
		emperor = { relation = { who = THIS value = -100 } }
	}
}
