# If you add religions, and use those tags, do not change them without changing everywhere they are used.

# Uses all 'modifiers' possible thats exported as a Modifier.

christian = {
	defender_of_faith = yes
	can_form_personal_unions = yes
	
	center_of_religion = 118 # Rome

	flags_with_emblem_percentage = 33 # default == 0
	flag_emblem_index_range = { 1 18 }

	chalcedonism = {
		color = { 0.75 0.65 0 }
		icon = 38
		allowed_conversion = {
			arianism
			coptic
			nestorian
		}
		country = {
			stability_cost_modifier = -0.1
			tolerance_own = 1
		}
		
		on_convert = {
			change_religion = chalcedonism
			add_stability = -3
		}
		
		heretic = { BOGOMILIST WALDENSIAN FRATICELLI HUSSITE LOLLARD SOCINIAN }
	}
	
	catholic = {
		color = { 0.8 0.8 0 }
		icon = 1
		allowed_conversion = {
			reformed
			protestant
		}
		country = {
			tolerance_own = 1
			tolerance_heretic = -1
		}
		
		hre_religion = yes
		
		on_convert = {
			change_religion = catholic
			add_prestige = -100
			
			remove_country_modifier = the_test_act
			remove_country_modifier = superintendent_office
			remove_country_modifier = the_popery_act
			
			add_country_modifier = {
				name = "conversion_zeal"
				duration = 3650
			}			
		
		}
		
		heretic = { BOGOMILIST WALDENSIAN FRATICELLI HUSSITE LOLLARD SOCINIAN }
		
		papacy = {
			papal_tag = PAP
			election_cost = 5
			seat_of_papacy = 118 # rome
			
			levy_church_tax = {
				cost = 50
				potential = {
					NOT = { tag = PAP }
				}
				allow = {
					NOT = { war_with = PAP }
					NOT = { has_country_modifier = papal_sanction_for_church_taxes }
				}
				effect = {
					add_country_modifier = {
						name = "papal_sanction_for_church_taxes"
						duration = 7300
					}
				}
				ai_will_do = {
					factor = 1
				}				
			}			
			bless_monarch = {
				cost = 50
				potential = {
					NOT = { tag = PAP }
				}
				allow = {
					NOT = { war_with = PAP }
					NOT = { prestige = 100 }
					NOT = { has_country_modifier = papal_blessing }
				}
				effect = {
					add_country_modifier = {
						name = "papal_blessing"
						duration = 7300
					}
				}
				ai_will_do = {
					factor = 1
				}
			}
			indulgence_for_sins = {
				cost = 50
				potential = {
					government = monarchy
					NOT = { tag = PAP }
				}
				allow = {
					NOT = { war_with = PAP }
					NOT = { legitimacy = 100 }
					NOT = { has_country_modifier = papal_indulgence }
				}
				effect = {
					add_country_modifier = {
						name = "papal_indulgence"
						duration = 7300
					}
				}
				ai_will_do = {
					factor = 1
				}
			}	
			local_saint = {
				cost = 100
				potential = {
					NOT = { tag = PAP }
				}
				allow = {
					NOT = { war_with = PAP }
					NOT = { stability = 3 }
				}
				effect = {
					add_stability = 1
				}
				ai_will_do = {
					factor = 1
					modifier = {
						factor = 2
						NOT = { stability = 0 }
					}
				}
			}
			forgiveness_for_usury = {
				cost = 50
				potential = {
					NOT = { tag = PAP }
				}
				allow = {
					NOT = { war_with = PAP }
					NOT = { has_country_modifier = usury_forgiven }
				}
				effect = {
					add_country_modifier = {
						name = "usury_forgiven"
						duration = 7300
					}
				}
				ai_will_do = {
					factor = 1
					modifier = {
						factor = 0
						NOT = { num_of_loans = 1 }
					}
				}
			}			
			proclaim_holy_war = {
				cost = 50
				potential = {
					NOT = { tag = PAP }
				}
				allow = {
					is_at_war = yes
					NOT = { war_with = PAP }
					NOT = { has_country_modifier = papal_sanction_for_holy_war }
				}
				effect = {
					add_country_modifier = {
						name = "papal_sanction_for_holy_war"
						duration = 7300
					}
				}
				ai_will_do = {
					factor = 1
					modifier = {
						factor = 0
						manpower_percentage = 0.5
					}
				}
			}
			send_papal_legate = {
				cost = 50
				potential = {
					NOT = { tag = PAP }
				}
				allow = {
					NOT = { war_with = PAP }
					NOT = { has_country_modifier = papal_legate }
				}
				effect = {
					add_country_modifier = {
						name = "papal_legate"
						duration = 7300
					}
				}
				ai_will_do = {
					factor = 1
				}
			}	
			sanction_commercial_monopoly = {
				cost = 100
				potential = {
					NOT = { tag = PAP }
				}
				allow = {
					NOT = { war_with = PAP }
				}
				effect = {
					add_mercantilism = 0.01
				}
				ai_will_do = {
					factor = 1
					modifier = {
						factor = 0
						NOT = { has_idea_group = trade_ideas }
					}
				}
			}			
		}

		date = 867.1.1
	}

	protestant = {
		color = { 0 0 0.7 }
		icon = 2

		allowed_conversion = {
			reformed
			catholic
		}
		allowed_center_conversion = {
			catholic
		}
		country = {
			global_tax_modifier = 0.1
			tolerance_own = 1
		}
		
		uses_church_power = yes				# Uses church power/aspect mechanics
		aspects = {
			organised_through_bishops_aspect
			priests_may_marry_aspect
			adult_baptism_aspect
			holy_sacraments_aspect
			saints_accept_prayers_aspect
			icons_images_aspect
			legalised_divorces_aspect
			heretics_deported_aspect
			parish_registers_aspect
			individual_creeds_aspect
			allow_usury_aspect
			translated_bibles_aspect
		}
		
		hre_heretic_religion = yes
		
		will_get_center = {
			any_owned_province = {
				OR = {
					religion = protestant
					religion = catholic
					religion = reformed
				}
				not = { province_id = 118 }
				is_in_capital_area = yes
				is_reformation_center = no
			}
		}

		on_convert = {
			change_religion = protestant
			add_prestige = -100
			remove_country_modifier = counter_reformation
			remove_country_modifier = the_statue_in_restraint_of_appeals
			remove_country_modifier = bavarian_jesuits
			remove_country_modifier = the_societas_jesu
			remove_country_modifier = the_declaration_of_indulgence
			remove_country_modifier = de_heretico_comburendo
			remove_country_modifier = the_conventicle_act
	
			if = {
				limit = {
					has_country_flag = reformation_money
				}
				random_owned_province = {
					limit = {
						OR = {
							religion = protestant
							religion = catholic
							religion = reformed
						}
						is_in_capital_area = yes
						is_reformation_center = no
						not = { province_id = 118 }
					}
					change_religion = protestant
					add_reform_center = protestant
				}
			}	
			if = {
				limit = {
					NOT = { has_country_flag = reformation_money }
				}
				add_years_of_income = 1.0
				random_owned_province = {
					limit = {
						OR = {
							religion = protestant
							religion = catholic
							religion = reformed
						}
						is_in_capital_area = yes
						is_reformation_center = no
						not = { province_id = 118 }
					}
					change_religion = protestant
					add_reform_center = protestant
				}
			}
			
			add_country_modifier = {
				name = "conversion_zeal"
				duration = 3650
			}			
			set_country_flag = reformation_money
			every_known_country = {
				limit = {
					reverse_has_opinion_modifier = {
						who = ROOT
						modifier = opinion_demote_pope
					}
				}
				reverse_remove_opinion = {
					who = ROOT
					modifier = opinion_demote_pope
				}
			}
		}
		
		heretic = { PENTECOSTAL PURITAN CONGREGATIONALIST }
		
		date = 1517.10.31
	}

	reformed = {
		color = { 0.3 0.3 0.9 }
		icon = 3
		allowed_conversion = {
			protestant
			catholic
		}
		allowed_center_conversion = {
			catholic
		}
		country = {
			tolerance_heretic = 2
			advisor_pool = 1
		}

		will_get_center = {
			any_owned_province = {
				OR = {
					religion = protestant
					religion = catholic
					religion = reformed
				}
				not = { province_id = 118 }
				is_in_capital_area = yes
				is_reformation_center = no
			}
		}
		
		on_convert = {
			change_religion = reformed
			add_prestige = -100
			remove_country_modifier = counter_reformation
			remove_country_modifier = the_statue_in_restraint_of_appeals
			remove_country_modifier = bavarian_jesuits
			remove_country_modifier = the_societas_jesu
			remove_country_modifier = the_declaration_of_indulgence
			remove_country_modifier = de_heretico_comburendo
			remove_country_modifier = the_conventicle_act
			
			if = {
				limit = {
					has_country_flag = reformation_money
				}
				random_owned_province = {
					limit = {
						OR = {
							religion = protestant
							religion = catholic
							religion = reformed
						}
						not = { province_id = 118 }
						is_in_capital_area = yes
						is_reformation_center = no
					}
					change_religion = reformed
					add_reform_center = reformed
				}
			}	
			if = {
				limit = {
					NOT = { has_country_flag = reformation_money }
				}
				add_years_of_income = 1.0
				random_owned_province = {
					limit = {
						OR = {
							religion = protestant
							religion = catholic
							religion = reformed
						}
						is_in_capital_area = yes
						is_reformation_center = no
						not = { province_id = 118 }
					}
					change_religion = reformed
					add_reform_center = reformed
				}
			}
			add_country_modifier = {
				name = "conversion_zeal"
				duration = 3650
			}			
			set_country_flag = "reformation_money"
			every_known_country = {
				limit = {
					reverse_has_opinion_modifier = {
						who = ROOT
						modifier = opinion_demote_pope
					}
				}
				reverse_remove_opinion = {
					who = ROOT
					modifier = opinion_demote_pope
				}
			}
		}
		
		heretic = { METHODIST BAPTIST QUAKER }
		
		date = 1536.5.1
		
		fervor = yes
	}

	orthodox = {
		color = { 0.7 0.5 0 }
		icon = 4

		country = {
			stability_cost_modifier = -0.1
			tolerance_own = 1
		}

		on_convert = {
			change_religion = orthodox
			add_stability = -3
		}

		province = {
			local_missionary_strength = -0.01
		}
		heretic = { OLD_BELIEVER MOLOKAN DUKHOBOR KHLYST SKOPTSY ICONOCLAST }
		
		has_patriarchs = yes		# Uses patriarch authority
		misguided_heretic = yes		#other christians hate them less

		date = 867.1.1
	}

	coptic = {
		color = { 0.7 0.5 0.5 }
		icon = 5
		allowed_conversion = {
			chalcedonism
			nestorian
			arianism
		}
		country = {
			defensiveness = 0.1
			tolerance_own = 2
		}
		on_convert = {
			change_religion = coptic
			add_stability = -3
		}
		province = {
			local_missionary_strength = -0.02
		}
		
		heretic = { ZAMIKAELITES STEPHANITES EUSTATHIANS }
		
		misguided_heretic = yes		# Other christians hate them less (?)

		date = 451.11.1
	}

	nestorian = {
		color = { 0.6 0.6 0 }
		icon = 6
		allowed_conversion = {
			chalcedonism
			arianism
			coptic
		}
		country = {
			stability_cost_modifier = -0.1
			tolerance_own = 1
		}
		on_convert = {
			change_religion = nestorian
			add_stability = -3
		}

		heretic = { ZAMIKAELITES STEPHANITES EUSTATHIANS }

		misguided_heretic = yes		# Other christians hate them less (?)

		date = 431.7.1
	}

	arianism = {
		color = { 0.4 0.4 0 }
		icon = 7
		allowed_conversion = {
			chalcedonism
			nestorian
			coptic
		}
		country = {
			global_tax_modifier = 0.1
			idea_cost = -0.1
		}
		on_convert = {
			change_religion = arianism
			add_stability = -3
		}
		
		heretic = { BOGOMILIST WALDENSIAN HUSSITE LOLLARD SOCINIAN }

		date = 325.1.1
	}
	
	crusade_name = CRUSADE
}

muslim = {
	defender_of_faith = yes

	center_of_religion = 385 # Mecca

	flags_with_emblem_percentage = 33
	flag_emblem_index_range = { 19 24 }
	
	sunni = {
		color = { 0 0.6 0 }
		icon = 8
		province = {
			local_missionary_strength = -0.01
		}
		country = {
			tolerance_own = 1
			heir_chance = 1.0
		}
		
		heretic = { BEKTASHI AHMADI ZIKRI YAZIDI }
		
		uses_piety = yes				# Uses piety mechanics

		date = 627.1.1
	}

	shiite = {
		color = { 0 0.8 0 }
		icon = 9
		province = {
			local_missionary_strength = -0.01
		}
		country = {
			heir_chance = 1.0
			land_morale = 0.10
		}
		
		heretic = { DRUZE HURUFI ZAIDI }
		
		uses_piety = yes				# Uses piety mechanics
	}

	ibadi = {
		color = { 0 0.4 0 }
		icon = 10
		country = {
			heir_chance = 1.0
			naval_morale = 0.1
		}
		province = {
			local_missionary_strength = -0.01
		}
		
		heretic = { HARURI SUFRI NAJADAT AZRAQI }
		
		uses_piety = yes				# Uses piety mechanics

		date = 690.1.1
	}
	
	crusade_name = JIHAD
}

buddhic = {

	flags_with_emblem_percentage = 33
	flag_emblem_index_range = { 25 31 }

	vajrayana = {
		color = { 0.8 0.3 0.3 }
		icon = 46
		allowed_conversion = {
			mahayana
			theravada
		}
		country = {
			tolerance_heretic = 1
			land_morale = 0.1
		}
		on_convert = {
			change_religion = vajrayana
			add_prestige = -100
			
			add_country_modifier = {
				name = "conversion_zeal"
				duration = 3650
			}
		}
		
		heretic = { ZEN }

		uses_karma = yes

		date = 630.1.1
	}

	mahayana = {
		color = { 0.8 0.3 0.5 }
		icon = 44
		allowed_conversion = {
			vajrayana
			tharavada
		}
		country = {
			tolerance_heretic = 2
			tolerance_heathen = 1
		}
		on_convert = {
			change_religion = mahayana
			add_prestige = -100
			
			add_country_modifier = {
				name = "conversion_zeal"
				duration = 3650
			}
		}
		
		heretic = { ZEN }

		uses_karma = yes
	}

	buddhism = { #Theravada
		color = { 0.8 0.3 0 }
		icon = 45
		allowed_conversion = {
			vajrayana
			mahayana
		}
		country = {
			tolerance_heretic = 2
			advisor_cost = -0.1
		}
		on_convert = {
			change_religion = theravada
			add_prestige = -100
			
			add_country_modifier = {
				name = "conversion_zeal"
				duration = 3650
			}
		}
		
		heretic = { ZEN }

		uses_karma = yes
	}

	crusade_name = CRUSADE
}

dharmic = {

	flags_with_emblem_percentage = 33
	flag_emblem_index_range = { 25 31 }

	hinduism = {
		color = { 0 0.8 0.8 }
		icon = 12
		allowed_conversion = {
			sikhism
			jainism
		}
		country = {
			tolerance_heathen = 1
			tolerance_own = 1
		}

		personal_deity = yes

		on_convert = {
			change_religion = hinduism
			add_prestige = -100
			
			add_country_modifier = {
				name = "conversion_zeal"
				duration = 3650
			}
		}
		
		heretic = { BHAKTI }
	}

	sikhism = {
		color = { 0 0.6 0.6 }
		icon = 13
		allowed_conversion = {
			hinduism
			jainism
		}
		country = {
			mil_tech_cost_modifier = -0.05
			land_morale = 0.1
		}
		province = {
			local_missionary_strength = -0.01
		}

		on_convert = {
			change_religion = sikhism
			add_prestige = -100
			
			add_country_modifier = {
				name = "conversion_zeal"
				duration = 3650
			}
		}
		
		heretic = { MASANDIS }

		date = 1499.01.01
	}

	jainism = {
		color = { 0.5 0.9 0.9 }
		icon = 14
		allowed_conversion = {
			hinduism
			sikhism
		}
		country = {
			global_tax_modifier = 0.05
			tolerance_heretic = 3
		}
		on_convert = {
			change_religion = jainism
			add_prestige = -100

			add_country_modifier = {
				name = "conversion_zeal"
				duration = 3650
			}
		}
		
		heretic = { BHAKTI }
	}

	zunism = {
		color = { 0.9 0.9 0.6 }
		icon = 41
		province = {
			local_missionary_strength = 0.02
		}
		country = {
			land_morale = 0.10
			defensiveness = 0.2
		}

		heretic = { BHAKTI }
	}

	crusade_name = CRUSADE
}

eastern = {

	flags_with_emblem_percentage = 33
	flag_emblem_index_range = { 25 31 }

	confucianism = {
		color = { 0.84 0.9 0.55 }
		icon = 15
		country = {
			tolerance_heretic = 2
			tolerance_heathen = 1
		}
		
		heretic = { TAOIST }
	}

	shinto = {
		color = { 0.8 0 0 }
		icon = 16
		province = {
			local_missionary_strength = -0.01
		}
		country = {
			land_morale = 0.1
			tolerance_heathen = -1
		}
		
		heretic = { SHUGENDO }

		date = 712.1.1
	}

	tibetan_bon = {
		color = { 0 0.4 0.4 }
		icon = 47
		province = {
			local_missionary_strength = 0.01
		}
		country = {
			land_morale = 0.1
			tolerance_heathen = 1
		}
		
		heretic = { SHUGENDO }
	}

	muism = {
		color = { 0.6 0.6 0.2 }
		icon = 48
		province = {
			local_missionary_strength = -0.01
		}
		country = {
			tolerance_heretic = 2
			tolerance_heathen = 1
		}
		
		heretic = { TAOIST }
	}
	
	crusade_name = CRUSADE
}

pagan = {

	flags_with_emblem_percentage = 10
	flag_emblem_index_range = { 17 18 }

	animism = {
		color = { 0.5 0.0 0.0 }
		icon = 17
		province = {
			local_missionary_strength = 0.02
		}
		country = {
			tolerance_own = 1
			global_unrest = -1
		}
		
		heretic = { BEAR_SPIRIT SNAKE_CLAN }
		
		annex = yes
	}
	
	shamanism = {
		color = { 0.5 0.3 0.3 }
		icon = 18
		province = {
			local_missionary_strength = 0.02
		}
		country = {
			tolerance_own = 1
			global_unrest = -1
		}
		
		heretic = { GOAT_SKULL }
		
		annex = yes		
	}
	
	crusade_name = CRUSADE
}
