murder_consequences_known_or_exposed_effect = {
	$MURDERER$ = {
		###ADD TRAITS###
		#Force tooltip is used for everyone but POV to make sure expose secret events looks right for everyone, even though the trait can only be added once. Kinslayer works the same way.
		add_trait_only_force_tooltip_if_not_pov_effect = { TRAIT = murderer POV = $POV$ }
		add_kinslayer_trait_or_nothing_effect = { VICTIM = $VICTIM$ }
		
		# Add piety penalty if the murder was unjust
		if = {
			limit = {
				NOR = {
					any_close_family_member = {
						even_if_dead = yes
						killer ?= $VICTIM$
					}
					any_spouse = {
						even_if_dead = yes
						killer ?= $VICTIM$
					}
					AND = {
						faith = { has_doctrine = tenet_fp3_fedayeen } #this checks that assassins don't get piety loss for killing unbelievers
						NOT = { faith = $VICTIM$.faith }
					}
				}		
			}
			add_piety = medium_piety_loss
		}
		
		# If we're a clan this affects unity
		if = {
			limit = { # If the victim is landed
				$VICTIM$ = { is_landed = yes }
			}
			add_clan_unity_interaction_effect = {
				CHARACTER = $MURDERER$
				TARGET = $VICTIM$
				VALUE = medium_unity_loss
				DESC = clan_unity_murder.desc
				REVERSE_NON_HOUSE_TARGET = no
			}
		}
		# For unlanded characters, we don't care as much, but you still lose some unity
		else = {
			add_clan_unity_interaction_effect = {
				CHARACTER = $MURDERER$
				TARGET = $VICTIM$
				VALUE = minor_unity_loss
				DESC = clan_unity_murder.desc
				REVERSE_NON_HOUSE_TARGET = no
			}
		}

		# Family Feud
		house_feud_murder_effect = { VICTIM = $VICTIM$ MURDERER = $MURDERER$ }

		# Opinion and dread: we only show this for the murderer.
		if = {
			limit = { this = $POV$ }
			murder_consequences_known_or_exposed_apply_dread_effect = { VICTIM = $VICTIM$ }
			murder_opinion_effect = { VICTIM = $VICTIM$ MURDERER = $MURDERER$ }
		}
		# There are some things you just shouldn't do
		show_as_tooltip = {
			if = {
				limit = {
					$VICTIM$ = { has_character_flag = is_party_baron }
				}
				add_character_modifier = { modifier = party_baron_murdered_the_joy_of_life_modifier }
			}
		}
		hidden_effect = {
			if = {
				limit = {
					OR = {
						exists = local_var:murdered_party_baron
						exists = scope:secret.var:murdered_party_baron
					}
				}
				add_character_modifier = { modifier = party_baron_murdered_the_joy_of_life_modifier }
			}
		}
	}

	# Struggle Catalysts.
	if = {
		limit = {
			$VICTIM$ = { is_vip_struggle_character = yes }
			$MURDERER$ = {
				any_character_struggle = {
					involvement = involved
					activate_struggle_catalyst_secondary_character_involvement_involved_trigger = {
						CATALYST = catalyst_discovery_of_very_important_murder
						CHAR = scope:victim
					}
				}
			}
		}
		$MURDERER$ = {
			every_character_struggle = {
				involvement = involved
				limit = {
					activate_struggle_catalyst_secondary_character_involvement_involved_trigger = {
						CATALYST = catalyst_discovery_of_very_important_murder
						CHAR = scope:victim
					}
				}
				activate_struggle_catalyst = {
					catalyst = catalyst_discovery_of_very_important_murder
					character = $MURDERER$
				}
			}
		}
	}
}

murder_consequences_known_or_exposed_hidden_opinion_effect = {
	$MURDERER$ = {
		###ADD TRAITS###
		#Force tooltip is used for everyone but POV to make sure expose secret events looks right for everyone, even though the trait can only be added once. Kinslayer works the same way.
		add_trait_only_force_tooltip_if_not_pov_effect = { TRAIT = murderer POV = $POV$ }
		add_kinslayer_trait_or_nothing_effect = { VICTIM = $VICTIM$ }
		
		if = { #Add piety penalty if the murder was unjust
			limit = {
				NOR = {
					any_close_family_member = {
						even_if_dead = yes
						killer ?= $VICTIM$
					}
					any_spouse = {
						even_if_dead = yes
						killer ?= $VICTIM$
					}
					AND = {
						faith = { has_doctrine = tenet_fp3_fedayeen } #this checks that assassins don't get piety loss for killing unbelievers
						NOT = { faith = $VICTIM$.faith }
					}
				}		
			}
			add_piety = medium_piety_loss
		}

		# Family Feud
		house_feud_murder_effect = { VICTIM = $VICTIM$ MURDERER = $MURDERER$ }

		###OPINION AND DREAD###
		#Hide this from POV if they're not the murderer
		if = {
			limit = { this = $POV$ }
			add_dread = 15
			hidden_effect = {
				murder_opinion_effect = { VICTIM = $VICTIM$ MURDERER = $MURDERER$ }
			}
		}
		else = {
			hidden_effect = {
				add_dread = 15
				murder_opinion_effect = { VICTIM = $VICTIM$ MURDERER = $MURDERER$ }
			}
		}
		# There are some things you just shouldn't do
		show_as_tooltip = {
			if = {
				limit = { $VICTIM$ = { has_character_flag = is_party_baron } }
				add_character_modifier = {
					modifier = party_baron_murdered_the_joy_of_life_modifier
				}
			}
		}
		hidden_effect = {
			if = {
				limit = {
					OR = {
						exists = local_var:murdered_party_baron
						exists = scope:secret.var:murdered_party_baron
					}
				}
				add_character_modifier = {
					modifier = party_baron_murdered_the_joy_of_life_modifier
				}
			}
		}
	}

	# Struggle Catalysts.
	if = {
		limit = {
			$VICTIM$ = { is_vip_struggle_character = yes }
			$MURDERER$ = {
				any_character_struggle = {
					involvement = involved
					activate_struggle_catalyst_secondary_character_involvement_involved_trigger = {
						CATALYST = catalyst_discovery_of_very_important_murder
						CHAR = scope:victim
					}
				}
			}
		}
		$MURDERER$ = {
			every_character_struggle = {
				involvement = involved
				limit = {
					activate_struggle_catalyst_secondary_character_involvement_involved_trigger = {
						CATALYST = catalyst_discovery_of_very_important_murder
						CHAR = scope:victim
					}
				}
				activate_struggle_catalyst = {
					catalyst = catalyst_discovery_of_very_important_murder
					character = $MURDERER$
				}
			}
		}
	}
}

unknown_murder_effect = {
	# Party Baron handling
	if = {
		limit = { $VICTIM$ = { has_character_flag = is_party_baron } }
		set_local_variable = {
			name = murdered_party_baron
			value = yes
		}
	}
	# If we're a clan this affects unity
	if = {
		limit = { # If the victim is landed
			$VICTIM$ = { is_landed = yes }
		}
		add_clan_unity_interaction_effect = {
			CHARACTER = $MURDERER$
			TARGET = $VICTIM$
			VALUE = minor_unity_loss
			DESC = clan_unity_murder_unknown.desc
			REVERSE_NON_HOUSE_TARGET = no
		}
	}
	else = { # For unlanded characters, we don't care as much, but you still lose some unity
		add_clan_unity_interaction_effect = {
			CHARACTER = $MURDERER$
			TARGET = $VICTIM$
			VALUE = miniscule_unity_loss
			DESC = clan_unity_murder_unknown.desc
			REVERSE_NON_HOUSE_TARGET = no
		}
	}
	$VICTIM$ = {
		#Killed by murder: set this up first to keep the killer hidden.
		hidden_effect = {
			death = {
				killer = $MURDERER$
				death_reason = $REASON$
			}
		}
		# Hide murderer in tooltip
		show_as_tooltip = {
			death = { death_reason = $REASON$ }
		}
	}
	$MURDERER$ = {
		if = {
			limit = { is_alive = yes }
			hidden_effect = {
				add_secret = {
					type = secret_murder
					target = $VICTIM$
				}
			}
			if = {
				limit = { exists = local_var:murdered_party_baron }
				random_secret = {
					type = secret_murder
					limit = {
						secret_target = $VICTIM$
					}
					set_variable = {
						name = murdered_party_baron
						value = yes
					}
				}
			}
		}
	}
}

#If it's a cannibal eating you - so that that fact is saved for future reference
unknown_cannibal_murder_effect = {
	$VICTIM$ = {
		death = {
			death_reason = death_mysterious
			killer = $MURDERER$
		}
	}
	$MURDERER$ = {
		add_secret = {
			type = secret_murder
			target = $VICTIM$
		}
		random_secret = {
			type = secret_murder
			limit = {
				secret_target = $VICTIM$
			}
			set_variable = { #To set the right death reason if the secret is revealed
				name = was_eaten_by_cannibal
				value = yes
			}
		}
	}
}

#Your head is turned into a bell chime
unknown_bell_murder_effect = {
	$VICTIM$ = {
		death = {
			death_reason = death_mysterious
			killer = $MURDERER$
		}
	}
	$MURDERER$ = {
		add_secret = {
			type = secret_murder
			target = $VICTIM$
		}
		random_secret = {
			type = secret_murder
			limit = {
				secret_target = $VICTIM$
			}
			save_scope_as = bell_secret
			set_variable = { #To set the right death reason if the secret is revealed
				name = was_turned_into_bell_chime 
				value = yes
			}
		}
	}
}


#KNOWN MURDER

# Exposer can be another character, or the murderer themselves if no specific character makes sense
known_murder_effect = {
	$VICTIM$ = { save_scope_as = victim_scope }
	$MURDERER$ = { save_scope_as = murderer_scope }
	hidden_effect = {
		if = {
			limit = { $VICTIM$ = { has_character_flag = is_party_baron } }
			set_local_variable = {
				name = murdered_party_baron
				value = yes
			}
		}
	}
	# If we're a clan this affects unity
	if = {
		limit = { # If the victim is landed
			$VICTIM$ = { is_landed = yes }
		}
		add_clan_unity_interaction_effect = {
			CHARACTER = $MURDERER$
			TARGET = $VICTIM$
			VALUE = medium_unity_loss
			DESC = clan_unity_murder.desc
			REVERSE_NON_HOUSE_TARGET = no
		}
	}
	else = { # For unlanded characters, we don't care as much, but you still lose some unity
		add_clan_unity_interaction_effect = {
			CHARACTER = $MURDERER$
			TARGET = $VICTIM$
			VALUE = minor_unity_loss
			DESC = clan_unity_murder.desc
			REVERSE_NON_HOUSE_TARGET = no
		}
	}
	$VICTIM$ = {
		every_close_family_member = {
			limit = {
				NOR = {
					this = $MURDERER$
					is_scheming_against = {
						target = $VICTIM$
						type = murder
					}
					has_any_bad_relationship_with_character_trigger = { CHARACTER = $VICTIM$ }
					trigger_if = {
						limit = { exists = scope:scheme }
						scope:scheme = { scheme_is_character_agent = prev }
					}
				}
				opinion = {
					target = $VICTIM$
					value > -50
				}
			}
			hidden_effect = {
				random = {
					chance = 25
					modifier = {
			            factor = 2
			            has_trait = wrathful
			        }
			        modifier = {
			            factor = 2
			            has_trait = vengeful
			        }
			        modifier = {
			            factor = 2
			            has_any_good_relationship_with_character_trigger = { CHARACTER = $VICTIM$ }
			        }
			        modifier = {
			        	factor = 2
			        	OR = {
			        		is_parent_of = $VICTIM$
			        		is_child_of = $VICTIM$
			        	} 	
			        }
				    trigger_event = {
						id = bp1_yearly.8050
						days = 15
					}
				}
			}
		}
		death = {
			death_reason = death_murder
			killer = $MURDERER$
		}
		hidden_effect = { set_killer_public = yes }
	}
	$MURDERER$ = {
		hidden_effect = {
			add_secret = {
				type = secret_murder
				target = $VICTIM$
			}
			random_secret = {
				type = secret_murder
				limit = {
					secret_target = $VICTIM$
				}

				set_variable = {
					name = known_murder
					value = yes
				}

				expose_secret = $EXPOSER$
			}
		}
	}
	show_as_tooltip = {
		murder_consequences_known_or_exposed_effect = {
			MURDERER = $MURDERER$
			VICTIM = $VICTIM$
			POV = root
		}
	}
	# Family Feud
	house_feud_murder_effect = { VICTIM = $VICTIM$ MURDERER = $MURDERER$ }
}

known_murder_hidden_opinion_effect = {
	$VICTIM$ = { save_scope_as = victim_scope }
	$MURDERER$ = { save_scope_as = murderer_scope }
	hidden_effect = {
		if = {
			limit = { $VICTIM$ = { has_character_flag = is_party_baron } }
			set_local_variable = {
				name = murdered_party_baron
				value = yes
			}
		}
	}
	$VICTIM$ = {
		every_close_family_member = {
			limit = {
				NOR = {
					this = $MURDERER$
					is_scheming_against = {
						target = $VICTIM$
						type = murder
					}
					has_any_bad_relationship_with_character_trigger = { CHARACTER = $VICTIM$ }
					trigger_if = {
						limit = { exists = scope:scheme }
						scope:scheme = { scheme_is_character_agent = prev }
					}
				}
				opinion = {
					target = $VICTIM$
					value > -50
				}
			}
			hidden_effect = {
				random = {
					chance = 25
					modifier = {
			            factor = 2
			            has_trait = wrathful
			        }
			        modifier = {
			            factor = 2
			            has_trait = vengeful
			        }
			        modifier = {
			            factor = 2
			            has_any_good_relationship_with_character_trigger = { CHARACTER = $VICTIM$ }
			        }
			        modifier = {
			        	factor = 2
			        	OR = {
			        		is_parent_of = $VICTIM$
			        		is_child_of = $VICTIM$
			        	} 	
			        }
				    trigger_event = {
						id = bp1_yearly.8050
						days = 15
					}
				}
			}
		}
		death = {
			death_reason = death_murder
			killer = $MURDERER$
		}
		hidden_effect = { set_killer_public = yes }
	}
	$MURDERER$ = {
		hidden_effect = {
			add_secret = {
				type = secret_murder
				target = $VICTIM$
			}
			random_secret = {
				type = secret_murder
				limit = {
					secret_target = $VICTIM$
				}

				set_variable = {
					name = known_murder
					value = yes
				}

				expose_secret = $EXPOSER$
			}
		}
	}
	show_as_tooltip = {
		murder_consequences_known_or_exposed_hidden_opinion_effect = {
			MURDERER = $MURDERER$
			VICTIM = $VICTIM$
			POV = root
		}
	}
	# Family Feud
	house_feud_murder_effect = { VICTIM = $VICTIM$ MURDERER = $MURDERER$ }
}


murder_opinion_effect = {
	$VICTIM$ = {
		#Victim's family
		every_spouse = {
			limit = { NOT = { this = $MURDERER$ } }
			add_to_temporary_list = close_family_murder_opinion_list
		}
		every_close_family_member = {
			limit = { NOT = { this = $MURDERER$ } }
			add_to_temporary_list = close_family_murder_opinion_list
		}

		if = {
			limit = {
				any_in_list = {
					list = close_family_murder_opinion_list
					always = yes
				}
			}
			every_in_list = {
				list = close_family_murder_opinion_list
				custom = all_close_family_and_spouses

				add_opinion = {
					target = $MURDERER$
					modifier = murdered_close_family_crime
				}
			}
		}
		#Victim's friends and lovers
		every_relation = {
			type = friend
			limit = {
				NOR = {
					this = $MURDERER$
					this = $VICTIM$
					is_in_list = close_family_murder_opinion_list
				}
			}
			add_to_list = victim_close_relations_list
		}
		every_relation = {
			type = lover
			limit = {
				NOR = {
					this = $MURDERER$
					this = $VICTIM$
					is_in_list = close_family_murder_opinion_list
					is_in_list = victim_close_relations_list
				}
			}
			add_to_list = victim_close_relations_list
		}
		if = {
			limit = {
				any_in_list = {
					list = victim_close_relations_list
					always = yes
				}
			}
			every_in_list = {
				list = victim_close_relations_list
				custom = all_friends_and_lovers
				add_opinion = {
					target = $MURDERER$
					modifier = executed_close_relation_opinion
				}
			}
		}
	}
}


attempted_murder_opinion_effect = {
	$VICTIM$ = {
        ###esr
		save_scope_as = esr_victim
		###esr/
		if = {
			limit = { is_alive = yes }
			add_opinion = {
				target = $MURDERER$
				modifier = attempted_murder_me_crime
			}
			hidden_effect = {
				add_opinion = {
					target = $MURDERER$
					modifier = murder_personal_grudge_opinion
					years = 2
				}
			}
		}

		every_spouse = {
			limit = { NOT = { this = $MURDERER$ } }
			add_to_temporary_list = close_family_murder_opinion_list
            ###esr
			add_to_temporary_list = esr_spouse_murder_opinion_list
			###esr/
		}
		###esr
		#every_close_family_member = {
		every_close_or_extended_family_member ={
			limit = { NOT = { this = $MURDERER$ } }
			add_to_temporary_list = close_family_murder_opinion_list
			###Note close_family_murder_opinion_list stores both close and extened family in esr
		}
		###esr/

		if = {
			limit = {
				any_in_list = {
					list = close_family_murder_opinion_list
					count >= 1
					NOT = {
						is_scheming_against = {
							target = $VICTIM$
							type = murder
						}
					}
				}
			}
			every_in_list = {
				list = close_family_murder_opinion_list
				###esr
				#custom = all_close_family_and_spouses
				custom = all_family_members

				#add_opinion = {
					#target = $MURDERER$
					#modifier = murdered_close_family_crime
				#}

				if = {
					limit = {
						OR = {
							is_close_family_of = $VICTIM$
							is_in_list = esr_spouse_murder_opinion_list
						}
					}
					add_opinion = {
						target = $MURDERER$
						modifier = attempted_murder_close_family_crime
					}					
				}

				else = {
					add_opinion = {
						target = $MURDERER$
						modifier = esr_attempted_murder_extended_family
					}		
				}
				###esr/
			}
		}
        ###esr
		#Victim's friends and lovers
		every_relation = {
			type = friend
			limit = {
				NOR = {
					this = $VICTIM$
					###esr
					this = $MURDERER$
					has_relation_best_friend = $VICTIM$
					#is_in_list = close_family_murder_opinion_list
					###esr/					
				}
			}
			add_to_list = victim_close_relations_list
		}
		every_relation = {
			type = lover
			limit = {
				NOR = {
					this = $VICTIM$
					###esr
					this = $MURDERER$
					has_relation_soulmate = $VICTIM$					
					#is_in_list = close_family_murder_opinion_list
					###esr/
					is_in_list = victim_close_relations_list
				}
			}
			add_to_list = victim_close_relations_list
		}
		if = {
			limit = {
				any_in_list = {
					list = victim_close_relations_list
					always = yes
				}
			}
			every_in_list = {
				list = victim_close_relations_list
				custom = all_friends_and_lovers
				add_opinion = {
					target = $MURDERER$
					modifier = esr_attempted_murder_close_relation_opinion
				}
			}
		}

		###esr
		#Victim's best friend and soulmate
		every_relation = {
			type = best_friend
			limit = { NOT = {this = $MURDERER$}}
			add_opinion = {
				target = $MURDERER$
				modifier = esr_attempted_murder_best_friend
			}
		}

		every_relation = {
			type = soulmate
			limit = { NOT = {this = $MURDERER$}}
			add_opinion = {
				target = $MURDERER$
				modifier = esr_attempted_murder_soulmate
			}
		}

		#Victim's rivals and nemesis
		every_relation = {
			type = rival
			limit = {
				NOR = {
					this = $MURDERER$
					has_relation_nemesis = $VICTIM$
					has_trait = just
					has_trait = compassionate
					has_trait = forgiving
					has_trait = honest
					has_trait = trusting
				}
			}
			custom = esr_rivals_attempted
			add_opinion = {
				target = $MURDERER$
				modifier = esr_attempted_murder_rival
			}
		}

		every_relation = {
			type = nemesis

			limit = {
				NOR = {
					this = $MURDERER$
					has_trait = just
					has_trait = compassionate
					has_trait = forgiving
				}
			}
			add_opinion = {
				target = $MURDERER$
				modifier = esr_attempted_murder_nemesis
			}
		}
		###esr/
		###esr/

		if = {
			limit = {
				exists = house
				exists = $MURDERER$.house
			}
			house = {
				change_house_relation_effect = {
					HOUSE = $MURDERER$.house
					VALUE = house_relation_damage_medium_value
					REASON = murder_attempt
					CHAR = $MURDERER$
					TARGET_CHAR = root
					TITLE = scope:dummy_gender
				}
			}
		}
	}
}

abduct_opinion_effect = {
	$VICTIM$ = {
		add_opinion = {
			target = $ABDUCTER$
			modifier = abducted_me_crime
		}
		#Victim's family
		every_spouse = {
			limit = { NOT = { this = $ABDUCTER$ } }
			add_to_temporary_list = close_family_abduct_opinion_list
		}
		every_close_family_member = {
			limit = { NOT = { this = $ABDUCTER$ } }
			add_to_temporary_list = close_family_abduct_opinion_list
		}

		if = {
			limit = {
				any_in_list = {
					list = close_family_abduct_opinion_list
					always = yes
				}
			}
			every_in_list = {
				list = close_family_abduct_opinion_list
				custom = all_close_family_and_spouses

				add_opinion = {
					target = $ABDUCTER$
					modifier = abducted_close_family_crime
				}
			}
		}
		#Victim's friends and lovers
		every_relation = {
			type = friend
			limit = {
				NOR = {
					this = $ABDUCTER$
					is_in_list = close_family_abduct_opinion_list
				}
			}
			add_to_list = victim_close_relations_list
		}
		every_relation = {
			type = lover
			limit = {
				NOR = {
					this = $VICTIM$
					is_in_list = close_family_abduct_opinion_list
					is_in_list = victim_close_relations_list
				}
			}
			add_to_list = victim_close_relations_list
		}
		if = {
			limit = {
				any_in_list = {
					list = victim_close_relations_list
					always = yes
				}
			}
			every_in_list = {
				list = victim_close_relations_list
				custom = all_friends_and_lovers
				add_opinion = {
					target = $ABDUCTER$
					modifier = abducted_close_relation_opinion
				}
			}
		}
	}
}

attempted_abduction_opinion_effect = {
	$VICTIM$ = {
		if = {
			limit = { is_alive = yes }
			add_opinion = {
				target = $ABDUCTER$
				modifier = attempted_abduct_me_crime
			}
			hidden_effect = {
				add_opinion = {
					target = $ABDUCTER$
					modifier = murder_personal_grudge_opinion
					years = 2
				}
			}
		}
		every_spouse = {
			limit = { NOT = { this = $ABDUCTER$ } }
			add_to_temporary_list = close_family_abduct_opinion_list
		}
		every_close_family_member = {
			limit = { NOT = { this = $ABDUCTER$ } }
			add_to_temporary_list = close_family_abduct_opinion_list
		}

		if = {
			limit = {
				any_in_list = {
					list = close_family_abduct_opinion_list
					always = yes
				}
			}
			every_in_list = {
				list = close_family_abduct_opinion_list
				custom = all_close_family_and_spouses

				add_opinion = {
					target = $ABDUCTER$
					modifier = attempted_abduct_close_family_crime
					years = 20
				}
			}
		}

	}
}


#Pick a Local Creepy Crawly
set_local_venomous_creature_effect = {
	random_list = {
		10 = {
			save_scope_value_as = {
				name = venomous_creature
				value = flag:rare_spider ##Very rare, as spiders poisonous enough to kill a man would need to come from VERY far
			}
		}
		500 = {
			save_scope_value_as = {
				name = venomous_creature
				value = flag:red_scorpion #India, Nepal
			}
			modifier = {
				factor = 0
				trigger_if = {
					limit = {
						exists = location
					}
					NOT = {
						location = { geographical_region = world_india }
					}
				}
			}
		}
		1000 = {
			save_scope_value_as = {
				name = venomous_creature
				value = flag:deathstalker #North Africa or Middle East
			}
			modifier = {
				factor = 0
				trigger_if = {
					limit = {
						exists = location
					}
					location = {
						NOR = {
							geographical_region = world_africa_north
							geographical_region = world_middle_east_jerusalem
							geographical_region = world_middle_east_persia
						}
					}
				}
			}
		}
		500 = {
			save_scope_value_as = {
				name = venomous_creature
				value = flag:fat_tail #Arabia, Middle East, Egypt
			}
			modifier = {
				factor = 0
				trigger_if = {
					limit = {
						exists = location
					}
					location = {
						NOR = {
							geographical_region = world_middle_east
							geographical_region = world_africa_north_east
						}
					}
				}
			}
		}
		200 = {
			save_scope_value_as = {
				name = venomous_creature
				value = flag:viper #Everywhere - fallback
			}
		}
		500 = {
			save_scope_value_as = {
				name = venomous_creature
				value = flag:mamba #Sub-saharan Africa
			}
			modifier = {
				factor = 0
				trigger_if = {
					limit = {
						exists = location
					}
					NOT = {
						location = { geographical_region = world_africa_west }
					}
				}
			}
		}
		250 = {
			save_scope_value_as = {
				name = venomous_creature
				value = flag:boomslang #Sub-saharan Africa
			}
			modifier = {
				factor = 0
				trigger_if = {
					limit = {
						exists = location
					}
					NOT = {
						location = { geographical_region = world_africa_west }
					}
				}
			}
		}
		250 = {
			save_scope_value_as = {
				name = venomous_creature
				value = flag:king_cobra #South-east Asia + India
			}
			modifier = {
				factor = 0
				trigger_if = {
					limit = {
						exists = location
					}
					location = {
						NOR = {
							geographical_region = world_india
							geographical_region = world_burma
							geographical_region = world_asia_southeast
						}
					}
				}
			}
		}
		1000 = {
			save_scope_value_as = {
				name = venomous_creature
				value = flag:daboia #India
			}
			modifier = {
				factor = 0
				trigger_if = {
					limit = {
						exists = location
					}
					NOT = {
						location = { geographical_region = world_india }
					}
				}
			}
		}
		500 = {
			save_scope_value_as = {
				name = venomous_creature
				value = flag:saw_scale #North Africa, Middle East, Pakistan, India
			}
			modifier = {
				factor = 0
				trigger_if = {
					limit = {
						exists = location
					}
					location = {
						NOR = {
							geographical_region = world_africa_north
							geographical_region = world_middle_east
							geographical_region = world_india
						}
					}
				}
			}
		}
		500 = {
			save_scope_value_as = {
				name = venomous_creature
				value = flag:krait #Pakistan, India, Southeast Asia
			}
			modifier = {
				factor = 0
				trigger_if = {
					limit = {
						exists = location
					}
					location = {
						NOR = {
							geographical_region = world_india
							geographical_region = world_burma
						}
					}
				}
			}
		}
		1 = {
			save_scope_value_as = {
				name = venomous_creature
				value = flag:beaked_mammal #Australia
			}
			modifier = {
				factor = 0
				stewardship <= 35 #Errr, *amazing* trade routes, I guess?
			}
		}
	}
}
