# DO NOT ALTER THE NAME OR NUMBER OF THESE!

succession_laws = {

	succ_gavelkind = {
		oldest_child_opinion = -5
		child_opinion = 15
		dynasty_opinion = 5
		vassal_opinion = 5

		potential = {
			NOR = {
				has_law = succ_military_elective
				title = k_shadowrealm
				title = k_horned_church
				title = e_bretonnia
				holder_scope = {
					has_landed_title = k_horned_church
				}
			}
			holder_scope = {
				OR = {
					independent = yes
					NOT = {
						any_liege = {
							holy_order = yes
						}
					}
				}
				NOR = {
					religion_group = ormazd_gods_group
					religion_group = necromantic_group
					culture_group = lizardman_group
					religion_group = greenskin_gods
					culture = cathayan
					trait = creature_beastman
					trait = in_matriheritage
					is_vampire_visible_trigger = yes
					is_merchant_republic = yes
					is_patrician = yes
				}
				OR = {
					independent = yes
					NOT = {
						any_demesne_title = {
							is_vice_royalty = yes
						}
					}
				}
			}
			OR = {
				is_landless_type_title = no
				is_tribal_type_title = yes
				temporary = yes
				AND = { #Big Clans
					higher_tier_than = DUKE
					holder_scope = { culture_group = skaven_group }
				}
			}

			rebel = no

			OR = {
				AND = {
					tier = BARON
					OR = {
						is_feudal = yes
						is_tribal = yes
					}
				}
				holder_scope = { is_feudal = yes }
				holder_scope = { is_tribal = yes }
			}
			is_primary_type_title = no
		}
		allow = {
			OR = {
				custom_tooltip = {
					text = "Is not a High Elf"
					NOT = {	holder_scope = { culture_group = asur_group } }
				}
				custom_tooltip = {
					text = "The High Elves do not change the laws of Ulthuan."
					NOT = { title = e_ulthuan }
					holder_scope = { culture_group = asur_group }
				}
			}
			holder_scope = {
				show_scope_change = no
				OR = {
					is_tribal = no
					custom_tooltip = {
						text = TT_NOT_UNREFORMED_PAGAN
						hidden_tooltip = {
							NOR = {
									culture_group = lizardman_group
									religion = norscan_gods
									religion = northern_gods
									religion = northern_gods_reformed
							}
						}
					}
				}
				in_revolt = no
			}
			conditional_tooltip = {
				trigger = {
					has_law = succ_hre_elective
					has_dlc = "Conclave"
					}
				has_law = law_voting_power_0
			}
			conditional_tooltip = {
				trigger = {
					has_law = succ_hre_elective
					NOT = { has_dlc = "Conclave" }
				}
				has_law = crown_authority_4
			}
			conditional_tooltip = {
				trigger = {
					has_law = succ_hre_elective
				}
				has_law = centralization_4
			}
			conditional_tooltip = {
				trigger = {
					has_dlc = "Conclave"
				}
				custom_tooltip = {
					text = forced_elective_tt
					hidden_tooltip = {
						NAND = {
							has_law = succession_voting_power_1
							OR = {
								has_law = succ_feudal_elective
								has_law = succ_hre_elective
							}
						}
					}
				}
			}
		}
		effect = {
			succession = gavelkind
		}
	}

	succ_elective_gavelkind = {
		child_opinion = 15
		dynasty_opinion = 5

		potential = {
			NOR = {
				has_law = succ_military_elective
				title = k_shadowrealm
				title = k_horned_church
				title = e_bretonnia
			}
			holder_scope = {
				is_nomadic = no
				OR = {
					independent = yes
					NOT = {
						any_liege = {
							holy_order = yes
						}
					}
				}
				NOR = {
					religion_group = necromantic_group
					religion_group = ormazd_gods_group
					culture_group = lizardman_group
					culture_group = skaven_group
					trait = creature_nehekharan
					trait = creature_orc
					trait = creature_goblin
					trait = creature_hobgoblin
					trait = creature_fimir
					culture = cathayan
					trait = in_matriheritage
					is_merchant_republic = yes
					is_patrician = yes
				}
				OR = {
					independent = yes
					NOT = {
						any_demesne_title = {
							is_vice_royalty = yes
						}
					}
				}
			}
			OR = {
				is_landless_type_title = no
				is_tribal_type_title = yes
				temporary = yes
			}

			rebel = no

			OR = {
				AND = {
					tier = BARON
					OR = {
						is_feudal = yes
						is_tribal = yes
					}
				}
				holder_scope = { is_feudal = yes }
				holder_scope = { is_tribal = yes }
			}
			is_primary_type_title = no
		}
		allow = {
			OR = {
				custom_tooltip = {
					text = "Is not a High Elf"
					NOT = {	holder_scope = { culture_group = asur_group } }
				}
				custom_tooltip = {
					text = "The High Elves do not change the laws of Ulthuan."
					NOT = { title = e_ulthuan }
					holder_scope = { culture_group = asur_group }
				}
			}
			conditional_tooltip = {
				trigger = {
					has_dlc = "Conclave"
				}
				custom_tooltip = {
					text = forced_elective_tt
					hidden_tooltip = {
						NAND = {
							has_law = succession_voting_power_1
							OR = {
								has_law = succ_feudal_elective
								has_law = succ_hre_elective
							}
						}
					}
				}
			}
			holder_scope = {
				show_scope_change = no
				in_revolt = no
			}
			conditional_tooltip = {
				trigger = {
					has_law = succ_hre_elective
					has_dlc = "Conclave"
				}
				has_law = law_voting_power_0
			}
			conditional_tooltip = {
				trigger = {
					has_law = succ_hre_elective
					NOT = { has_dlc = "Conclave" }
				}
				has_law = crown_authority_4
			}
			conditional_tooltip = {
				trigger = {
					has_law = succ_hre_elective
				}
				has_law = centralization_4
			}
		}
		effect = {
			succession = {
				base_type = elective_gavelkind
				voting_rules = elective_gavelkind
			}
		}
	}

	succ_eldership = {
		dynasty_opinion = 5

		potential = {
			NOT={
				has_law = succ_military_elective
			}
			NAND = {
				has_law = succ_byzantine_elective
				holder_scope = {
					OR = {
						has_landed_title = e_tilea
						has_landed_title = e_estalia
						has_landed_title = e_eternal_empire
					}
				}
			}
			holder_scope = {
				OR = {
					culture=ropsmann
					has_religion_feature = religion_beatification
					has_religion_feature = religion_feature_west_african
				}
			}
			holder_scope = {
				has_dlc = "Holy Fury"
				is_nomadic = no
				OR = {
					independent = yes
					NOT = {
						any_liege = {
							holy_order = yes
						}
					}
				}
				NOR = {
					has_religion_feature = religion_matriarchal
					has_religion_feature = religion_patriarchal
				}
				is_merchant_republic = no
				is_patrician = no
				OR = {
					independent = yes
					NOT = {
						any_demesne_title = {
							is_vice_royalty = yes
						}
					}
				}
			}
			OR = {
				is_landless_type_title = no
				is_tribal_type_title = yes
				temporary = yes
			}

			rebel = no

			OR = {
				holder_scope = { is_feudal = yes }
				holder_scope = { is_tribal = yes }
			}
			is_primary_type_title = no
		}
		allow = {
			conditional_tooltip = {
				trigger = {
					has_dlc = "Holy Fury"
				}
				holder_scope = {
					OR = {
						culture=ropsmann
						has_religion_feature = religion_beatification
						has_religion_feature = religion_feature_west_african
					}
				}
				custom_tooltip = {
					text = forced_elective_tt
					hidden_tooltip = {
						NAND = {
							has_law = succession_voting_power_1
							OR = {
								has_law = succ_feudal_elective
								has_law = succ_hre_elective
							}
						}
					}
				}
			}
			holder_scope = {
				show_scope_change = no
				in_revolt = no
			}
		}
		effect = {
			succession = {
				base_type = tanistry
				voting_rules = eldership_rules
			}
			elective_voting_rules = eldership_rules
		}
	}

	succ_seniority = {
		vassal_opinion = -5
		oldest_child_opinion = -15
		child_opinion = -10
		dynasty_opinion = 5

		potential = {
			NOR = {
				has_law = succ_military_elective
				title = k_shadowrealm
				title = k_horned_church
				title = e_bretonnia
			}
			holder_scope = {
				OR = {
					independent = yes
					NOT = {
						any_liege = {
							holy_order = yes
						}
					}
				}
				OR = {
					is_merchant_republic = no
					primary_title = {
						NOT = { title = PREVPREV }
					}
				}
				NOR = {
					religion_group = necromantic_group
					culture_group = lizardman_group
					culture_group = skaven_group
					trait = creature_beastman
					trait = creature_nehekharan
					trait = creature_orc
					trait = creature_goblin
					trait = creature_hobgoblin
					trait = creature_fimir
					trait = in_matriheritage
				}
				OR = {
					is_republic = no
					is_patrician = yes
				}
				OR = {
					independent = yes
					NOT = {
						any_demesne_title = {
							is_vice_royalty = yes
						}
					}
				}
			}
			OR = {
				is_landless_type_title = no
				is_tribal_type_title = yes
				temporary = yes
			}
			OR = {
				AND = {
					tier = BARON
					is_feudal = yes
				}
				holder_scope = { is_feudal = yes }
				holder_scope = { is_patrician = yes }
			}

			is_primary_type_title = no

			OR = {
				NOT = { tier = BARON }
				holder_scope = { is_patrician = yes }
			}
		}

		allow = {
			OR = {
				custom_tooltip = {
					text = "Is not a High Elf"
					NOT = {	holder_scope = { culture_group = asur_group } }
				}
				custom_tooltip = {
					text = "The High Elves do not change the laws of Ulthuan."
					NOT = { title = e_ulthuan }
					holder_scope = { culture_group = asur_group }
				}
			}
			conditional_tooltip = {
				trigger = {
					NOT = { has_dlc = "Conclave" }
					NOT = { has_law = succ_hre_elective }
				}
				OR = {
					hidden_tooltip = {
						has_crown_law_title = no
					}
					holder_scope = {
						show_scope_change = no
						is_patrician = yes
						OR = {
							is_merchant_republic = no
							PREV = {
								is_primary_holder_title = no
							}
							NOT = {
								in_revolt = yes
								succ_law_title = {
									title = PREVPREV
								}
							}
						}
					}
					crownlaw_title = {
						OR = {
							has_law = crown_authority_2
							has_law = crown_authority_3
							has_law = crown_authority_4
							has_law = imperial_crown_authority_2
							has_law = imperial_crown_authority_3
							has_law = imperial_crown_authority_4
						}
					}
				}
			}
			custom_tooltip = {
				text = not_forced_tt
				hidden_tooltip = {
					holder_scope = { NOT = { has_character_flag = liege_forced_succ_law } }
				}
			}
			conditional_tooltip = {
				trigger = {
					has_dlc = "Conclave"
				}
				custom_tooltip = {
					text = forced_elective_tt
					hidden_tooltip = {
						NAND = {
							has_law = succession_voting_power_1
							OR = {
								has_law = succ_feudal_elective
								has_law = succ_hre_elective
							}
						}
					}
				}
			}
			conditional_tooltip = {
				trigger = {
					has_law = succ_hre_elective
					has_dlc = "Conclave"
				}
				has_law = law_voting_power_0
			}
			conditional_tooltip = {
				trigger = {
					has_law = succ_hre_elective
					NOT = { has_dlc = "Conclave" }
				}
				has_law = crown_authority_4
			}
			conditional_tooltip = {
				trigger = {
					has_law = succ_hre_elective
				}
				has_law = centralization_4
			}
		}

		effect = {
			succession = seniority
		}
	}

	succ_primogeniture = {
		oldest_child_opinion = 10
		youngest_child_opinion = -15
		child_opinion = -10
		dynasty_opinion = -5
		potential = {
			NOR = {
				has_law = succ_military_elective
				title = k_shadowrealm
				title = k_horned_church
				title = e_bretonnia
			}
			holder_scope = {
				NOR = {
					religion_group = necromantic_group
					religion_group = ormazd_gods_group
					culture_group = lizardman_group
					culture_group = skaven_group
					trait = creature_beastman
					trait = creature_nehekharan
					trait = creature_orc
					trait = creature_goblin
					trait = creature_hobgoblin
					trait = creature_fimir
					is_merchant_republic = yes
					is_patrician = yes
				}
			}
			OR = {
				holder_scope = { # Viceroyalties can always have primogeniture if not Ormazd
					any_demesne_title = {
						is_vice_royalty = yes
					}
				}
				AND = {
					holder_scope = {
						OR = {
							independent = yes
							NOT = {
								any_liege = {
									holy_order = yes
								}
							}
						}
						OR = {
							NOT = { religion_group = chaos_gods_group }
							is_reformed_religion = yes
						}
					}
					OR = {
						is_landless_type_title = no
						is_tribal_type_title = yes
						temporary = yes
					}
					is_primary_type_title = no
					OR = {
						AND = {
							tier = BARON
							is_feudal = yes
						}
						holder_scope = { is_feudal = yes }
					}
				}
			}
		}
		allow = {
			OR = {
				custom_tooltip = {
					text = "Is not a High Elf"
					NOT = {	holder_scope = { culture_group = asur_group } }
				}
				custom_tooltip = {
					text = "The High Elves do not change the laws of Ulthuan."
					NOT = { title = e_ulthuan }
					holder_scope = { culture_group = asur_group }
				}
			}
			conditional_tooltip = {
				trigger = {
					has_dlc = "Conclave"
				}
				OR = {
					holder_scope = { # Viceroyalties can always have primogeniture if not muslim
						show_scope_change = no
						any_demesne_title = {
							is_vice_royalty = yes
						}
					}
					holder_scope = {
						show_scope_change = no
						primary_title = {
							show_scope_change = no
							OR = {
								has_law = ze_administration_laws_1
								has_law = ze_administration_laws_2
							}
						}
					}
				}
			}
			conditional_tooltip = {
				trigger = {
					NOT = { has_dlc = "Conclave" }
					NOT = { has_law = succ_hre_elective }
				}
				OR = {
					holder_scope = { # Viceroyalties can always have primogeniture if not muslim
						show_scope_change = no
						any_demesne_title = {
							is_vice_royalty = yes
						}
					}
					hidden_tooltip = {
						has_crown_law_title = no
					}
					crownlaw_title = {
						OR = {
							has_law = crown_authority_3
							has_law = crown_authority_4
							has_law = imperial_crown_authority_3
							has_law = imperial_crown_authority_4
						}
					}
				}
			}
			custom_tooltip = {
				text = not_forced_tt
				hidden_tooltip = {
					holder_scope = { NOT = { has_character_flag = liege_forced_succ_law } }
				}
			}
			conditional_tooltip = {
				trigger = {
					has_dlc = "Conclave"
				}
				custom_tooltip = {
					text = forced_elective_tt
					hidden_tooltip = {
						NAND = {
							has_law = succession_voting_power_1
							OR = {
								has_law = succ_feudal_elective
								has_law = succ_hre_elective
							}
						}
					}
				}
			}
			conditional_tooltip = {
				trigger = {
					has_law = succ_hre_elective
					has_dlc = "Conclave"
				}
				has_law = law_voting_power_0
			}
			conditional_tooltip = {
				trigger = {
					has_law = succ_hre_elective
					NOT = { has_dlc = "Conclave" }
				}
				OR = {
					has_law = crown_authority_4
					has_law = imperial_crown_authority_4
				}
			}
			conditional_tooltip = {
				trigger = {
					has_law = succ_hre_elective
				}
				has_law = centralization_4
			}
		}

		effect = {
			succession = primogeniture
		}
	}

	succ_feudal_elective = {
		oldest_child_opinion = -15
		child_opinion = -5
		dynasty_opinion = -5
		vassal_opinion = 10
		potential = {
			NOR = {
				has_law = succ_military_elective
				title = k_horned_church
				title = e_bretonnia
				title = k_zharrduk
			}
			holder_scope = {
				OR = {
					independent = yes
					NOT = {
						any_liege = {
							holy_order = yes
						}
					}
				}
				OR = {
					NOT = {	religion_group = ormazd_gods_group }
					has_law = succession_voting_power_1
					OR = {
						has_law = succ_feudal_elective # Keep it even if you revoke Full Council Authority
						has_law = succ_hre_elective
					}
					ROOT = {
						has_title_flag = alternate_hre
					}
				}
				NOR = {
					religion_group = necromantic_group
					religion_group = ormazd_gods_group
					culture_group = skaven_group
					culture_group = lizardman_group
					trait = creature_beastman
					trait = creature_nehekharan
					trait = creature_orc
					trait = creature_goblin
					trait = creature_hobgoblin
					trait = creature_fimir
					culture = cathayan
					trait = in_matriheritage
				}
				is_merchant_republic = no
				is_patrician = no

				OR = {
					NOT = { religion_group = chaos_gods_group }
					is_reformed_religion = yes
					religion = norscan_gods
					has_law = succession_voting_power_1
					OR = {
						has_law = succ_feudal_elective # Keep it even if you revoke Full Council Authority
						has_law = succ_hre_elective
					}
					ROOT = {
						has_title_flag = alternate_hre
					}
				}
				OR = {
					independent = yes
					NOT = {
						any_demesne_title = {
							is_vice_royalty = yes
						}
					}
				}
			}
			OR = {
				is_landless_type_title = no
				is_tribal_type_title = yes
				temporary = yes
			}
			is_primary_type_title = no
			NOT = { tier = BARON }
			holder_scope = {
				OR = {
					is_feudal = yes
					has_law = succession_voting_power_1
					OR = {
						has_law = succ_feudal_elective # Keep it even if you revoke Full Council Authority
						has_law = succ_hre_elective
					}
					ROOT = {
						has_title_flag = alternate_hre
					}
				}
			}
			NOR = {  #Special Elective.
				title = e_the_empire
				has_title_flag = alternate_hre
			}
		}
		allow = {
			custom_tooltip = {
				text = not_forced_tt
				hidden_tooltip = {
					holder_scope = { NOT = { has_character_flag = liege_forced_succ_law } }
				}
			}
		}
		effect = {
			succession = {
				base_type = feudal_elective
				voting_rules = feudal_elective
			}
		}
	}
	succ_hre_elective = {
		oldest_child_opinion = -15
		child_opinion = -5
		dynasty_opinion = -5
		vassal_opinion = 15
		vassal_limit = 20
		potential = {
			OR = {
				title = e_the_empire #Title-bound.
				ROOT = {
					has_title_flag = alternate_hre
				}
			}
			holder_scope = {
				religion_group = old_world_group
				OR = {
					independent = yes
					NOT = {
						any_liege = {
							holy_order = yes
						}
					}
				}
				OR = {
					NOT = {	religion_group = ormazd_gods_group }
					has_law = succession_voting_power_1
					has_law = succ_feudal_elective # Keep it even if you revoke Full Council Authority
					has_law = succ_hre_elective
					ROOT = {
						has_title_flag = alternate_hre
					}
				}
				is_merchant_republic = no
				is_patrician = no

				OR = {
					NOT = { religion_group = chaos_gods_group }
					is_reformed_religion = yes
					#religion = hellenic_pagan
					has_law = succession_voting_power_1
					has_law = succ_feudal_elective # Keep it even if you revoke Full Council Authority
					has_law = succ_hre_elective
					ROOT = {
						has_title_flag = alternate_hre
					}
				}
				OR = {
					independent = yes
					NOT = {
						any_demesne_title = {
							is_vice_royalty = yes
						}
					}
				}
			}
			OR = {
				is_landless_type_title = no
				is_tribal_type_title = yes
				temporary = yes
			}
			is_primary_type_title = no
			NOT = { tier = BARON }
			holder_scope = {
				OR = {
					is_feudal = yes
					has_law = succession_voting_power_1
					has_law = succ_feudal_elective # Keep it even if you revoke Full Council Authority
					has_law = succ_hre_elective
					ROOT = {
						has_title_flag = alternate_hre
					}
				}
			}
		}
		allow = {
			custom_tooltip = {
				text = not_forced_tt
				hidden_tooltip = {
					holder_scope = { NOT = { has_character_flag = liege_forced_succ_law } }
				}
			}
		}
		effect = {
			succession = {
				base_type = feudal_elective
				voting_rules = hre_feudal_elective
			}
		}
	}

	succ_byzantine_elective = {
		oldest_child_opinion = -5
		child_opinion = -5
		dynasty_opinion = -5
		feudal_opinion = -5
		potential = {
			holder_scope = {
				OR = {
					has_landed_title = e_tilea
					has_landed_title = e_estalia
					has_landed_title = e_eternal_empire
				}
				NOT = { religion_group = ormazd_gods_group }
				is_nomadic = no
				is_merchant_republic = no
				is_patrician = no
			}
		}
		allow = {
			custom_tooltip = {
				text = not_forced_tt
				hidden_tooltip = {
					holder_scope = { NOT = { has_character_flag = liege_forced_succ_law } }
				}
			}
		}
		effect = {
			succession = {
				base_type = feudal_elective
				voting_rules = byzantine_elective
			}
		}
	}

	succ_tanistry = {
		oldest_child_opinion = -20
		child_opinion = -10
		dynasty_opinion = 5
		vassal_opinion = 5
		potential = {
			NOR = {
				has_law = succ_military_elective
				title = k_shadowrealm
				title = k_horned_church
				title = e_bretonnia
			}
			holder_scope = {
				OR = {
					independent = yes
					NOT = {
						any_liege = {
							holy_order = yes
						}
					}
				}
				NOR = {
					religion_group = necromantic_group
					religion_group = ormazd_gods_group
					culture_group = lizardman_group
					culture_group = skaven_group
					trait = creature_beastman
					trait = creature_nehekharan
					trait = creature_orc
					trait = creature_goblin
					trait = creature_hobgoblin
					trait = creature_fimir
					culture = cathayan
					trait = in_matriheritage
					is_merchant_republic = yes
					is_patrician = yes
				}
				OR = {
					culture_group = albion_group
					any_owned_bloodline = {
						has_bloodline_flag = bloodline_tanistry
					}
				}
				OR = {
					independent = yes
					NOT = {
						any_demesne_title = {
							is_vice_royalty = yes
						}
					}
				}
			}
			OR = {
				is_landless_type_title = no
				is_tribal_type_title = yes
				temporary = yes
			}
			is_primary_type_title = no
			NOT = { tier = BARON }
			OR = {
				holder_scope = {
					OR = {
						culture_group = albion_group
						any_owned_bloodline = {
							has_bloodline_flag = bloodline_tanistry
						}
					}
				}
				AND = {
					tier = BARON
					is_feudal = yes
				}
				holder_scope = { is_feudal = yes }
			}
			#NOT = { holder_scope = { government = confucian_bureaucracy } }
			NOT = { holder_scope = { government = celestial_empire_government } }

		}
		allow = {
			OR = {
				custom_tooltip = {
					text = "Is not a High Elf"
					NOT = {	holder_scope = { culture_group = asur_group } }
				}
				custom_tooltip = {
					text = "The High Elves do not change the laws of Ulthuan."
					NOT = { title = e_ulthuan }
					holder_scope = { culture_group = asur_group }
				}
			}
			OR = {
				holder_scope = { is_feudal = yes }
				holder_scope = { is_tribal = yes }
			}
			custom_tooltip = {
				text = not_forced_tt
				hidden_tooltip = {
					holder_scope = { NOT = { has_character_flag = liege_forced_succ_law } }
				}
			}
			conditional_tooltip = {
				trigger = {
					has_dlc = "Conclave"
				}
				custom_tooltip = {
					text = forced_elective_tt
					hidden_tooltip = {
						NAND = {
							has_law = succession_voting_power_1
							OR = {
								has_law = succ_feudal_elective
								has_law = succ_hre_elective
							}
						}
					}
				}
			}
			conditional_tooltip = {
				trigger = {
					has_law = succ_hre_elective
					has_dlc = "Conclave"
				}
				has_law = law_voting_power_0
			}
			conditional_tooltip = {
				trigger = {
					has_law = succ_hre_elective
					NOT = { has_dlc = "Conclave" }
				}
				has_law = crown_authority_4
			}
			conditional_tooltip = {
				trigger = {
					has_law = succ_hre_elective
				}
				has_law = centralization_4
			}
		}
		effect = {
			succession = {
				base_type = tanistry
				voting_rules = tanistry
			}
		}
	}

	succ_ultimogeniture = {
		youngest_child_opinion = 10
		oldest_child_opinion = -15
		child_opinion = -10
		dynasty_opinion = -5
		potential = {
			NOR = {
				has_law = succ_military_elective
				title = k_shadowrealm
				title = k_horned_church
				title = e_bretonnia
			}
			holder_scope = {
				OR = {
					independent = yes
					NOT = {
						any_liege = {
							holy_order = yes
						}
					}
				}
				NOR = {
					religion_group = necromantic_group
					religion_group = ormazd_gods_group
					culture_group = lizardman_group
					culture_group = skaven_group
					trait = creature_beastman
					trait = creature_nehekharan
					trait = creature_orc
					trait = creature_goblin
					trait = creature_hobgoblin
					trait = creature_fimir
					culture = cathayan
					is_merchant_republic = yes
					is_patrician = yes
				}
				OR = {
					independent = yes
					NOT = {
						any_demesne_title = {
							is_vice_royalty = yes
						}
					}
				}
			}
			OR = {
				is_landless_type_title = no
				is_tribal_type_title = yes
				temporary = yes
			}
			is_primary_type_title = no
			OR = {
				AND = {
					tier = BARON
					is_feudal = yes
				}
				holder_scope = { is_feudal = yes }
			}
		}
		allow = {
				OR = {
				custom_tooltip = {
					text = "Is not a High Elf"
					NOT = {	holder_scope = { culture_group = asur_group } }
					}
				custom_tooltip = {
					text = "The High Elves do not change the laws of Ulthuan."
						NOT = { title = e_ulthuan }
						holder_scope = { culture_group = asur_group }
					}
				}
				conditional_tooltip = {
					trigger = {
						has_dlc = "Conclave"
					}
					holder_scope = {
						show_scope_change = no
						primary_title = {
							show_scope_change = no
							OR = {
								has_law = ze_administration_laws_1
								has_law = ze_administration_laws_2
							}
						}
					}
				}
				conditional_tooltip = {
					trigger = {
						NOT = { has_dlc = "Conclave" }
						NOT = { has_law = succ_hre_elective }
					}
					OR = {
						hidden_tooltip = {
							has_crown_law_title = no
						}
						crownlaw_title = {
							OR = {
								has_law = crown_authority_1
								has_law = crown_authority_2
								has_law = crown_authority_3
								has_law = crown_authority_4
								has_law = imperial_crown_authority_1
								has_law = imperial_crown_authority_2
								has_law = imperial_crown_authority_3
								has_law = imperial_crown_authority_4
							}
						}
					}
				}
				custom_tooltip = {
					text = not_forced_tt
					hidden_tooltip = {
						holder_scope = { NOT = { has_character_flag = liege_forced_succ_law } }
					}
				}
				conditional_tooltip = {
					trigger = {
						has_dlc = "Conclave"
					}
					custom_tooltip = {
						text = forced_elective_tt
						hidden_tooltip = {
							NAND = {
								has_law = succession_voting_power_1
								OR = {
									has_law = succ_feudal_elective
									has_law = succ_hre_elective
								}
							}
						}
					}
				}
				conditional_tooltip = {
					trigger = {
						has_law = succ_hre_elective
						has_dlc = "Conclave"
					}
					has_law = law_voting_power_0
				}
				conditional_tooltip = {
					trigger = {
						has_law = succ_hre_elective
						NOT = { has_dlc = "Conclave" }
					}
					has_law = crown_authority_4
				}
				conditional_tooltip = {
					trigger = {
						has_law = succ_hre_elective
					}
					has_law = centralization_4
				}
		}

		effect = {
			succession = ultimogeniture
		}
	}

	succ_turkish_succession = {
		oldest_child_opinion = -5
  		#child_opinion = 30
  		#dynasty_opinion = 10
		potential = {
			NOR = {
				has_law = succ_military_elective
				title = k_shadowrealm
				title = k_horned_church
				title = e_bretonnia
			}
			holder_scope = {
				NOR = {
					culture_group = lizardman_group
					culture_group = skaven_group
					trait = creature_beastman
					trait = creature_nehekharan
					culture = cathayan
					trait = in_matriheritage
				}
				OR = {
					religion_group = necromantic_group
					religion_group = ormazd_gods_group
					trait = creature_orc
					trait = creature_goblin
					trait = creature_hobgoblin
					trait = creature_fimir
					AND = {
						has_religion_feature = religion_patriarchal
						is_theocracy = no
					}
					AND = {
						has_religion_feature = religion_matriarchal
						is_theocracy = no
					}
				}
				NOR = {
					is_republic = yes
					is_merchant_republic = yes
					is_nomadic = yes
				}
			}
			OR = {
				holder_scope = { # Viceroyalties can always have turkish succession if muslim
					any_demesne_title = {
						is_vice_royalty = yes
					}
				}
				AND = {
					OR = {
						is_landless_type_title = no
						is_tribal_type_title = yes
						temporary = yes
						holder_scope = { trait = vampire_blood_visible }
					}
					holder_scope = {
						OR = {
							independent = yes
							NOT = {
								any_liege = {
									holy_order = yes
								}
							}
						}
					}
					is_primary_type_title = no
				}
			}
			NAND = {
				has_law = succession_voting_power_1
				OR = {
					has_law = succ_feudal_elective
					has_law = succ_hre_elective
				}
			}
			#NOT = { holder_scope = { government = confucian_bureaucracy } }
		}
		effect = {
			succession = turkish_succession
		}
	}

	succ_papal_succession = {
		potential = {
			title = k_cult_of_sigmar
		}

		effect = {
			succession = papal_succession
		}
	}

	# Titles revert back to the liege on death
	succ_appointment = {
		potential = {
			NOR = {
				has_law = succ_military_elective
				title = k_shadowrealm
				title = k_horned_church
				title = e_bretonnia
			}
			holder_scope = {
				NOT = { culture_group = skaven_group }
				is_feudal = yes
				independent = no
				any_liege = {
					holy_order = yes
				}
				is_merchant_republic = no
			}
		}
		effect = {
			succession = appointment
		}
	}

	succ_open_elective = {
		potential = {
			NOR = {
				has_law = succ_military_elective
				has_law = succ_whunter_elective
			}
			NOR = {
				title = e_realm_of_brayherd
				title = k_shadowrealm
				title = k_cult_of_sigmar
				title = e_bretonnia
			}
			NAND = { NOT = { title = k_horned_church }
				holder_scope = { culture_group = skaven_group } }
			NAND = { independent = no
				has_law = succ_appointment } #Do not allow lizardmen vassals to turn back
			temporary = no
			OR = { title = k_horned_church
				holder_scope = { culture_group = lizardman_group }
				is_primary_type_title = yes
				holy_order = yes
				AND = {
					NOT = { holder_scope = { religion_group = old_world_group } }
					tier = BARON
					OR = {
						is_republic = yes
						AND = {
							is_theocracy = yes
							NOT = { holder_scope = { religion_group = necromantic_group } }
						 }
					}
				}
				holder_scope = {
					NOR = {
						government = elector_count_government
						government = feudal_government
						trait = creature_beastman
					}
					OR = {
						is_republic = yes
						AND = {
							is_theocracy = yes
							controls_religion = yes
						}
					}
				}
			}
			OR = {
				is_theocracy = yes
				holder_scope = { culture_group = lizardman_group }
				AND = {
					is_landless_type_title = yes
					holder_scope = {
						NOT = {	is_vampire_visible_trigger = yes }
					}
				}
				holder_scope = {
					NOR = {
						is_theocracy = yes
						is_vampire_visible_trigger = yes
					}
				}
			}
			holder_scope = {
				is_patrician = no
				is_merchant_republic = no
				NOT = { trait = in_matriheritage }
				OR = {
					independent = yes
					is_feudal = no
					NOT = {
						any_liege = {
							holy_order = yes
						}
					}
				}
			}
			NAND = {
				has_law = succession_voting_power_1
				OR = {
					has_law = succ_feudal_elective
					has_law = succ_hre_elective
				}
			}
		}

		effect = {
			succession = open_elective
		}
	}

	succ_catholic_bishopric = {
		potential = {
			NOR = {
				title = k_shadowrealm
				title = k_horned_church
				title = e_bretonnia
			}
			holder_scope = {
				NOT = { culture_group = skaven_group }
			}
			is_landless_type_title = no
			OR = {
				AND = {
					tier = BARON
					is_theocracy = yes
				}
				holder_scope = { is_theocracy = yes }
			}

			holder_scope = {
				religion_group = old_world_group
				is_merchant_republic = no
				OR = {
					independent = yes
					is_feudal = no
					NOT = {
						any_liege = {
							holy_order = yes
						}
					}
				}
			}
			is_primary_type_title = no
		}
		effect = {
			succession = catholic_bishopric
		}
	}

	succ_patrician_elective = {
		potential = {
			NOR = {
				title = k_shadowrealm
				title = k_horned_church
				title = e_bretonnia
			}
			NOT = { holder_scope = { culture_group = skaven_group } }
			OR = {
				is_primary_holder_title = yes
				holder_scope = {
					in_revolt = yes
					succ_law_title = {
						title = PREVPREV
					}
				}
			}
			holder_scope = {
				is_merchant_republic = yes
			}
		}
		effect = {
			succession = patrician_elective
		}
	}

	succ_nomad_succession = {
		potential = {
			NOR = {
				title = k_shadowrealm
				title = k_horned_church
				title = e_bretonnia
				holder_scope = { culture_group = skaven_group }
			}
			holder_scope = {
				is_nomadic = yes
			}
		}
		effect = {
			succession = nomad_succession
		}
	}

	succ_offmap_succession = {
		potential = {
			holder_scope = {
				top_liege = { is_offmap_governor = yes }
				government = confucian_bureaucracy # To use this with future offmap powers, use an OR clause here with the new government types
			}
		}
		effect = {
			succession = offmap_succession
			# This succession type generates a character of China's culture and religion
			# They have decent (4-10) stats, and good (7-11) stewardship, and will always have a Stewardship education
			# The offmap power defined in the top liege's government is used to determine the culture and religion. Will not function if this isn't defined
		}
	}

	succ_military_elective = {
		vassal_opinion=5
		potential = {
			NAND = { independent = no
				has_law = succ_appointment } #Do not allow lizardmen vassals to turn back
			temporary = no
			OR = {
				OR = {
					title = k_the_brass_legion
					title = d_the_brass_legion
					title = c_the_brass_legion
					title = d_skulltakers
					title = c_skulltakers
					title = c_shadow_warriors
					title = d_knights_of_antoch
					title = k_knights_of_antoch
					title = k_red_dukedom
					title = k_knights_of_morr
					title = d_knights_of_morr
					title = c_order_of_the_raven
					has_title_flag = mercenary_landed_title
					has_title_flag = holy_order_landed_title
				}
				holy_order = yes
			}
			holder_scope = {
				is_patrician = no
				is_merchant_republic = no
				NOT = { trait = in_matriheritage }
				OR = {
					independent = yes
					is_feudal = no
					NOT = {
						any_liege = {
							holy_order = yes
						}
					}
				}
			}
			NAND = {
				has_law = succession_voting_power_1
				OR = {
					has_law = succ_feudal_elective
					has_law = succ_hre_elective
				}
			}
		}

		effect = {
			succession = {
				base_type = feudal_elective
				voting_rules = military_elective
			}
		}
	}
	succ_whunter_elective = {
		potential = {
			NAND = { independent = no
				has_law = succ_appointment } #Do not allow lizardmen vassals to turn back
			temporary = no
			holder_scope = {
				trait=witch_hunter
				is_patrician = no
				is_merchant_republic = no
				higher_tier_than=BARON
				OR = {
					independent = yes
					top_liege = {
						trait=witch_hunter
					}
				}
			}
			NAND = {
				has_law = succession_voting_power_1
				OR = {
					has_law = succ_feudal_elective
					has_law = succ_hre_elective
				}
			}
		}

		effect = {
			succession = {
				base_type = feudal_elective
				voting_rules = witch_hunter_elective
			}
		}
	}

	succ_bretonnia_elective = {
		feudal_opinion = 5 #Only Feudal Vassals would care (Knights)
		potential = {
			title = e_bretonnia #Title-bound.
			holder_scope = { religion_group = old_world_group }
		}
		allow = {
			custom_tooltip = {
				text = not_forced_tt
				hidden_tooltip = {
					holder_scope = { NOT = { has_character_flag = liege_forced_succ_law } }
				}
			}
		}
		effect = {
			succession = {
				base_type = feudal_elective
				voting_rules = bretonnia_feudal_elective
			}
		}
	}

	succ_sorcererous_conclave_elective = {
		vassal_opinion = 10
		potential = {
			title = k_zharrduk
			holder_scope = {
				religion = hashut
			}
		}
		allow = {
			custom_tooltip = {
				text = not_forced_tt
				hidden_tooltip = {
					holder_scope = { NOT = { has_character_flag = liege_forced_succ_law } }
				}
			}
		}
		effect = {
			succession = {
				base_type = feudal_elective
				voting_rules = sorcerous_conclave_voting
			}
		}
	}
}

gender_laws = {
	cognatic_succession = {
		potential = {
			holder_scope = {
				OR = {
					culture_group = norscan_group
					culture_group = asur_group
					culture_group = druchii_group
					culture_group = asrai_group
					culture_group = imperial_group
					culture_group = tilean_group
					culture_group = estalian_group
					culture_group = halfling_old_world
					culture_group = halfling_lustrian
					culture_group = kislevite_group
					culture_group = lahmian_group
					culture_group = ogre_group
					culture = cathayan
					religion = slaanesh
					capital_scope = { region = world_old_world_border_princes }
				}
				NOR = {
					has_religion_feature = religion_matriarchal
					has_religion_feature = religion_equal
					religion = greenskin_gods
					religion = spider_god
					culture_group = skaven_group
					culture_group = goblin_group
					culture_group = orc_group
					culture_group = lizardman_group
					is_vampire_visible_trigger = yes
					trait = creature_nehekharan
					trait = creature_beastman
					religion = amazon
					trait = creature_amazon
					#no male sorcerers, ever!
					AND = {
						trait = druchii_sorceress
						any_liege = { trait = malekith }
					}
					title = k_ghrond
					trait = phoenix_king
					trait = everqueen
				}
				OR = {
					NOT = { tier = BARON }
					is_theocracy = yes
					is_republic = yes
				}
				OR = {
					independent = yes
					NOT = {
						any_liege = {
							holy_order = yes
						}
					}
					is_merchant_republic = yes
				}
				OR = {
					AND = {
						NOT = { religion_group = ormazd_gods_group }
						has_horde_culture = no
						is_merchant_republic = no
					}
					AND = {
						has_dlc = "Zeus"
						ROOT = {
							holder_scope = {
								primary_title = {
									OR = {
										has_law = status_of_women_3
										has_law = status_of_women_4
									}
								}
							}
						}
						OR = {
							is_patrician = no
							liege = {
								primary_title = {
									OR = {
										has_law = true_cognatic_succession
										has_law = cognatic_succession
									}
								}
							}
						}
					}
				}
			}
			OR={
				holder_scope={trait=witch_hunter} #Witch hunters can elect both females and males but females don't have much favor in the elections
				AND={
					is_landless_type_title = no
					is_primary_type_title = no
				}
			}

			OR = {
				AND = {
					tier = BARON
					is_theocracy = no
					is_republic = no
				}
				holder_scope = {
					is_theocracy = no
					is_republic = no
				}
			}

		}

		effect = {
			gender_succ = cognatic
			law_set_allow_matrilineal_marriage = yes
		}
		default = yes
		default_selection = {
			factor = 15
			modifier = {
				factor = 0
				holder_scope = {
					culture_group = amazon_group
				}
			}
			modifier = {
				factor = 25
				holder_scope = {
					OR = {
						culture = ungol
						culture = ropsmann
						}
						is_female = no
					}

				}
		}
	}

	true_cognatic_succession = {
		male_dynasty_opinion = -5

		potential = {
			OR = {
				holder_scope = {
					OR = {
						capital_scope = { region = world_old_world_border_princes }
						culture_group = asur_group
						culture_group = druchii_group
						culture_group = asrai_group
						culture_group = halfling_old_world
						culture_group = halfling_lustrian
						culture_group = kislevite_group
						culture_group = lahmian_group
					        culture_group = ogre_group						
					        culture = cathayan
						culture = wasai
						culture = bayaji
						religion = slaanesh
						trait = creature_nehekharan
						is_vampire_visible_trigger = yes
						AND = {
							OR = {
								culture_group = tilean_group
								culture_group = estalian_group
								culture = stirlander
								culture = talabeclander
								religion = shallyan
							}
							religion = myrmidian
							is_female = yes
							prestige = 1000
						}
					}
			 	}
				holder_scope = {
					is_merchant_republic = no
					is_patrician = no
					NOR = {
						culture_group = lizardman_group
						religion = amazon
						trait = creature_amazon
						culture_group = goblin_group
						culture_group = orc_group
						trait = creature_beastman
						religion = greenskin_gods
						religion = spider_god
						trait = phoenix_king
						trait = everqueen
					}
				}
			}
			holder_scope = {
				NOR = {
					has_religion_feature = religion_matriarchal
					has_religion_feature = religion_patriarchal
					culture_group = skaven_group
				}
			}
			NOR = {
				#no male sorcerers, ever!
				holder_scope = {
					trait = druchii_sorceress
					top_liege = { trait = malekith }
				}
				title = k_ghrond
			}
			holder_scope = {
				OR = {
					AND = {
						NOT = { religion_group = ormazd_gods_group }
						has_horde_culture = no
						#is_tribal = no
						#is_nomadic = no
						#is_merchant_republic = no
						#is_patrician = no
					}
					has_religion_feature = religion_equal
					has_religion_feature = religion_feature_bon
					AND = {
						has_dlc = "Zeus"
						ROOT = { holder_scope = { primary_title = { has_law = status_of_women_4 } } }
						OR = {
							is_patrician = no
							liege = {
								primary_title = {
									OR = {
										has_law = true_cognatic_succession
										has_law = cognatic_succession
									}
								}
							}
						}
					}
				}
			}

			is_landless_type_title = no

			OR = {
				AND = {
					tier = BARON
					is_theocracy = no
					is_republic = no
				}
				holder_scope = {
					is_theocracy = no
					OR = {
						is_republic = no
						is_patrician = yes
					}
				}
				holder_scope = {
					has_religion_feature = religion_equal
				}
			}

			is_primary_type_title = no
		}

		allow = {
			holder_scope = {
				OR = {
					custom_tooltip = {
						text = "Is Nehekharan"
						trait = creature_nehekharan
					}
					custom_tooltip = {
						text = "Is an Elf"
						OR = {
							culture_group = asur_group
							culture_group = druchii_group
							culture_group = asrai_group
						}
					}
					custom_tooltip = {
						text = "Is a Halfling"
						OR = {
							culture_group = halfling_old_world
							culture_group = halfling_lustrian
						}
					}
					custom_tooltip = {
						text = "Is a Kislevite"
						culture_group = kislevite_group
					}
					custom_tooltip = {
						text = "Is a Lahmian Vampire"
						culture_group = lahmian_group
					}
					custom_tooltip = {
						text = "Is a Southlander"
						OR = {
							culture = wasai
							culture = bayaji
						}
					}
					custom_tooltip = {
						text = "Openly worships Slaanesh"
						religion = slaanesh
					}
					custom_tooltip = {
						text = "is_a_known_vampire_tt"
						OR = {
							trait = vampire_lahmian_visible
							trait = vampire_carstein_visible
							trait = vampire_blood_visible
							trait = vampire_strigoi_visible
							trait = vampire_necrarch_visible
							trait = vampire_jade_visible
							trait = vampire_mahtmasi_visible
						}
					}
					AND = {
						custom_tooltip = {
							text = "Is a female Stirlander, Talabeclander, or Tilean or Estalian worshipper of Myrmidia"
							OR = {
								culture_group = tilean_group
								culture_group = estalian_group
								culture = stirlander
								culture = talabeclander
							 }
							 OR = {
								 religion = myrmidian
								 culture = stirlander
								 culture = talabeclander
							 }
							 is_female = yes
						}
						prestige = 1000
					 }
					capital_scope = { region = world_old_world_border_princes }
                                       }
                                       AND = {
                                           has_law = status_of_women_2
                                           prestige >= 1000
                                       }
                                       AND = {
                                           has_law = status_of_women_3
                                           prestige >= 500
                                       }
                                       AND = {
                                           has_law = status_of_women_4
                                           prestige >= 100
				}
			}
		}
		effect = {
			gender_succ = true_cognatic
			law_set_allow_matrilineal_marriage = yes
		}
		default_selection = {
			factor = 10

			modifier = {
				factor = 0
				holder_scope = {
					culture_group = amazon_group
				}
			}
			modifier = {
				factor = 1.5
				holder_scope = {
					culture_group = asrai_group
				}
			}
			modifier = {
				factor = 0
				holder_scope = {
					culture = amazon_main
				}
			}
			modifier = {
				factor = 100
				holder_scope = {
					OR = {
						culture = kislevite
						culture = gospodar
						}
					}
				}
			modifier = {
				factor = 100
				holder_scope = {
					OR = {
						culture = ungol
						culture = ropsmann
						}
					is_female = yes
					}

				}
			modifier = {
				factor = 0.1
				NOT = {
					holder_scope = {
						has_religion_feature = religion_equal
					}
				}
			}

			modifier = {
				factor = 100
				holder_scope = {
					has_religion_feature = religion_equal
				}
			}
		}
	}

	agnatic_succession = {
		female_dynasty_opinion = -5

		potential = {
			holder_scope = {
				NOR = {
					has_religion_feature = religion_matriarchal
					has_religion_feature = religion_equal
					culture = witchhunter_culture
					trait = creature_nehekharan
					culture_group = asrai_group
					is_vampire_visible_trigger = yes
					religion = amazon
					trait = creature_amazon
					#no male sorcerers, ever!
					trait = druchii_sorceress
					top_liege = { trait = malekith }
					title = k_ghrond
					religion = cytharai
					religion = atharti
					trait = everqueen
				}
			}
			NOR = {
				has_law = enatic_cognatic_succession
				has_law = enatic_succession
			}
		}
		effect = {
			gender_succ = agnatic
		}
		default = yes
		default_selection = {
			factor = 1

			modifier = {
				factor = 1.25
				holder_scope = {
					primary_title = {
						NOR = {
							has_law = status_of_women_3
							has_law = status_of_women_4
						}
					}
				}
			}

			modifier = {
				factor = 0
				culture = amazon_main
			}
		}
	}

	enatic_succession = {
		male_dynasty_opinion = -10
		female_dynasty_opinion = 10
		potential = {
			OR = {
				capital_scope = { region = world_old_world_border_princes }
				holder_scope = { has_religion_feature = religion_matriarchal }
				AND = {
					holder_scope = { trait = druchii_sorceress }
					title = k_ghrond
				}
				AND = {
					holder_scope = { is_female = yes }
					title = d_black_sisters
				}
				holder_scope = { religion = amazon }
				holder_scope = {
					NOR = {
						culture = witchhunter_culture
						culture_group = skaven_group
						culture_group = ogre_group
						culture_group = lizardman_group
						culture_group = asrai_group
						culture_group = goblin_group
						culture_group = orc_group
						religion_group = greenskin_gods_group
						trait = creature_nehekharan
						trait = creature_beastman
						is_vampire_visible_trigger = yes
						culture = cathayan
						has_landed_title = e_ulthuan
					}
					OR = {
						independent = yes
						NOT = {
							any_liege = { holy_order = yes }
						}
					}
				}
			}
		}

		allow = {
			holder_scope = {
				is_female = yes
				OR = {
					trait = ambitious
					trait = lunatic_3
					trait = lunatic_2
					trait = lunatic_1
					trait = possessed
					prestige = 2000
				capital_scope = { region = world_old_world_border_princes }
				}
				NOR = {
					trait = content
					trait = slow
					trait = imbecile
				}
				custom_tooltip = {
					text = is_not_a_known_vampire_tt
					NOT = { is_vampire_visible_trigger = yes }
				}
				OR = {
					any_owned_bloodline = {
						has_bloodline_flag = matrilineal_bloodline
					}
					has_law = enatic_succession
					culture = amazon_main
					AND = {
						OR = {
							has_law = true_cognatic_succession
							has_law = enatic_cognatic_succession
						}
						is_female = yes
					}
				}
			}
		}

		effect = {
			gender_succ = enatic
		}
		default_selection = {
			factor = 1
			modifier = {
				factor = 0
				NOT = { culture = amazon_main }
				}
			modifier = {
				factor = 100
				culture = amazon_main
				}
		}
	}

	enatic_cognatic_succession = {
		male_dynasty_opinion = -10
		female_dynasty_opinion = 5

		potential = {
			holder_scope = {
				OR = {
					has_religion_feature = religion_matriarchal
					any_owned_bloodline = {
						has_bloodline_flag = bloodline_enatic_cognatic
					}
					any_owned_bloodline = {
						has_bloodline_flag = matrilineal_bloodline
					}
					capital_scope = { region = world_old_world_border_princes }
				}
			}
			NOR = {
				title = k_shadowrealm
				culture_group = ogre_group
				culture_group = skaven_group
			}
			OR = {
				holder_scope = { religion = amazon }
				capital_scope = { region = world_old_world_border_princes }
				NOR = {
					#no male sorcerers, ever!
					holder_scope = {
						trait = druchii_mage
						top_liege = { trait = malekith }
					}
					title = k_ghrond
				}
				holder_scope = {
					NOR = {
						culture_group = lizardman_group
						culture_group = goblin_group
						culture_group = orc_group
						culture = witchhunter_culture
						religion_group = greenskin_gods_group
						trait = creature_beastman
						trait = creature_nehekharan
						is_vampire_visible_trigger = yes
						culture = cathayan
					}
					OR = {
						NOT = { has_landed_title = e_ulthuan }
						NOT = { trait = creature_elf }
					}
					OR = {
						independent = yes
						NOT = {
							any_liege = { holy_order = yes }
						}
					}
					OR = {
						has_law = enatic_succession
						culture = amazon_main
						AND = {
							has_law = true_cognatic_succession
							is_female = yes
						}
					}
				}
			}
		}

		allow = {
			holder_scope = {
				is_female = yes
				OR = {
					trait = ambitious
					trait = lunatic_3
					trait = lunatic_2
					trait = lunatic_1
					trait = possessed
					prestige = 2000
					capital_scope = { region = world_old_world_border_princes }
				}
				NOR = {
					trait = content
					trait = slow
					trait = imbecile
				}
				custom_tooltip = {
					text = is_not_a_known_vampire_tt
					NOT = { is_vampire_visible_trigger = yes }
				}
				any_owned_bloodline = {
					has_bloodline_flag = matrilineal_bloodline
				}
				OR = {
					has_law = enatic_succession
					culture = amazon_main
					AND = {
						has_law = true_cognatic_succession
						is_female = yes
					}
				}
			}
		}
		effect = {
			gender_succ = enatic_cognatic
		}
		default_selection = {
			factor = 1

			modifier = {
				factor = 0
				NOT = {
					holder_scope = {
						OR = {
							has_religion_feature = religion_matriarchal
							any_owned_bloodline = {
								has_bloodline_flag = bloodline_enatic_cognatic
							}
						}
					}
				}
			}

			modifier = {
				factor = 100
				holder_scope = {
					OR = {
						has_religion_feature = religion_matriarchal
						any_owned_bloodline = {
							has_bloodline_flag = bloodline_enatic_cognatic
						}
					}
				}
			}
		}
	}
}
