# Secularism Abandoned
country_event = {
	id = et.28
	title = "et.EVTNAME28"
	desc = "et.EVTDESC28"
	picture = RELIGION_eventPicture

	is_triggered_only = yes
	
	option = {
		name = "et.EVTOPTA28"
		trigger = {
			any_owned_province = {
				religion = catholic
			}
		}
		change_religion = catholic
		clr_country_flag = secularism_abolished
	}
	option = {
		name = "et.EVTOPTB28"
		trigger = {
			any_owned_province = {
				religion = protestant
			}
		}
		change_religion = protestant
		clr_country_flag = secularism_abolished
	}
	option = {
		name = "et.EVTOPTC28"
		trigger = {
			any_owned_province = {
				religion = reformed
			}
		}
		change_religion = reformed
		clr_country_flag = secularism_abolished
	}
	option = {
		name = "et.EVTOPTD28"
		trigger = {
			any_owned_province = {
				religion = orthodox
			}
		}
		change_religion = orthodox
		clr_country_flag = secularism_abolished
	}
	option = {
		name = "et.EVTOPTE28"
		trigger = {
			any_owned_province = {
				religion = coptic
			}
		}
		change_religion = coptic
		clr_country_flag = secularism_abolished
	}
	option = {
		name = "et.EVTOPTF28"
		trigger = {
			any_owned_province = {
				religion = sunni
			}
		}
		change_religion = sunni
		clr_country_flag = secularism_abolished
	}
	option = {
		name = "et.EVTOPTG28"
		trigger = {
			any_owned_province = {
				religion = shiite
			}
		}
		change_religion = shiite
		clr_country_flag = secularism_abolished
	}
	option = {
		name = "et.EVTOPTH28"
		trigger = {
			any_owned_province = {
				religion = ibadi
			}
		}
		change_religion = ibadi
		clr_country_flag = secularism_abolished
	}
	option = {
		name = "et.EVTOPTI28"
		trigger = {
			any_owned_province = {
				religion = mahayana
			}
		}
		change_religion = mahayana
		clr_country_flag = secularism_abolished
	}
	option = {
		name = "et.EVTOPTJ28"
		trigger = {
			any_owned_province = {
				religion = buddhism
			}
		}
		change_religion = buddhism
		clr_country_flag = secularism_abolished
	}
	option = {
		name = "et.EVTOPTK28"
		trigger = {
			any_owned_province = {
				religion = vajrayana
			}
		}
		change_religion = vajrayana
		clr_country_flag = secularism_abolished
	}
	option = {
		name = "et.EVTOPTL28"
		trigger = {
			any_owned_province = {
				religion = hinduism
			}
		}
		change_religion = hinduism
		clr_country_flag = secularism_abolished
	}
	option = {
		name = "et.EVTOPTM28"
		trigger = {
			any_owned_province = {
				religion = confucianism
			}
		}
		change_religion = confucianism
		clr_country_flag = secularism_abolished
	}
	option = {
		name = "et.EVTOPTN28"
		trigger = {
			any_owned_province = {
				religion = shinto
			}
		}
		change_religion = shinto
		clr_country_flag = secularism_abolished
	}
	option = {
		name = "et.EVTOPTO28"
		trigger = {
			any_owned_province = {
				religion = jewish
			}
		}
		change_religion = jewish
		clr_country_flag = secularism_abolished
	}
	option = {
		name = "et.EVTOPTP28"
		trigger = {
			any_owned_province = {
				religion = zoroastrian
			}
		}
		change_religion = zoroastrian
		clr_country_flag = secularism_abolished
	}
	option = {
		name = "et.EVTOPTQ28"
		clr_country_flag = secularism_abolished
	}
}

#Clear Secular provinces
province_event = {

	id = et.54
	title = "et.EVTNAME54"
	desc = "et.EVTDESC54"
	picture = RELIGIOUS_CONVERSION_eventPicture
	
	trigger = {
		religion = secularism
		is_city = yes
	}
	mean_time_to_happen = {
		months = 2
	}
	
	option = {
		name = "et.EVTOPTA54"
		change_religion = irreligious
		owner = {
			every_owned_province = {
				limit = { religion = secularism }
				change_religion = irreligious
			}
		}
	}
}

#Irreligion Spreads
country_event = {

	id = et.76
	title = "et.EVTNAME76"
	desc = "et.EVTDESC76"
	picture = REFORM_eventPicture
	
	trigger = {
		religion = secularism
		OR = {
			technology_group = western
			technology_group = asian
		}
		OR = {
			government = socialist_republic
			government = fascist_dictatorship
			government = communist_dictatorship
			government = parliamentary_monarchy
			government = parliamentary_republic
			government = presidental_republic
		}
		any_owned_province = { 
			NOT = { religion = irreligious } 
			NOT = { religion_group = muslim } 
		}
		OR = {
			NOT = { has_faction = conservative_party }
			NOT = { faction_in_power = conservative_party }
		}
	}
	mean_time_to_happen = {
		months = 2400

		modifier = {
			factor = 0.4
			has_faction = liberal_party
			OR = {
				faction_in_power = liberal_party
				faction_in_power = communist_party
				faction_in_power = national_socialist_party
			}
		}
		modifier = {
			factor = 0.6
			any_owned_province = { religion = irreligious }
		}
		modifier = {
			factor = 0.02
			has_country_modifier = state_atheism
		}
	}
	
	option = {
		name = "et.EVTOPTA76"
		random_owned_province = {
			limit = { NOT = { religion = irreligious } NOT = { religion_group = muslim } }
			if = {
				limit = { religion = catholic }
				set_province_flag = traditional_religion_catholic
			}
			if = {
				limit = { religion = orthodox }
				set_province_flag = traditional_religion_orthodox
			}
			if = {
				limit = { religion = protestant }
				set_province_flag = traditional_religion_protestant
			}
			if = {
				limit = { religion = reformed }
				set_province_flag = traditional_religion_reformed
			}
			if = {
				limit = { religion = coptic }
				set_province_flag = traditional_religion_coptic
			}
			if = {
				limit = { religion = mahayana }
				set_province_flag = traditional_religion_mahayana
			}
			if = {
				limit = { religion = vajrayana }
				set_province_flag = traditional_religion_vajrayana
			}
			if = {
				limit = { religion = buddhism }
				set_province_flag = traditional_religion_theravada
			}
			if = {
				limit = { religion = hinduism }
				set_province_flag = traditional_religion_hinduism
			}
			if = {
				limit = { religion = sikhism }
				set_province_flag = traditional_religion_sikhism
			}
			if = {
				limit = { religion = zoroastrian }
				set_province_flag = traditional_religion_zoroastrian
			}
			change_religion = irreligious
		}
	}
}

#Province re-adopts religion
province_event = {

	id = et.77
	title = "et.EVTNAME77"
	desc = "et.EVTDESC77"
	picture = REFORM_eventPicture
	
	trigger = {
		religion = irreligious
		owner = {
			NOT = { has_country_modifier = state_atheism }
			OR = {
				has_country_modifier = state_atheism_abolished
				AND = {
					NOT = { government = socialist_republic }
					NOT = { government = fascist_dictatorship }
					NOT = { government = communist_dictatorship }
					NOT = { government = parliamentary_monarchy }
					NOT = { government = parliamentary_republic }
					NOT = { government = presidental_republic }
				}
			}
		}
		OR = {
			has_province_flag = traditional_religion_catholic
			has_province_flag = traditional_religion_orthodox
			has_province_flag = traditional_religion_protestant
			has_province_flag = traditional_religion_reformed
			has_province_flag = traditional_religion_coptic
			has_province_flag = traditional_religion_mahayana
			has_province_flag = traditional_religion_theravada
			has_province_flag = traditional_religion_vajrayana
			has_province_flag = traditional_religion_hinduism
			has_province_flag = traditional_religion_sikhism
			has_province_flag = traditional_religion_zoroastrian
		}
	}
	mean_time_to_happen = {
		months = 2400

		modifier = {
			factor = 0.05
			owner = { has_country_modifier = state_atheism_abolished }
		}
		modifier = {
			factor = 0.5
			owner = {
				has_faction = conservative_party
				faction_in_power = conservative_party
			}
		}
		modifier = {
			factor = 5
			owner = {
				has_faction = liberal_party
				OR = {
					faction_in_power = liberal_party
					faction_in_power = communist_party
					faction_in_power = national_socialist_party
				}
			}
		}
	}
	
	option = {
		name = "et.EVTOPTA77"
		if = {
			limit = { has_province_flag = traditional_religion_catholic }
			change_religion = catholic
			clr_province_flag = traditional_religion_catholic
		}
		if = {
			limit = { has_province_flag = traditional_religion_orthodox }
			change_religion = orthodox
			clr_province_flag = traditional_religion_orthodox
		}
		if = {
			limit = { has_province_flag = traditional_religion_protestant }
			change_religion = protestant
			clr_province_flag = traditional_religion_protestant
		}
		if = {
			limit = { has_province_flag = traditional_religion_reformed }
			change_religion = reformed
			clr_province_flag = traditional_religion_reformed
		}
		if = {
			limit = { has_province_flag = traditional_religion_coptic }
			change_religion = coptic
			clr_province_flag = traditional_religion_coptic
		}
		if = {
			limit = { has_province_flag = traditional_religion_mahayana }
			change_religion = mahayana
			clr_province_flag = traditional_religion_mahayana
		}
		if = {
			limit = { has_province_flag = traditional_religion_vajrayana }
			change_religion = vajrayana
			clr_province_flag = traditional_religion_vajrayana
		}
		if = {
			limit = { has_province_flag = traditional_religion_theravada }
			change_religion = buddhism
			clr_province_flag = traditional_religion_theravada
		}
		if = {
			limit = { has_province_flag = traditional_religion_hinduism }
			change_religion = hinduism
			clr_province_flag = traditional_religion_hinduism
		}
		if = {
			limit = { has_province_flag = traditional_religion_sikhism }
			change_religion = sikhism
			clr_province_flag = traditional_religion_sikhism
		}
		if = {
			limit = { has_province_flag = traditional_religion_zoroastrian }
			change_religion = zoroastrian
			clr_province_flag = traditional_religion_catholic
		}
	}
}

#Clear Irreligious countries
country_event = {

	id = et.78
	title = "et.EVTNAME78"
	desc = "et.EVTDESC78"
	picture = REFORM_eventPicture
	
	trigger = {
		religion = irreligious
	}
	mean_time_to_happen = {
		months = 2
	}
	
	option = {
		name = "et.EVTOPTA78"
		change_religion = secularism
	}
}
