﻿
#LMF note: this is included in LMF since a) RelationToMe is used a lot in the LMF loc, and b) the vanilla file has errors for the RelationToMe versions when it comes to identifying court positions. If vanilla ever fixes this, I'll take it back out of LMF.

LMF_RelationToMe = {
	type = character

	text = {
		localization_key = relation_you
		trigger = { scope:second = root }
	}

	text = {
		localization_key = relation_motherwife
		trigger = {
			scope:second = {
				OR = {
					this = root.mother
					this = root.mother.mother
					this = root.father.mother
				}
				any_spouse = { this = root }
			}
		}
	}

	text = {
		localization_key = relation_mother_concubine
		trigger = {
			scope:second = {
				OR = {
					this = root.mother
					this = root.mother.mother
					this = root.father.mother
				}
				any_consort = { this = root }
				is_concubine = yes
			}
		}
	}

	text = {
		localization_key = relation_sisterwife
		trigger = {
			scope:second = {
				any_sibling = { this = root }
				is_female = yes
				any_spouse = { this = root }
			}
		}
	}

	text = {
		localization_key = relation_sister_concubine
		trigger = {
			scope:second = {
				any_sibling = { this = root }
				is_female = yes
				any_consort = { this = root }
				is_concubine = yes
			}
		}
	}

	text = {
		localization_key = relation_daughterwife
		trigger = {
			scope:second = {
				OR = {
					any_parent = { this = root }
					any_parent = { any_parent = { this = root } }
				}
				is_female = yes
				any_spouse = { this = root }
			}
		}
	}

	text = {
		localization_key = relation_daughter_concubine
		trigger = {
			scope:second = {
				OR = {
					any_parent = { this = root }
					any_parent = { any_parent = { this = root } }
				}
				any_consort = { this = root }
				is_female = yes
				is_concubine = yes
			}
		}
	}

	text = {
		localization_key = relation_fatherhusband
		trigger = {
			scope:second = {
				OR = {
					this = root.father
					this = root.father.father
					this = root.mother.father
				}
				any_spouse = { this = root }
			}
		}
	}

	text = {
		localization_key = relation_father_consort
		trigger = {
			scope:second = {
				OR = {
					this = root.father
					this = root.father.father
					this = root.mother.father
				}
				any_consort = { this = root }
				is_concubine = yes
			}
		}
	}

	text = {
		localization_key = relation_brotherhusband
		trigger = {
			scope:second = {
				any_sibling = { this = root }
				is_female = no
				any_spouse = { this = root }
			}
		}
	}

	text = {
		localization_key = relation_brother_consort
		trigger = {
			scope:second = {
				any_sibling = { this = root }
				is_female = no
				any_consort = { this = root }
				is_concubine = yes
			}
		}
	}

	text = {
		localization_key = relation_sonhusband
		trigger = {
			scope:second = {
				OR = {
					any_parent = { this = root }
					any_parent = {
						even_if_dead = yes
						any_parent = {
							this = root
						}
					}
				}
				is_female = no
				any_spouse = { this = root }
			}
		}
	}

	text = {
		localization_key = relation_son_consort
		trigger = {
			scope:second = {
				OR = {
					any_parent = { this = root }
					any_parent = {
						even_if_dead = yes
						any_parent = {
							this = root
						}
					}
				}
				is_female = no
				any_consort = { this = root }
				is_concubine = yes
			}
		}
	}

	text = {
		localization_key = relation_wife
		trigger = {
			any_spouse = {
				this = scope:second
			}
			scope:second = {
				is_female = yes
				is_alive = yes
				is_concubine = no
			}
		}
	}

	text = {
		localization_key = relation_husband
		trigger = {
			any_spouse = {
				this = scope:second
			}
			scope:second = {
				is_male = yes
				is_alive = yes
				is_concubine = no
			}
		}
	}

	text = {
		localization_key = relation_wife_departed
		trigger = {
			scope:second = {
				is_female = yes
				any_former_spouse = {
					this = root
				}
				is_alive = no
				is_concubine = no
			}
		}
	}

	text = {
		localization_key = relation_husband_departed
		trigger = {
			scope:second = {
				is_male = yes
				any_former_spouse = {
					this = root
				}
				is_alive = no
				is_concubine = no
			}
		}
	}

	text = {
		localization_key = relation_mother
		trigger = {
			scope:second = {
				is_female = yes
				any_child = {
					this = root
				}
			}
		}
	}

	text = {
		localization_key = relation_father
		trigger = {
			scope:second = {
				is_female = no
				any_child = {
					this = root
				}
			}
		}
	}

	text = {
		localization_key = relation_heir_daughter
		trigger = {
			player_heir ?= scope:second
			scope:second = {
				is_female = yes
				is_child_of = root
			}
		}
	}

	text = {
		localization_key = relation_heir_son
		trigger = {
			player_heir ?= scope:second
			scope:second = {
				is_male = yes
				is_child_of = root
			}
		}
	}

	text = {
		localization_key = relation_travel_leader_daughter
		trigger = {
			scope:second = {
				is_female = yes
				is_child_of = root
				root.current_travel_plan ?= {
					scope:second = { is_travel_leader = yes }
				}
			}
		}
	}

	text = {
		localization_key = relation_travel_leader_son
		trigger = {
			scope:second = {
				is_male = yes
				is_child_of = root
				root.current_travel_plan ?= {
					scope:second = { is_travel_leader = yes }
				}
			}
		}
	}

	text = {
		localization_key = relation_travel_leader_wife
		trigger = {
			scope:second = {
				is_spouse_of = root
				is_female = yes
				root.current_travel_plan ?= {
					scope:second = { is_travel_leader = yes }
				}
			}
		}
	}

	text = {
		localization_key = relation_travel_leader_husband
		trigger = {
			scope:second = {
				is_spouse_of = root
				is_male = yes
				root.current_travel_plan ?= {
					scope:second = { is_travel_leader = yes }
				}
			}
		}
	}

	text = {
		localization_key = relation_travel_leader_mother
		trigger = {
			scope:second = {
				is_spouse_of = root
				is_female = yes
				root.current_travel_plan ?= {
					scope:second = { is_travel_leader = yes }
				}
			}
		}
	}

	text = {
		localization_key = relation_travel_leader_father
		trigger = {
			scope:second = {
				is_spouse_of = root
				is_male = yes
				root.current_travel_plan ?= {
					scope:second = { is_travel_leader = yes }
				}
			}
		}
	}

	text = {
		localization_key = relation_travel_leader
		trigger = {
			root.current_travel_plan ?= {
				scope:second = { is_travel_leader = yes }
			}
		}
	}

	text = {
		localization_key = relation_daughter
		trigger = {
			scope:second = {
				is_female = yes
				is_child_of = root
			}
		}
	}

	text = {
		localization_key = relation_son
		trigger = {
			scope:second = {
				is_female = no
				is_child_of = root
			}
		}
	}
	
	text = {
		localization_key = relation_movement_leader
		trigger = {
			scope:second = {
				trigger_if = {
					limit = {
						any_character_situation = {
							situation_type = dynastic_cycle
						}
						government_has_flag = government_is_celestial
						root = { government_has_flag = government_is_celestial }
					}
				}
				is_any_movement_leader = yes
				top_participant_group:dynastic_cycle ?= root.top_participant_group:dynastic_cycle
			}
		}
	}

	text = {
		localization_key = relation_grandmother
		trigger = {
			scope:second = {
				is_female = yes
				is_grandparent_of = root
			}
		}
	}

	text = {
		localization_key = relation_grandfather
		trigger = {
			scope:second = {
				is_male = yes
				is_grandparent_of = root
			}
		}
	}

	text = {
		localization_key = relation_granddaughter
		trigger = {
			scope:second = {
				is_female = yes
				is_grandchild_of = root
			}
		}
	}

	text = {
		localization_key = relation_grandson
		trigger = {
			scope:second = {
				is_female = no
				is_grandchild_of = root
			}
		}
	}

	text = {
		localization_key = relation_half_sister
		trigger = {
			scope:second = {
				is_female = yes
				is_sibling_of = root
				NAND = {
					father ?= root.father
					mother ?= root.mother
				}
			}
		}
	}

	text = {
		localization_key = relation_half_brother
		trigger = {
			scope:second = {
				is_female = no
				is_sibling_of = root
				NAND = {
					father ?= root.father
					mother ?= root.mother
				}
			}
		}
	}

	text = {
		localization_key = relation_sister_nemesis
		trigger = {
			scope:second = {
				has_relation_nemesis = root
				is_female = yes
				any_sibling = {
					this = root
				}
			}
		}
	}

	text = {
		localization_key = relation_sister_rival
		trigger = {
			scope:second = {
				has_relation_rival = root
				NOT = { has_relation_nemesis = root }
				is_female = yes
				any_sibling = {
					this = root
				}
			}
		}
	}

	text = {
		localization_key = relation_brother_nemesis
		trigger = {
			scope:second = {
				has_relation_nemesis = root
				is_female = no
				any_sibling = {
					this = root
				}
			}
		}
	}

	text = {
		localization_key = relation_brother_rival
		trigger = {
			scope:second = {
				has_relation_rival = root
				NOT = { has_relation_nemesis = root }
				is_female = no
				any_sibling = {
					this = root
				}
			}
		}
	}

	text = {
		localization_key = relation_sister_best_friend
		trigger = {
			scope:second = {
				is_female = yes
				any_relation = {
					type = best_friend
					this = root
				}
				any_sibling = {
					this = root
				}
			}
		}
	}

	text = {
		localization_key = relation_sister_friend
		trigger = {
			scope:second = {
				is_female = yes
				any_relation = {
					type = friend
					this = root
				}
				any_sibling = {
					this = root
				}
			}
		}
	}

	text = {
		localization_key = relation_brother_best_friend
		trigger = {
			scope:second = {
				is_female = no
				any_relation = {
					type = best_friend
					this = root
				}
				any_sibling = {
					this = root
				}
			}
		}
	}

	text = {
		localization_key = relation_brother_friend
		trigger = {
			scope:second = {
				is_female = no
				any_relation = {
					type = friend
					this = root
				}
				any_sibling = {
					this = root
				}
			}
		}
	}

	text = {
		localization_key = relation_sister_bully
		trigger = {
			scope:second = {
				is_female = yes
				any_relation = {
					type = victim
					this = root
				}
				any_sibling = {
					this = root
				}
			}
		}
	}

	text = {
		localization_key = relation_brother_bully
		trigger = {
			scope:second = {
				is_female = no
				any_relation = {
					type = victim
					this = root
				}
				any_sibling = {
					this = root
				}
			}
		}
	}

	text = {
		localization_key = relation_sister_victim
		trigger = {
			scope:second = {
				is_female = yes
				any_relation = {
					type = bully
					this = root
				}
				any_sibling = {
					this = root
				}
			}
		}
	}

	text = {
		localization_key = relation_brother_victim
		trigger = {
			scope:second = {
				is_female = no
				any_relation = {
					type = bully
					this = root
				}
				any_sibling = {
					this = root
				}
			}
		}
	}

	text = {
		localization_key = relation_sister
		trigger = {
			scope:second = {
				is_female = yes
				is_sibling_of = root
			}
		}
	}

	text = {
		localization_key = relation_brother
		trigger = {
			scope:second = {
				is_female = no
				is_sibling_of = root
			}
		}
	}

	text = {
		localization_key = relation_niece
		trigger = {
			scope:second = {
				is_female = yes
				is_sibling_child_of_root_trigger = yes
			}
		}
	}

	text = {
		localization_key = relation_nephew
		trigger = {
			scope:second = {
				is_female = no
				is_sibling_child_of_root_trigger = yes
			}
		}
	}

	text = {
		localization_key = relation_aunt
		trigger = {
			scope:second = {
				is_female = yes
				is_parent_sibling_of_root_trigger = yes
			}
		}
	}

	text = {
		localization_key = relation_uncle
		trigger = {
			scope:second = {
				is_female = no
				is_parent_sibling_of_root_trigger = yes
			}
		}
	}

	text = {
		localization_key = relation_hostage
		trigger = {
			scope:second = {
				is_hostage = yes
				warden ?= root
			}
		}
	}

	text = {
		localization_key = relation_warden
		trigger = {
			is_hostage = yes
			warden ?= scope:second
		}
	}

	text = {
		localization_key = relation_concubine_female
		trigger = {
			scope:second = {
				is_female = yes
				any_consort = { this = root }
				is_concubine = yes
			}
		}
	}

	text = {
		localization_key = relation_concubine_male
		trigger = {
			scope:second = {
				is_male = yes
				any_consort = { this = root }
				is_concubine = yes
			}
		}
	}

	text = {
		localization_key = relation_religious_head
		trigger = {
			faith.religious_head = scope:second
		}
	}

	text = {
		localization_key = relation_great_grandfather
		trigger = {
			scope:second = {
				is_male = yes
				is_great_grandparent_of = root
			}
		}
	}

	text = {
		localization_key = relation_great_grandmother
		trigger = {
			scope:second = {
				is_female = yes
				is_great_grandparent_of = root
			}
		}
	}

	text = {
		localization_key = relation_greatgranddaughter
		trigger = {
			scope:second = {
				is_female = yes
				is_great_grandchild_of = root
			}
		}
	}

	text = {
		localization_key = relation_greatgrandson
		trigger = {
			scope:second = {
				is_female = no
				is_great_grandchild_of = root
			}
		}
	}
	
	text = {
		localization_key = relation_greatgreatgranddaughter
		trigger = {
			scope:second = {
				is_female = yes
				any_parent = {
					even_if_dead = yes
					is_great_grandchild_of = root
				}
			}
		}
	}

	text = {
		localization_key = relation_greatgreatgrandson
		trigger = {
			scope:second = {
				is_female = no
				any_parent = {
					even_if_dead = yes
					is_great_grandchild_of = root
				}
			}
		}
	}

	text = {
		localization_key = relation_motherinlaw
		trigger = {
			scope:second = {
				is_female = yes
				any_child = {
					is_spouse_of = root
				}
			}
		}
	}
	
	text = {
		localization_key = relation_fatherinlaw
		trigger = {
			scope:second = {
				is_male = yes
				any_child = {
					is_spouse_of = root
				}
			}
		}
	}

	text = {
		localization_key = daughter_in_law
		trigger = {
			scope:second = {
				is_female = yes
				any_spouse = {
					is_child_of = root
				}
			}
		}
	}

	text = {
		localization_key = son_in_law
		trigger = {
			scope:second = {
				is_female = no
				any_spouse = {
					is_child_of = root
				}
			}
		}
	}

	text = {
		localization_key = relation_cousin
		trigger = {
			scope:second = {
				is_male = yes
				is_cousin_of = root
			}
		}
	}

	text = {
		localization_key = relation_cousin_female
		trigger = {
			scope:second = {
				is_female = yes
				is_cousin_of = root
			}
		}
	}
	
	text = {
		localization_key = relation_great_uncle
		trigger = {
			scope:second = {
				is_male = yes
				is_great_aunt_uncle_of = { CHARACTER = root }
			}
		}
	}
	
	text = {
		localization_key = relation_great_aunt
		trigger = {
			scope:second = {
				is_female = yes
				is_great_aunt_uncle_of = { CHARACTER = root }
			}
		}
	}
	
	text = {
		localization_key = relation_great_nephew
		trigger = {
			scope:second = {
				is_male = yes
				is_great_nibling_of = { CHARACTER = root }
			}
		}
	}
	
	text = {
		localization_key = relation_great_niece
		trigger = {
			scope:second = {
				is_female = yes
				is_great_nibling_of = { CHARACTER = root }
			}
		}
	}

	text = {
		localization_key = relation_stepdaughter
		trigger = {
			scope:second = {
				is_female = yes
				any_parent = {
					any_spouse = {
						this = root
						NOT = { is_parent_of = scope:second }
					}
				}
			}
		}
	}

	text = {
		localization_key = relation_stepson
		trigger = {
			scope:second = {
				is_male = yes
				any_parent = {
					any_spouse = {
						this = root
						NOT = { is_parent_of = scope:second }
					}
				}
			}
		}
	}

	text = {
		localization_key = relation_stepsister
		trigger = {
			scope:second = {
				is_female = yes
				any_parent = {
					any_spouse = {
						any_child = {
							this = root
							NOT = { is_sibling_of = scope:second }
						}
					}
				}
			}
		}
	}

	text = {
		localization_key = relation_stepbrother
		trigger = {
			scope:second = {
				is_male = yes
				any_parent = {
					any_spouse = {
						any_child = {
							this = root
							NOT = { is_sibling_of = scope:second }
						}
					}
				}
			}
		}
	}

	text = {
		localization_key = relation_stepmother
		trigger = {
			scope:second = {
				is_female = yes
				any_spouse = {
					any_child = {
						this = root
						NOT = { is_child_of = scope:second }
					}
				}
			}
		}
	}

	text = {
		localization_key = relation_stepfather
		trigger = {
			scope:second = {
				is_male = yes
				any_spouse = {
					any_child = {
						this = root
						NOT = { is_child_of = scope:second }
					}
				}
			}
		}
	}

	text = {
		localization_key = relation_liege_female_soulmate
		trigger = {
			scope:second = {
				has_relation_soulmate = root
				is_female = yes
				any_vassal_or_below = {
					this = root
				}
			}
		}
	}

	text = {
		localization_key = relation_liege_female_lover
		trigger = {
			scope:second = {
				has_relation_lover = root
				is_female = yes
				any_vassal_or_below = {
					this = root
				}
				trigger_if = { # not reflected in has_RelationToMe_relation trigger
					limit = { has_secret_relation_lover = root }
					any_secret = {
						type = secret_lover
						secret_target = { this = root }
						local_player_knows_this_secret = yes
					}
				}
			}
		}
	}

	text = {
		localization_key = relation_liege_male_soulmate
		trigger = {
			scope:second = {
				has_relation_soulmate = root
				is_female = no
				any_vassal_or_below = {
					this = root
				}
			}
		}
	}

	text = {
		localization_key = relation_liege_male_lover
		trigger = {
			scope:second = {
				has_relation_lover = root
				is_female = no
				any_vassal_or_below = {
					this = root
				}
				trigger_if = { # not reflected in has_RelationToMe_relation trigger
					limit = { has_secret_relation_lover = root }
					any_secret = {
						type = secret_lover
						secret_target = { this = root }
						local_player_knows_this_secret = yes
					}
				}
			}
		}
	}

	text = {
		localization_key = relation_soulmate_female
		trigger = {
			scope:second = {
				OR = {
					any_relation = {
						type = soulmate
						this = root
					}
					any_memory = {
						memory_type = soulmate_died
						memory_participant:dead_relation ?= root
					}
				}
				is_female = yes
			}
		}
	}

	text = {
		localization_key = relation_lover_female
		trigger = {
			scope:second = {
				OR = {
					any_relation = {
						type = lover
						this = root
					}
					any_memory = {
						memory_type = lover_died
						memory_participant:dead_relation ?= root
					}
				}
				is_female = yes
				trigger_if = { # not reflected in has_RelationToMe_relation trigger
					limit = { has_secret_relation_lover = root }
					any_secret = {
						type = secret_lover
						secret_target = { this = root }
						local_player_knows_this_secret = yes
					}
				}
			}
		}
	}

	text = {
		localization_key = relation_soulmate_male
		trigger = {
			scope:second = {
				OR = {
					any_relation = {
						type = soulmate
						this = root
					}
					any_memory = {
						memory_type = soulmate_died
						memory_participant:dead_relation ?= root
					}
				}
				is_female = no
			}
		}
	}

	text = {
		localization_key = relation_lover_male
		trigger = {
			scope:second = {
				OR = {
					any_relation = {
						type = lover
						this = root
					}
					any_memory = {
						memory_type = lover_died
						memory_participant:dead_relation ?= root
					}
				}
				is_female = no
				trigger_if = { # not reflected in has_RelationToMe_relation trigger
					limit = { has_secret_relation_lover = root }
					any_secret = {
						type = secret_lover
						secret_target = { this = root }
						local_player_knows_this_secret = yes
					}
				}
			}
		}
	}

	text = {
		localization_key = relation_best_friend_female
		trigger = {
			scope:second = {
				OR = {
					has_relation_best_friend = root
					any_memory = {
						memory_type = best_friend_died
						memory_participant:dead_relation ?= root
					}
				}
				is_female = yes
			}
		}
	}

	text = {
		localization_key = relation_friend_female
		trigger = {
			scope:second = {
				OR = {
					has_relation_friend = root
					any_memory = {
						memory_type = best_friend_died
						memory_participant:dead_relation ?= root
					}
				}
				NOR = {
					has_relation_best_friend = root
					any_memory = {
						memory_type = best_friend_died
						memory_participant:dead_relation ?= root
					}
				}
				is_female = yes
			}
		}
	}

	text = {
		localization_key = relation_best_friend_male
		trigger = {
			scope:second = {
				OR = {
					has_relation_best_friend = root
					any_memory = {
						memory_type = best_friend_died
						memory_participant:dead_relation ?= root
					}
				}
				is_female = no
			}
		}
	}

	text = {
		localization_key = relation_friend_male
		trigger = {
			scope:second = {
				OR = {
					has_relation_friend = root
					any_memory = {
						memory_type = best_friend_died
						memory_participant:dead_relation ?= root
					}
				}
				NOR = {
					has_relation_best_friend = root
					any_memory = {
						memory_type = best_friend_died
						memory_participant:dead_relation ?= root
					}
				}
				is_female = no
			}
		}
	}

	text = {
		localization_key = relation_liege_female_nemesis
		trigger = {
			scope:second = {
				has_relation_nemesis = root
				is_female = yes
				any_vassal_or_below = {
					this = root
				}
			}
		}
	}

	text = {
		localization_key = relation_liege_female_rival
		trigger = {
			scope:second = {
				has_relation_rival = root
				NOT = { has_relation_nemesis = root }
				is_female = yes
				any_vassal_or_below = {
					this = root
				}
			}
		}
	}

	text = {
		localization_key = relation_liege_male_nemesis
		trigger = {
			scope:second = {
				has_relation_nemesis = root
				is_female = no
				any_vassal_or_below = {
					this = root
				}
			}
		}
	}

	text = {
		localization_key = relation_liege_male_rival
		trigger = {
			scope:second = {
				has_relation_rival = root
				NOT = { has_relation_nemesis = root }
				is_female = no
				any_vassal_or_below = {
					this = root
				}
			}
		}
	}

	text = {
		localization_key = relation_vassal_female_nemesis
		trigger = {
			scope:second = {
				is_female = yes
				has_relation_nemesis = root
			}
			any_vassal_or_below = {
				this = scope:second
			}
		}
	}

	text = {
		localization_key = relation_vassal_female_rival
		trigger = {
			scope:second = {
				is_female = yes
				has_relation_rival = root
				NOT = { has_relation_nemesis = root }
			}
			any_vassal_or_below = {
				this = scope:second
			}
		}
	}

	text = {
		localization_key = relation_vassal_male_nemesis
		trigger = {
			scope:second = {
				is_female = no
				has_relation_nemesis = root
			}
			any_vassal_or_below = {
				this = scope:second
			}
		}
	}

	text = {
		localization_key = relation_vassal_male_rival
		trigger = {
			scope:second = {
				is_female = no
				has_relation_rival = root
				NOT = { has_relation_nemesis = root }
			}
			any_vassal_or_below = {
				this = scope:second
			}
		}
	}

	text = {
		localization_key = relation_nemesis_female
		trigger = {
			scope:second = {
				OR = {
					any_relation = {
						type = nemesis
						this = root
					}
					any_memory = {
						memory_type = nemesis_died
						memory_participant:dead_relation ?= root
					}
				}
				is_female = yes
			}
		}
	}

	text = {
		localization_key = relation_rival_female
		trigger = {
			scope:second = {
				OR = {
					any_relation = {
						type = rival
						this = root
					}
					any_memory = {
						memory_type = rival_died
						memory_participant:dead_relation ?= root
					}
				}
				is_female = yes
			}
		}
	}

	text = {
		localization_key = relation_nemesis_male
		trigger = {
			scope:second = {
				OR = {
					any_relation = {
						type = nemesis
						this = root
					}
					any_memory = {
						memory_type = nemesis_died
						memory_participant:dead_relation ?= root
					}
				}
				is_female = no
			}
		}
	}

	text = {
		localization_key = relation_rival_male
		trigger = {
			scope:second = {
				OR = {
					any_relation = {
						type = rival
						this = root
					}
					any_memory = {
						memory_type = rival_died
						memory_participant:dead_relation ?= root
					}
				}
				is_female = no
			}
		}
	}

	text = {
		localization_key = relation_crush
		trigger = {
			any_relation = {
				type = crush
				this = scope:second
			}
		}
	}

	text = {
		localization_key = relation_bully
		trigger = {
			scope:second = {
				any_relation = {
					type = victim
					this = root
				}
			}
		}
	}

	text = {
		localization_key = relation_victim
		trigger = {
			scope:second = {
				any_relation = {
					type = bully
					this = root
				}
			}
		}
	}

	text = {
		localization_key = relation_ward
		trigger = {
			scope:second = {
				any_relation = {
					type = guardian
					this = root
				}
			}
		}
	}

	text = {
		localization_key = relation_guardian
		trigger = {
			scope:second = {
				any_relation = {
					type = ward
					this = root
				}
			}
		}
	}
	
	text = {
		localization_key = relation_disciple
		trigger = {
			scope:second = {
				any_relation = {
					type = elder
					this = root
				}
			}
		}
	}

	text = {
		localization_key = relation_elder
		trigger = {
			scope:second = {
				any_relation = {
					type = disciple
					this = root
				}
			}
		}
	}

	text = {
		localization_key = relation_foe
		trigger = {
			scope:second = {
				is_at_war_with = root
			}
		}
	}

	text = { #intrigue-mentor
		localization_key = relation_mentor
		trigger = {
			scope:second = {
				any_relation = {
					type = intrigue_student
					this = root
				}
			}
		}
	}

	text = { #intrigue-mentor
		localization_key = relation_student
		trigger = {
			scope:second = {
				any_relation = {
					type = intrigue_mentor
					this = root
				}
			}
		}
	}

	text = {
		localization_key = relation_mentor
		trigger = {
			scope:second = {
				any_relation = {
					type = student
					this = root
				}
			}
		}
	}

	text = {
		localization_key = relation_student
		trigger = {
			scope:second = {
				any_relation = {
					type = mentor
					this = root
				}
			}
		}
	}

	text = {
		localization_key = relation_sisterinlaw
		trigger = {
			scope:second = {
				is_female = yes
				is_sibling_in_law_of = { CHARACTER = root }
			}
		}
	}

	text = {
		localization_key = relation_brotherinlaw
		trigger = {
			scope:second = {
				is_female = no
				is_sibling_in_law_of = { CHARACTER = root }
			}
		}
	}

	text = {
		localization_key = relation_cousininlaw_female
		trigger = {
			scope:second = {
				is_female = yes
				is_cousin_in_law_of = { CHARACTER = root }
			}
		}
	}

	text = {
		localization_key = relation_cousininlaw_male
		trigger = {
			scope:second = {
				is_female = no
				is_cousin_in_law_of = { CHARACTER = root }
			}
		}
	}

	text = {
		localization_key = relation_auntinlaw
		trigger = {
			scope:second = {
				is_female = yes
				is_aunt_uncle_in_law_of = { CHARACTER = root }
			}
		}
	}

	text = {
		localization_key = relation_uncleinlaw
		trigger = {
			scope:second = {
				is_female = no
				is_aunt_uncle_in_law_of = { CHARACTER = root }
			}
		}
	}

	text = {
		localization_key = relation_grandmotherinlaw
		trigger = {
			scope:second = {
				is_female = yes
				any_child = {
					even_if_dead = yes
					any_child = { is_spouse_of = root }
				}
			}
		}
	}

	text = {
		localization_key = relation_grandfatherinlaw
		trigger = {
			scope:second = {
				is_female = no
				any_child = {
					even_if_dead = yes
					any_child = { is_spouse_of = root }
				}
			}
		}
	}

	text = {
		localization_key = relation_great_grandmotherinlaw
		trigger = {
			scope:second = {
				is_female = yes
				any_child = {
					even_if_dead = yes
					any_child = {
						even_if_dead = yes
						any_child = { is_spouse_of = root }
					}
				}
			}
		}
	}

	text = {
		localization_key = relation_great_grandfatherinlaw
		trigger = {
			scope:second = {
				is_female = no
				any_child = {
					even_if_dead = yes
					any_child = {
						even_if_dead = yes
						any_child = { is_spouse_of = root }
					}
				}
			}
		}
	}

	text = {
		localization_key = relation_granddaughterinlaw
		trigger = {
			scope:second = {
				is_female = yes
				is_granddaughterson_in_law_of_root_trigger = yes
			}
		}
	}

	text = {
		localization_key = relation_grandsoninlaw
		trigger = {
			scope:second = {
				is_female = no
				is_granddaughterson_in_law_of_root_trigger = yes
			}
		}
	}

	text = {
		localization_key = relation_great_granddaughterinlaw
		trigger = {
			scope:second = {
				is_female = yes
				is_great_granddaughterson_in_law_of_root_trigger = yes
			}
		}
	}

	text = {
		localization_key = relation_great_grandsoninlaw
		trigger = {
			scope:second = {
				is_female = no
				is_great_granddaughterson_in_law_of_root_trigger = yes
			}
		}
	}

	text = {
		localization_key = relation_nieceinlaw
		trigger = {
			scope:second = {
				is_female = yes
				is_nibling_in_law_of = { CHARACTER = root }
			}
		}
	}

	text = {
		localization_key = relation_nephewinlaw
		trigger = {
			scope:second = {
				is_female = no
				is_nibling_in_law_of = { CHARACTER = root }
			}
		}
	}
	
	text = {
		localization_key = relation_ceremonial_liege_female
		trigger = {
			scope:second = {
				is_female = yes
				top_liege = root.top_liege
				tgp_is_ceremonial_liege_trigger = yes
			}
		}
	}

	text = {
		localization_key = relation_ceremonial_liege_male
		trigger = {
			scope:second = {
				is_female = no
				top_liege = root.top_liege
				tgp_is_ceremonial_liege_trigger = yes
			}
		}
	}

	text = {
		localization_key = relation_liege_female
		trigger = {
			scope:second = {
				is_female = yes
				OR = {
					any_vassal_or_below = {
						this = root
					}
					any_courtier = {
						this = root
					}
				}
			}
		}
	}

	text = {
		localization_key = relation_liege_male
		trigger = {
			scope:second = {
				is_female = no
				OR = {
					any_vassal_or_below = {
						this = root
					}
					any_courtier = {
						this = root
					}
				}
			}
		}
	}
	
	text = {
		localization_key = relation_suzerain
		trigger = {
			scope:second = {
				any_tributary = { this = root }
			}
		}
	}

	text = {
		localization_key = relation_councillor_female
		trigger = {
			scope:second = {
				is_female = yes
				is_councillor_of = root
			}
		}
	}

	text = {
		localization_key = relation_councillor_male
		trigger = {
			scope:second = {
				is_female = no
				is_councillor_of = root
			}
		}
	}

	text = {
		localization_key = relation_court_physician_female
		trigger = {
			scope:second = {
				is_female = yes
				has_court_position = court_physician_court_position
				is_court_position_employer = {
					court_position = court_physician_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_court_physician_male
		trigger = {
			scope:second = {
				is_male = yes
				has_court_position = court_physician_court_position
				is_court_position_employer = {
					court_position = court_physician_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_keeper_of_swans_female
		trigger = {
			scope:second = {
				is_female = yes
				has_court_position = keeper_of_swans_court_position
				is_court_position_employer = {
					court_position = keeper_of_swans_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_keeper_of_swans_male
		trigger = {
			scope:second = {
				is_male = yes
				has_court_position = keeper_of_swans_court_position
				is_court_position_employer = {
					court_position = keeper_of_swans_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_travel_leader_female
		trigger = {
			scope:second = {
				is_female = yes
				has_court_position = travel_leader_court_position
				is_court_position_employer = {
					court_position = travel_leader_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_travel_leader_male
		trigger = {
			scope:second = {
				is_male = yes
				has_court_position = travel_leader_court_position
				is_court_position_employer = {
					court_position = travel_leader_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_master_of_horse_female
		trigger = {
			scope:second = {
				is_female = yes
				has_court_position = master_of_horse_court_position
				is_court_position_employer = {
					court_position = master_of_horse_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_master_of_horse_male
		trigger = {
			scope:second = {
				is_male = yes
				has_court_position = master_of_horse_court_position
				is_court_position_employer = {
					court_position = master_of_horse_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_court_jester_female
		trigger = {
			scope:second = {
				is_female = yes
				has_court_position = court_jester_court_position
				is_court_position_employer = {
					court_position = court_jester_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_court_jester_male
		trigger = {
			scope:second = {
				is_male = yes
				has_court_position = court_jester_court_position
				is_court_position_employer = {
					court_position = court_jester_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_master_of_hunt_female
		trigger = {
			scope:second = {
				is_female = yes
				has_court_position = master_of_hunt_court_position
				is_court_position_employer = {
					court_position = master_of_hunt_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_master_of_hunt_male
		trigger = {
			scope:second = {
				is_male = yes
				has_court_position = master_of_hunt_court_position
				is_court_position_employer = {
					court_position = master_of_hunt_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_high_almoner_female
		trigger = {
			scope:second = {
				is_female = yes
				has_court_position = high_almoner_court_position
				is_court_position_employer = {
					court_position = high_almoner_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_high_almoner_male
		trigger = {
			scope:second = {
				is_male = yes
				has_court_position = high_almoner_court_position
				is_court_position_employer = {
					court_position = high_almoner_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_cupbearer_female
		trigger = {
			scope:second = {
				is_female = yes
				has_court_position = cupbearer_court_position
				is_court_position_employer = {
					court_position = cupbearer_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_cupbearer_male
		trigger = {
			scope:second = {
				is_male = yes
				has_court_position = cupbearer_court_position
				is_court_position_employer = {
					court_position = cupbearer_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_seneschal_female
		trigger = {
			scope:second = {
				is_female = yes
				has_court_position = seneschal_court_position
				is_court_position_employer = {
					court_position = seneschal_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_seneschal_male
		trigger = {
			scope:second = {
				is_male = yes
				has_court_position = seneschal_court_position
				is_court_position_employer = {
					court_position = seneschal_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_antiquarian_female
		trigger = {
			scope:second = {
				is_female = yes
				has_court_position = antiquarian_court_position
				is_court_position_employer = {
					court_position = antiquarian_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_antiquarian_male
		trigger = {
			scope:second = {
				is_male = yes
				has_court_position = antiquarian_court_position
				is_court_position_employer = {
					court_position = antiquarian_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_court_tutor_female
		trigger = {
			scope:second = {
				is_female = yes
				has_court_position = court_tutor_court_position
				is_court_position_employer = {
					court_position = court_tutor_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_court_tutor_male
		trigger = {
			scope:second = {
				is_male = yes
				has_court_position = court_tutor_court_position
				is_court_position_employer = {
					court_position = court_tutor_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_royal_architect_female
		trigger = {
			scope:second = {
				is_female = yes
				has_court_position = royal_architect_court_position
				is_court_position_employer = {
					court_position = royal_architect_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_royal_architect_male
		trigger = {
			scope:second = {
				is_male = yes
				has_court_position = royal_architect_court_position
				is_court_position_employer = {
					court_position = royal_architect_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_court_poet_female
		trigger = {
			scope:second = {
				is_female = yes
				has_court_position = court_poet_court_position
				is_court_position_employer = {
					court_position = court_poet_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_court_poet_male
		trigger = {
			scope:second = {
				is_male = yes
				has_court_position = court_poet_court_position
				is_court_position_employer = {
					court_position = court_poet_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_bodyguard_female
		trigger = {
			scope:second = {
				is_female = yes
				has_court_position = bodyguard_court_position
				is_court_position_employer = {
					court_position = bodyguard_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_bodyguard_male
		trigger = {
			scope:second = {
				is_male = yes
				has_court_position = bodyguard_court_position
				is_court_position_employer = {
					court_position = bodyguard_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_champion_female
		trigger = {
			scope:second = {
				is_female = yes
				has_court_position = champion_court_position
				is_court_position_employer = {
					court_position = champion_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_champion_male
		trigger = {
			scope:second = {
				is_male = yes
				has_court_position = champion_court_position
				is_court_position_employer = {
					court_position = champion_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_court_musician_female
		trigger = {
			scope:second = {
				is_female = yes
				has_court_position = court_musician_court_position
				is_court_position_employer = {
					court_position = court_musician_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_court_musician_male
		trigger = {
			scope:second = {
				is_male = yes
				has_court_position = court_musician_court_position
				is_court_position_employer = {
					court_position = court_musician_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_food_taster_female
		trigger = {
			scope:second = {
				is_female = yes
				has_court_position = food_taster_court_position
				is_court_position_employer = {
					court_position = food_taster_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_food_taster_male
		trigger = {
			scope:second = {
				is_male = yes
				has_court_position = food_taster_court_position
				is_court_position_employer = {
					court_position = food_taster_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_lady_in_waiting_female
		trigger = {
			scope:second = {
				is_female = yes
				has_court_position = lady_in_waiting_court_position
				is_court_position_employer = {
					court_position = lady_in_waiting_court_position
					who = root
				}
			}
		}
	}

	text = { #Shouldn't happen, but who knows ¯\_(ツ)_/¯
		localization_key = relation_lady_in_waiting_male
		trigger = {
			scope:second = {
				is_male = yes
				has_court_position = lady_in_waiting_court_position
				is_court_position_employer = {
					court_position = lady_in_waiting_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_garuda_female
		trigger = {
			scope:second = {
				is_female = yes
				has_court_position = garuda_court_position
				is_court_position_employer = {
					court_position = garuda_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_garuda_male
		trigger = {
			scope:second = {
				is_male = yes
				has_court_position = garuda_court_position
				is_court_position_employer = {
					court_position = garuda_court_position
					who = root
				}
			}
		}
	}

	text = { #Shouldn't happen, but who knows ¯\_(ツ)_/¯
		localization_key = relation_chief_eunuch_female
		trigger = {
			scope:second = {
				is_female = yes
				has_court_position = chief_eunuch_court_position
				is_court_position_employer = {
					court_position = chief_eunuch_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_chief_eunuch_male
		trigger = {
			scope:second = {
				is_male = yes
				has_court_position = chief_eunuch_court_position
				is_court_position_employer = {
					court_position = chief_eunuch_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_court_gardener_female
		trigger = {
			scope:second = {
				is_female = yes
				has_court_position = court_gardener_court_position
				is_court_position_employer = {
					court_position = court_gardener_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_court_gardener_male
		trigger = {
			scope:second = {
				is_male = yes
				has_court_position = court_gardener_court_position
				is_court_position_employer = {
					court_position = court_gardener_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_chief_qadi_female
		trigger = {
			scope:second = {
				is_female = yes
				has_court_position = chief_qadi_court_position
				is_court_position_employer = {
					court_position = chief_qadi_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_chief_qadi_male
		trigger = {
			scope:second = {
				is_male = yes
				has_court_position = chief_qadi_court_position
				is_court_position_employer = {
					court_position = chief_qadi_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_wet_nurse_female
		trigger = {
			scope:second = {
				is_female = yes
				has_court_position = wet_nurse_court_position
				is_court_position_employer = {
					court_position = wet_nurse_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_akolouthos_male
		trigger = {
			scope:second = {
				is_male = yes
				has_court_position = akolouthos_court_position
				is_court_position_employer = {
					court_position = akolouthos_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_akolouthos_female
		trigger = {
			scope:second = {
				is_female = yes
				has_court_position = akolouthos_court_position
				is_court_position_employer = {
					court_position = akolouthos_court_position
					who = root
				}
			}
		}
	}
	
	text = {
		localization_key = relation_court_astrologer_male
		trigger = {
			scope:second = { is_male = yes }
			has_court_position = court_astrologer_court_position
			is_court_position_employer = {
		        court_position = court_astrologer_court_position
		        who = root
		    }
		}
	}
	
	text = {
		localization_key = relation_court_astrologer_female
		trigger = {
			scope:second = { is_female = yes }
			has_court_position = court_astrologer_court_position
			is_court_position_employer = {
		        court_position = court_astrologer_court_position
		        who = root
		    }
		}
	}

	text = { #Shouldn't happen, but who knows ¯\_(ツ)_/¯
		localization_key = relation_wet_nurse_male
		trigger = {
			scope:second = {
				is_male = yes
				has_court_position = wet_nurse_court_position
				is_court_position_employer = {
					court_position = wet_nurse_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_vassal_female
		trigger = {
			scope:second = {
				is_female = yes
			}
			any_vassal_or_below = {
				this = scope:second
			}
		}
	}

	text = {
		localization_key = relation_vassal_male
		trigger = {
			scope:second = {
				is_female = no
			}
			any_vassal_or_below = {
				this = scope:second
			}
		}
	}
	
	text = {
		localization_key = relation_fellow_subject_female
		trigger = {
			scope:second = {
				is_female = yes
				top_liege != this	
			}
			top_liege != this
			liege = scope:second.liege
			top_liege = {
				has_government = celestial_government
			}
		}
	}

	text = {
		localization_key = relation_fellow_subject_male
		trigger = {
			scope:second = {
				is_female = no
				top_liege != this	
			}
			top_liege != this
			liege = scope:second.liege
			top_liege = {
				has_government = celestial_government
			}
		}
	}

	text = {
		localization_key = relation_fellow_vassal_female
		trigger = {
			scope:second = {
				is_female = yes
				top_liege != this
			}
			top_liege != this
			liege = scope:second.liege
		}
	}

	text = {
		localization_key = relation_fellow_vassal_male
		trigger = {
			scope:second = {
				is_female = no
				top_liege != this
			}
			top_liege != this
			liege = scope:second.liege
		}
	}

	text = {
		localization_key = relation_knight
		trigger = {
			scope:second = { is_knight_of = root }
		}
	}

	text = {
		localization_key = relation_ally
		trigger = {
			scope:second = {
				is_allied_to = root
			}
		}
	}

	text = {
		localization_key = relation_kinswoman
		trigger = {
			scope:second = {
				is_female = yes
				is_lowborn = no
			}
			scope:second.dynasty = root.dynasty
		}
	}

	text = {
		localization_key = relation_kinsman
		trigger = {
			scope:second = {
				is_male = yes
				is_lowborn = no
			}
			scope:second.dynasty = root.dynasty
		}
	}

	text = {
		localization_key = relation_inspired_character_female
		trigger = {
			scope:second = {
				is_courtier_of = root
				OR = {
					inspiration ?= {
						inspiration_sponsor = { this = root }
					}
					AND = {
						exists = var:created_artifact_for
						var:created_artifact_for = root
					}
				}
				is_female = yes
			}
		}
	}
	text = {
		localization_key = relation_inspired_character_male
		trigger = {
			scope:second = {
				is_courtier_of = root
				OR = {
					inspiration ?= {
						inspiration_sponsor = { this = root }
					}
					AND = {
						exists = var:created_artifact_for
						var:created_artifact_for = root
					}
				}
				is_male = yes
			}
		}
	}

	text = {
		localization_key = relation_follower_female
		trigger = {
			is_landed_or_landless_administrative = no
			scope:second = {
				is_courtier_of = root
				is_female = yes
			}
		}
	}

	text = {
		localization_key = relation_follower_male
		trigger = {
			is_landed_or_landless_administrative = no
			scope:second = {
				is_courtier_of = root
				is_male = yes
			}
		}
	}

	text = {
		localization_key = relation_courtier_female
		trigger = {
			is_landed_or_landless_administrative = yes
			scope:second = {
				is_courtier_of = root
				is_female = yes
			}
		}
	}

	text = {
		localization_key = relation_courtier_male
		trigger = {
			is_landed_or_landless_administrative = yes
			scope:second = {
				is_courtier_of = root
				is_male = yes
			}
		}
	}

	text = {
		localization_key = follower_female
		trigger = {
			has_government = landless_adventurer_government
			scope:second = {
				is_courtier_of = root
				is_female = yes
			}
		}
	}

	text = {
		localization_key = follower_male
		trigger = {
			has_government = landless_adventurer_government
			scope:second = {
				is_courtier_of = root
				is_male = yes
			}
		}
	}

	text = {
		localization_key = relation_peasant_affair_female
		trigger = {
			any_owned_story = {
				type = story_peasant_affair
				var:peasant_character = {
					this = scope:second
					is_female = yes
				}
			}
		}
	}

	text = {
		localization_key = relation_peasant_affair_male
		trigger = {
			any_owned_story = {
				type = story_peasant_affair
				var:peasant_character = {
					this = scope:second
					is_male = yes
				}
			}
		}
	}

	text = {
		localization_key = relation_agent
		trigger = {
			any_scheme = {
				scheme_is_character_agent = scope:second
			}
		}
	}

	text = {
		localization_key = relation_host_female
		trigger = {
			host ?= scope:second
			scope:second = { is_female = yes }
		}
	}

	text = {
		localization_key = relation_host_male
		trigger = {
			host ?= scope:second
			scope:second = { is_male = yes }
		}
	}

	text = {
		localization_key = relation_prisoner_female
		trigger = {
			scope:second = {
				is_female = yes
				is_imprisoned_by = root
			}
		}
	}

	text = {
		localization_key = relation_prisoner_male
		trigger = {
			scope:second = {
				is_male = yes
				is_imprisoned_by = root
			}
		}
	}

	text = {
		localization_key = relation_jailer_female
		trigger = {
			is_imprisoned_by = scope:second
			scope:second = {
				is_female = yes
			}
		}
	}

	text = {
		localization_key = relation_jailer_male
		trigger = {
			is_imprisoned_by = scope:second
			scope:second = {
				is_male = yes
			}
		}
	}

	text = {
		localization_key = relation_guest_female
		trigger = {
			scope:second = {
				is_female = yes
				host ?= root
			}
		}
	}

	text = {
		localization_key = relation_guest_male
		trigger = {
			scope:second = {
				is_male = yes
				host ?= root
			}
		}
	}

	text = {
		localization_key = relation_old_foe_female
		trigger = {
			root = {
				any_memory = {
					OR = {
						has_memory_type = war_won
						has_memory_type = war_lost
					}
					any_memory_participant = {
						this = scope:second
					}
				}
			}
			scope:second = {
				is_female = yes
			}
		}
	}

	text = {
		localization_key = relation_old_foe_male
		trigger = {
			root = {
				any_memory = {
					OR = {
						has_memory_type = war_won
						has_memory_type = war_lost
					}
					any_memory_participant = {
						this = scope:second
					}
				}
			}
			scope:second = {
				is_male = yes
			}
		}
	}

	text = {
		localization_key = relation_fellow_pilgrim_female
		trigger = {
			root = {
				current_travel_plan ?= {
					travel_leader.involved_activity ?= {
						has_activity_type = activity_pilgrimage
					}
					any_entourage_character = {
						this = scope:second
					}
				}
			}
			scope:second = {
				is_female = yes
			}
		}
	}

	text = {
		localization_key = relation_fellow_pilgrim_male
		trigger = {
			root = {
				current_travel_plan ?= {
					travel_leader.involved_activity ?= {
						has_activity_type = activity_pilgrimage
					}
					any_entourage_character = {
						this = scope:second
					}
				}
			}
			scope:second = {
				is_male = yes
			}
		}
	}

	text = {
		localization_key = relation_fellow_traveler_female
		trigger = {
			root = {
				current_travel_plan ?= {
					any_entourage_character = {
						this = scope:second
					}
				}
			}
			scope:second = {
				is_female = yes
			}
		}
	}

	text = {
		localization_key = relation_fellow_traveler_male
		trigger = {
			root = {
				current_travel_plan ?= {
					any_entourage_character = {
						this = scope:second
					}
				}
			}
			scope:second = {
				is_male = yes
			}
		}
	}

	text = {
		localization_key = relation_fellow_contestant_female
		trigger = {
			involved_activity ?= {
				has_activity_type = activity_tournament
				any_guest_subset_current_phase = { #you're participating
					name = contestant
					this = root
				}
				any_guest_subset_current_phase = { #they are participating
					name = contestant
					this = scope:second
				}
			}
			scope:second = {
				is_female = yes
			}
		}
	}

	text = {
		localization_key = relation_fellow_contestant_male
		trigger = {
			involved_activity ?= {
				has_activity_type = activity_tournament
				any_guest_subset_current_phase = { #you're participating
					name = contestant
					this = root
				}
				any_guest_subset_current_phase = { #they are participating
					name = contestant
					this = scope:second
				}
			}
			scope:second = {
				is_male = yes
			}
		}
	}

	text = {
		localization_key = relation_fellow_attendee_female
		trigger = {
			involved_activity ?= {
				has_activity_type = activity_tournament
				any_attending_character = { this = scope:second }
			}
			scope:second = {
				is_female = yes
			}
		}
	}

	text = {
		localization_key = relation_fellow_attendee_male
		trigger = {
			involved_activity ?= {
				has_activity_type = activity_tournament
				any_attending_character = { this = scope:second }
			}
			scope:second = {
				is_male = yes
			}
		}
	}
	
	text = {
		localization_key = relation_servant_of_china_female
		trigger = {
			scope:second = {
				top_liege != this
				top_liege = {
					has_government = celestial_government
					NOT = { this = root }
				}
				is_female = yes
			}
		}
	}

	text = {
		localization_key = relation_servant_of_china_male
		trigger = {
			scope:second = {
				top_liege != this
				top_liege = {
					has_government = celestial_government
					NOT = { this = root }
				}
				is_male = yes
			}
		}
	}

	text = {
		localization_key = relation_acquaintance_female
		trigger = {
			scope:second = {
				is_female = yes
			}
		}
	}

	text = {
		localization_key = relation_acquaintance_male
		trigger = {
			scope:second = {
				is_male = yes
			}
		}
	}
}

LMF_RelationToMePossessive = {
	type = character

	text = {
		localization_key = CHARACTER_NAME_MY
		trigger = { scope:second = root }
	}

	text = {
		localization_key = relation_motherwife_possessive
		trigger = {
			scope:second = {
				OR = {
					this = root.mother
					this = root.mother.mother
					this = root.father.mother
				}
				any_spouse = { this = root }
			}
		}
	}

	text = {
		localization_key = relation_mother_concubine_possessive
		trigger = {
			scope:second = {
				OR = {
					this = root.mother
					this = root.mother.mother
					this = root.father.mother
				}
				any_consort = { this = root }
				is_concubine = yes
			}
		}
	}

	text = {
		localization_key = relation_sisterwife_possessive
		trigger = {
			scope:second = {
				any_sibling = { this = root }
				is_female = yes
				any_spouse = { this = root }
			}
		}
	}

	text = {
		localization_key = relation_sister_concubine_possessive
		trigger = {
			scope:second = {
				any_sibling = { this = root }
				is_female = yes
				any_consort = { this = root }
				is_concubine = yes
			}
		}
	}

	text = {
		localization_key = relation_daughterwife_possessive
		trigger = {
			scope:second = {
				OR = {
					any_parent = { this = root }
					any_parent = { any_parent = { this = root } }
				}
				is_female = yes
				any_spouse = { this = root }
			}
		}
	}

	text = {
		localization_key = relation_daughter_concubine_possessive
		trigger = {
			scope:second = {
				OR = {
					any_parent = { this = root }
					any_parent = { any_parent = { this = root } }
				}
				any_consort = { this = root }
				is_female = yes
				is_concubine = yes
			}
		}
	}

	text = {
		localization_key = relation_fatherhusband_possessive
		trigger = {
			scope:second = {
				OR = {
					this = root.father
					this = root.father.father
					this = root.mother.father
				}
				any_spouse = { this = root }
			}
		}
	}

	text = {
		localization_key = relation_father_consort_possessive
		trigger = {
			scope:second = {
				OR = {
					this = root.father
					this = root.father.father
					this = root.mother.father
				}
				any_consort = { this = root }
				is_concubine = yes
			}
		}
	}

	text = {
		localization_key = relation_brotherhusband_possessive
		trigger = {
			scope:second = {
				any_sibling = { this = root }
				is_female = no
				any_spouse = { this = root }
			}
		}
	}

	text = {
		localization_key = relation_brother_consort_possessive
		trigger = {
			scope:second = {
				any_sibling = { this = root }
				is_female = no
				any_consort = { this = root }
				is_concubine = yes
			}
		}
	}

	text = {
		localization_key = relation_sonhusband_possessive
		trigger = {
			scope:second = {
				OR = {
					any_parent = { this = root }
					any_parent = {
						even_if_dead = yes
						any_parent = {
							this = root
						}
					}
				}
				is_female = no
				any_spouse = { this = root }
			}
		}
	}

	text = {
		localization_key = relation_son_consort_possessive
		trigger = {
			scope:second = {
				OR = {
					any_parent = { this = root }
					any_parent = {
						even_if_dead = yes
						any_parent = {
							this = root
						}
					}
				}
				is_female = no
				any_consort = { this = root }
				is_concubine = yes
			}
		}
	}

	text = {
		localization_key = relation_wife_possessive
		trigger = {
			scope:second = {
				is_female = yes
				any_spouse = {
					even_if_dead = yes
					this = root
				}
				is_alive = yes
				is_concubine = no
			}
		}
	}

	text = {
		localization_key = relation_husband_possessive
		trigger = {
			scope:second = {
				is_male = yes
				any_spouse = {
					even_if_dead = yes
					this = root
				}
				is_alive = yes
				is_concubine = no
			}
		}
	}

	text = {
		localization_key = relation_wife_departed_possessive
		trigger = {
			scope:second = {
				is_female = yes
				any_spouse = {
					even_if_dead = yes
					this = root
				}
				is_alive = no
				is_concubine = no
			}
		}
	}

	text = {
		localization_key = relation_husband_departed_possessive
		trigger = {
			scope:second = {
				is_male = yes
				any_spouse = {
					even_if_dead = yes
					this = root
				}
				is_alive = no
				is_concubine = no
			}
		}
	}

	text = {
		localization_key = relation_mother_possessive
		trigger = {
			scope:second = {
				is_female = yes
				any_child = {
					this = root
				}
			}
		}
	}

	text = {
		localization_key = relation_father_possessive
		trigger = {
			scope:second = {
				is_female = no
				any_child = {
					this = root
				}
			}
		}
	}

	text = {
		localization_key = relation_daughter_possessive
		trigger = {
			scope:second = {
				is_female = yes
				is_child_of = root
			}
		}
	}

	text = {
		localization_key = relation_son_possessive
		trigger = {
			scope:second = {
				is_female = no
				is_child_of = root
			}
		}
	}

	text = {
		localization_key = relation_half_sister_possessive
		trigger = {
			scope:second = {
				is_female = yes
				is_sibling_of = root
				NAND = {
					father ?= root.father
					mother ?= root.mother
				}
			}
		}
	}

	text = {
		localization_key = relation_half_brother_possessive
		trigger = {
			scope:second = {
				is_female = no
				is_sibling_of = root
				NAND = {
					father ?= root.father
					mother ?= root.mother
				}
			}
		}
	}

	text = {
		localization_key = relation_sister_possessive
		trigger = {
			scope:second = {
				is_female = yes
				any_sibling = {
					this = root
				}
			}
		}
	}

	text = {
		localization_key = relation_brother_possessive
		trigger = {
			scope:second = {
				is_female = no
				any_sibling = {
					this = root
				}
			}
		}
	}

	text = {
		localization_key = relation_granddaughter_possessive
		trigger = {
			scope:second = {
				is_female = yes
				is_grandchild_of = root
			}
		}
	}

	text = {
		localization_key = relation_grandson_possessive
		trigger = {
			scope:second = {
				is_female = no
				is_grandchild_of = root
			}
		}
	}
	
	text = {
		localization_key = relation_greatgranddaughter_possessive
		trigger = {
			scope:second = {
				is_female = yes
				any_parent = {
					even_if_dead = yes
					is_great_grandchild_of = root
				}
			}
		}
	}

	text = {
		localization_key = relation_greatgrandson_possessive
		trigger = {
			scope:second = {
				is_female = no
				any_parent = {
					even_if_dead = yes
					is_great_grandchild_of = root
				}
			}
		}
	}

	text = {
		localization_key = relation_niece_possessive
		trigger = {
			scope:second = {
				is_female = yes
				is_nibling_of = root
			}
		}
	}

	text = {
		localization_key = relation_nephew_possessive
		trigger = {
			scope:second = {
				is_female = no
				is_nibling_of = root
			}
		}
	}

	text = {
		localization_key = relation_aunt_possessive
		trigger = {
			scope:second = {
				is_female = yes
				is_uncle_or_aunt_of = root
			}
		}
	}

	text = {
		localization_key = relation_uncle_possessive
		trigger = {
			scope:second = {
				is_female = no
				is_uncle_or_aunt_of = root
			}
		}
	}

	text = {
		localization_key = relation_hostage_possessive
		trigger = {
			scope:second = {
				is_hostage = yes
				warden ?= root
			}
		}
	}

	text = {
		localization_key = relation_warden_possessive
		trigger = {
			is_hostage = yes
			warden ?= scope:second
		}
	}

	text = {
		localization_key = relation_concubine_female_possessive
		trigger = {
			scope:second = {
				is_female = yes
				any_spouse = { this = root }
				is_concubine = yes
			}
		}
	}

	text = {
		localization_key = relation_concubine_male_possessive
		trigger = {
			scope:second = {
				is_male = yes
				any_spouse = { this = root }
				is_concubine = yes
			}
		}
	}

	text = { #Both grandparents and great grandparents
		localization_key = relation_grandmother_possessive
		trigger = {
			scope:second = {
				is_female = yes
				OR = {
					any_child = {
						even_if_dead = yes
						any_child = {
							this = root
						}
					}
					any_child = {
						even_if_dead = yes
						any_child = {
							even_if_dead = yes
							any_child = {
								this = root
							}
						}
					}
				}
			}
		}
	}

	text = { #Both grandparents and great grandparents
		localization_key = relation_grandfather_possessive
		trigger = {
			scope:second = {
				is_female = no
				OR = {
					any_child = {
						even_if_dead = yes
						any_child = {
							this = root
						}
					}
					any_child = {
						even_if_dead = yes
						any_child = {
							even_if_dead = yes
							any_child = {
								this = root
							}
						}
					}
				}
			}
		}
	}

	text = {
		localization_key = relation_religious_head_possessive
		trigger = {
			faith.religious_head = scope:second
		}
	}

	text = {
		localization_key = relation_greatgranddaughter_possessive
		trigger = {
			scope:second = {
				is_female = yes
				any_parent = {
					even_if_dead = yes
					any_parent = {
						even_if_dead = yes
						any_parent = {
							this = root
						}
					}
				}
			}
		}
	}

	text = {
		localization_key = relation_greatgrandson_possessive
		trigger = {
			scope:second = {
				is_female = no
				any_parent = {
					even_if_dead = yes
					any_parent = {
						even_if_dead = yes
						any_parent = {
							this = root
						}
					}
				}
			}
		}
	}

	text = {
		localization_key = relation_stepdaughter_possessive
		trigger = {
			scope:second = {
				is_female = yes
				any_parent = {
					any_spouse = {
						this = root
						NOT = { is_parent_of = scope:second }
					}
				}
			}
		}
	}

	text = {
		localization_key = relation_stepson_possessive
		trigger = {
			scope:second = {
				is_male = yes
				any_parent = {
					any_spouse = {
						this = root
						NOT = { is_parent_of = scope:second }
					}
				}
			}
		}
	}

	text = {
		localization_key = relation_stepsister_possessive
		trigger = {
			scope:second = {
				is_female = yes
				any_parent = {
					any_spouse = {
						any_child = {
							this = root
							NOT = { is_sibling_of = scope:second }
						}
					}
				}
			}
		}
	}

	text = {
		localization_key = relation_stepbrother_possessive
		trigger = {
			scope:second = {
				is_male = yes
				any_parent = {
					any_spouse = {
						any_child = {
							this = root
							NOT = { is_sibling_of = scope:second }
						}
					}
				}
			}
		}
	}

	text = {
		localization_key = relation_stepmother_possessive
		trigger = {
			scope:second = {
				is_female = yes
				any_spouse = {
					any_child = {
						this = root
						NOT = { is_child_of = scope:second }
					}
				}
			}
		}
	}

	text = {
		localization_key = relation_stepfather_possessive
		trigger = {
			scope:second = {
				is_male = yes
				any_spouse = {
					any_child = {
						this = root
						NOT = { is_child_of = scope:second }
					}
				}
			}
		}
	}

	text = {
		localization_key = relation_motherinlaw_possessive
		trigger = {
			scope:second = {
				is_female = yes
				any_child = {
					is_spouse_of = root
				}
			}
		}
	}
	
	text = {
		localization_key = relation_fatherinlaw_possessive
		trigger = {
			scope:second = {
				is_male = yes
				any_child = {
					is_spouse_of = root
				}
			}
		}
	}

	text = {
		localization_key = daughter_in_law_possessive
		trigger = {
			scope:second = {
				is_female = yes
				any_spouse = {
					is_child_of = root
				}
			}
		}
	}

	text = {
		localization_key = son_in_law_possessive
		trigger = {
			scope:second = {
				is_female = no
				any_spouse = {
					is_child_of = root
				}
			}
		}
	}

	text = {
		localization_key = relation_liege_female_lover_possessive
		trigger = {
			scope:second = {
				has_relation_lover = root
				is_female = yes
				any_vassal_or_below = {
					this = root
				}
				trigger_if = { # not reflected in has_RelationToMe_relation trigger
					limit = { has_secret_relation_lover = root }
					any_secret = {
						type = secret_lover
						secret_target = { this = root }
						local_player_knows_this_secret = yes
					}
				}
			}
		}
	}

	text = {
		localization_key = relation_liege_female_soulmate_possessive
		trigger = {
			scope:second = {
				has_relation_soulmate = root
				is_female = yes
				any_vassal_or_below = {
					this = root
				}
			}
		}
	}

	text = {
		localization_key = relation_liege_male_lover_possessive
		trigger = {
			scope:second = {
				has_relation_lover = root
				is_female = no
				any_vassal_or_below = {
					this = root
				}
				trigger_if = { # not reflected in has_RelationToMe_relation trigger
					limit = { has_secret_relation_lover = root }
					any_secret = {
						type = secret_lover
						secret_target = { this = root }
						local_player_knows_this_secret = yes
					}
				}
			}
		}
	}

	text = {
		localization_key = relation_liege_male_soulmate_possessive
		trigger = {
			scope:second = {
				has_relation_soulmate = root
				is_female = no
				any_vassal_or_below = {
					this = root
				}
			}
		}
	}

	text = {
		localization_key = relation_lover_female_possessive
		trigger = {
			scope:second = {
				OR = {
					any_relation = {
						type = lover
						this = root
					}
					any_memory = {
						memory_type = lover_died
						memory_participant:dead_relation ?= root
					}
				}
				is_female = yes
				trigger_if = { # not reflected in has_RelationToMe_relation trigger
					limit = { has_secret_relation_lover = root }
					any_secret = {
						type = secret_lover
						secret_target = { this = root }
						local_player_knows_this_secret = yes
					}
				}
			}
		}
	}

	text = {
		localization_key = relation_soulmate_female_possessive
		trigger = {
			scope:second = {
				OR = {
					any_relation = {
						type = soulmate
						this = root
					}
					any_memory = {
						memory_type = soulmate_died
						memory_participant:dead_relation ?= root
					}
				}
				is_female = yes
			}
		}
	}

	text = {
		localization_key = relation_lover_male_possessive
		trigger = {
			scope:second = {
				OR = {
					any_relation = {
						type = lover
						this = root
					}
					any_memory = {
						memory_type = lover_died
						memory_participant:dead_relation ?= root
					}
				}
				is_female = no
				trigger_if = { # not reflected in has_RelationToMe_relation trigger
					limit = { has_secret_relation_lover = root }
					any_secret = {
						type = secret_lover
						secret_target = { this = root }
						local_player_knows_this_secret = yes
					}
				}
			}
		}
	}

	text = {
		localization_key = relation_soulmate_male_possessive
		trigger = {
			scope:second = {
				OR = {
					any_relation = {
						type = soulmate
						this = root
					}
					any_memory = {
						memory_type = soulmate_died
						memory_participant:dead_relation ?= root
					}
				}
				is_female = no
			}
		}
	}

	text = {
		localization_key = relation_friend_female_possessive
		trigger = {
			scope:second = {
				any_relation = {
					type = friend
					this = root
				}
				is_female = yes
			}
		}
	}

	text = {
		localization_key = relation_best_friend_female_possessive
		trigger = {
			scope:second = {
				any_relation = {
					type = best_friend
					this = root
				}
				is_female = yes
			}
		}
	}

	text = {
		localization_key = relation_friend_male_possessive
		trigger = {
			scope:second = {
				any_relation = {
					type = friend
					this = root
				}
				is_female = no
			}
		}
	}

	text = {
		localization_key = relation_best_friend_male_possessive
		trigger = {
			scope:second = {
				any_relation = {
					type = best_friend
					this = root
				}
				is_female = no
			}
		}
	}

	text = {
		localization_key = relation_liege_female_nemesis_possessive
		trigger = {
			scope:second = {
				has_relation_nemesis = root
				is_female = yes
				any_vassal_or_below = {
					this = root
				}
			}
		}
	}

	text = {
		localization_key = relation_liege_female_rival_possessive
		trigger = {
			scope:second = {
				has_relation_rival = root
				NOT = { has_relation_nemesis = root }
				is_female = yes
				any_vassal_or_below = {
					this = root
				}
			}
		}
	}

	text = {
		localization_key = relation_liege_male_nemesis_possessive
		trigger = {
			scope:second = {
				has_relation_nemesis = root
				is_female = no
				any_vassal_or_below = {
					this = root
				}
			}
		}
	}

	text = {
		localization_key = relation_liege_male_rival_possessive
		trigger = {
			scope:second = {
				has_relation_rival = root
				NOT = { has_relation_nemesis = root }
				is_female = no
				any_vassal_or_below = {
					this = root
				}
			}
		}
	}

	text = {
		localization_key = relation_vassal_female_nemesis_possessive
		trigger = {
			scope:second = {
				is_female = yes
				has_relation_nemesis = root
			}
			any_vassal_or_below = {
				this = scope:second
			}
		}
	}

	text = {
		localization_key = relation_vassal_female_rival_possessive
		trigger = {
			scope:second = {
				is_female = yes
				has_relation_rival = root
				NOT = { has_relation_nemesis = root }
			}
			any_vassal_or_below = {
				this = scope:second
			}
		}
	}

	text = {
		localization_key = relation_fellow_vassal_female_nemesis_possessive
		trigger = {
			scope:second = {
				is_female = yes
				has_relation_nemesis = root
				top_liege != this
			}
			top_liege != this
			liege = scope:second.liege
		}
	}

	text = {
		localization_key = relation_fellow_vassal_female_rival_possessive
		trigger = {
			scope:second = {
				is_female = yes
				has_relation_rival = root
				NOT = { has_relation_nemesis = root }
				top_liege != this
			}
			top_liege != this
			liege = scope:second.liege
		}
	}

	text = {
		localization_key = relation_vassal_male_nemesis_possessive
		trigger = {
			scope:second = {
				is_female = no
				has_relation_nemesis = root
			}
			any_vassal_or_below = {
				this = scope:second
			}
		}
	}

	text = {
		localization_key = relation_vassal_male_rival_possessive
		trigger = {
			scope:second = {
				is_female = no
				has_relation_rival = root
				NOT = { has_relation_nemesis = root }
			}
			any_vassal_or_below = {
				this = scope:second
			}
		}
	}

	text = {
		localization_key = relation_fellow_vassal_male_nemesis_possessive
		trigger = {
			scope:second = {
				is_female = no
				has_relation_nemesis = root
				top_liege != this
			}
			top_liege != this
			liege = scope:second.liege
		}
	}

	text = {
		localization_key = relation_fellow_vassal_male_rival_possessive
		trigger = {
			scope:second = {
				is_female = no
				has_relation_rival = root
				NOT = { has_relation_nemesis = root }
				top_liege != this
			}
			top_liege != this
			liege = scope:second.liege
		}
	}

	text = {
		localization_key = relation_nemesis_female_possessive
		trigger = {
			scope:second = {
				OR = {
					any_relation = {
						type = nemesis
						this = root
					}
					any_memory = {
						memory_type = nemesis_died
						memory_participant:dead_relation ?= root
					}
				}
				is_female = yes
			}
		}
	}

	text = {
		localization_key = relation_rival_female_possessive
		trigger = {
			scope:second = {
				OR = {
					any_relation = {
						type = rival
						this = root
					}
					any_memory = {
						memory_type = rival_died
						memory_participant:dead_relation ?= root
					}
				}
				is_female = yes
			}
		}
	}

	text = {
		localization_key = relation_nemesis_male_possessive
		trigger = {
			scope:second = {
				OR = {
					any_relation = {
						type = nemesis
						this = root
					}
					any_memory = {
						memory_type = nemesis_died
						memory_participant:dead_relation ?= root
					}
				}
				is_female = no
			}
		}
	}

	text = {
		localization_key = relation_rival_male_possessive
		trigger = {
			scope:second = {
				OR = {
					any_relation = {
						type = rival
						this = root
					}
					any_memory = {
						memory_type = rival_died
						memory_participant:dead_relation ?= root
					}
				}
				is_female = no
			}
		}
	}

	text = {
		localization_key = relation_crush_possessive
		trigger = {
			any_relation = {
				type = crush
				this = scope:second
			}
		}
	}

	text = {
		localization_key = relation_bully_possessive
		trigger = {
			scope:second = {
				any_relation = {
					type = victim
					this = root
				}
			}
		}
	}

	text = {
		localization_key = relation_victim_possessive
		trigger = {
			scope:second = {
				any_relation = {
					type = bully
					this = root
				}
			}
		}
	}

	text = {
		localization_key = relation_ward_possessive
		trigger = {
			scope:second = {
				any_relation = {
					type = guardian
					this = root
				}
			}
		}
	}

	text = {
		localization_key = relation_guardian_possessive
		trigger = {
			scope:second = {
				any_relation = {
					type = ward
					this = root
				}
			}
		}
	}
	
	text = {
		localization_key = relation_disciple_possessive
		trigger = {
			scope:second = {
				any_relation = {
					type = elder
					this = root
				}
			}
		}
	}

	text = {
		localization_key = relation_elder_possessive
		trigger = {
			scope:second = {
				any_relation = {
					type = disciple
					this = root
				}
			}
		}
	}

	text = { #intrigue-mentor
		localization_key = relation_mentor_possessive
		trigger = {
			scope:second = {
				any_relation = {
					type = intrigue_student
					this = root
				}
			}
		}
	}

	text = { #intrigue-mentor
		localization_key = relation_student_possessive
		trigger = {
			scope:second = {
				any_relation = {
					type = intrigue_mentor
					this = root
				}
			}
		}
	}

	text = {
		localization_key = relation_mentor_possessive
		trigger = {
			scope:second = {
				any_relation = {
					type = student
					this = root
				}
			}
		}
	}

	text = {
		localization_key = relation_student_possessive
		trigger = {
			scope:second = {
				any_relation = {
					type = mentor
					this = root
				}
			}
		}
	}

	text = {
		localization_key = relation_cousin_possessive
		trigger = {
			scope:second = {
				is_cousin_of = root
				is_male = yes
			}
		}
	}

	text = {
		localization_key = relation_cousin_female_possessive
		trigger = {
			scope:second = {
				is_cousin_of = root
				is_female = yes
			}
		}
	}
	
	text = {
		localization_key = relation_great_uncle_possessive
		trigger = {
			scope:second = {
				is_male = yes
				is_great_aunt_uncle_of = { CHARACTER = root }
			}
		}
	}
	
	text = {
		localization_key = relation_great_aunt_possessive
		trigger = {
			scope:second = {
				is_female = yes
				is_great_aunt_uncle_of = { CHARACTER = root }
			}
		}
	}
	
	text = {
		localization_key = relation_great_nephew_possessive
		trigger = {
			scope:second = {
				is_male = yes
				is_great_nibling_of = { CHARACTER = root }
			}
		}
	}
	
	text = {
		localization_key = relation_great_niece_possessive
		trigger = {
			scope:second = {
				is_female = yes
				is_great_nibling_of = { CHARACTER = root }
			}
		}
	}

	text = {
		localization_key = relation_sisterinlaw_possessive
		trigger = {
			scope:second = {
				is_female = yes
				is_sibling_in_law_of = { CHARACTER = root }
			}
		}
	}

	text = {
		localization_key = relation_brotherinlaw_possessive
		trigger = {
			scope:second = {
				is_female = no
				is_sibling_in_law_of = { CHARACTER = root }
			}
		}
	}

	text = {
		localization_key = relation_cousininlaw_female_possessive
		trigger = {
			scope:second = {
				is_female = yes
				is_cousin_in_law_of = { CHARACTER = root }
			}
		}
	}

	text = {
		localization_key = relation_cousininlaw_male_possessive
		trigger = {
			scope:second = {
				is_female = no
				is_cousin_in_law_of = { CHARACTER = root }
			}
		}
	}

	text = {
		localization_key = relation_auntinlaw_possessive
		trigger = {
			scope:second = {
				is_female = yes
				is_aunt_uncle_in_law_of = { CHARACTER = root }
			}
		}
	}

	text = {
		localization_key = relation_uncleinlaw_possessive
		trigger = {
			scope:second = {
				is_female = no
				is_aunt_uncle_in_law_of = { CHARACTER = root }
			}
		}
	}

	text = {
		localization_key = relation_grandmotherinlaw_possessive
		trigger = {
			scope:second = {
				is_female = yes
				any_child = {
					even_if_dead = yes
					any_child = { is_spouse_of = root }
				}
			}
		}
	}

	text = {
		localization_key = relation_grandfatherinlaw_possessive
		trigger = {
			scope:second = {
				is_female = no
				any_child = {
					even_if_dead = yes
					any_child = { is_spouse_of = root }
				}
			}
		}
	}

	text = {
		localization_key = relation_great_grandmotherinlaw_possessive
		trigger = {
			scope:second = {
				is_female = yes
				any_child = {
					even_if_dead = yes
					any_child = {
						even_if_dead = yes
						any_child = { is_spouse_of = root }
					}
				}
			}
		}
	}

	text = {
		localization_key = relation_great_grandfatherinlaw_possessive
		trigger = {
			scope:second = {
				is_female = no
				any_child = {
					even_if_dead = yes
					any_child = {
						even_if_dead = yes
						any_child = { is_spouse_of = root }
					}
				}
			}
		}
	}

	text = {
		localization_key = relation_granddaughterinlaw_possessive
		trigger = {
			scope:second = {
				is_female = yes
				is_granddaughterson_in_law_of_root_trigger = yes
			}
		}
	}

	text = {
		localization_key = relation_grandsoninlaw_possessive
		trigger = {
			scope:second = {
				is_female = no
				is_granddaughterson_in_law_of_root_trigger = yes
			}
		}
	}

	text = {
		localization_key = relation_great_granddaughterinlaw_possessive
		trigger = {
			scope:second = {
				is_female = yes
				is_great_granddaughterson_in_law_of_root_trigger = yes
			}
		}
	}

	text = {
		localization_key = relation_great_grandsoninlaw_possessive
		trigger = {
			scope:second = {
				is_female = no
				is_great_granddaughterson_in_law_of_root_trigger = yes
			}
		}
	}

	text = {
		localization_key = relation_nieceinlaw_possessive
		trigger = {
			scope:second = {
				is_female = yes
				is_nibling_in_law_of = { CHARACTER = root }
			}
		}
	}

	text = {
		localization_key = relation_nephewinlaw_possessive
		trigger = {
			scope:second = {
				is_female = no
				is_nibling_in_law_of = { CHARACTER = root }
			}
		}
	}
	
	text = {
		localization_key = relation_ceremonial_liege_female_possessive
		trigger = {
			scope:second = {
				is_female = yes
				top_liege = root.top_liege
				tgp_is_ceremonial_liege_trigger = yes
			}
		}
	}

	text = {
		localization_key = relation_ceremonial_liege_male_possessive
		trigger = {
			scope:second = {
				is_female = no
				top_liege = root.top_liege
				tgp_is_ceremonial_liege_trigger = yes
			}
		}
	}

	text = {
		localization_key = relation_liege_female_possessive
		trigger = {
			scope:second = {
				is_female = yes
				any_vassal_or_below = {
					this = root
				}
			}
		}
	}

	text = {
		localization_key = relation_liege_male_possessive
		trigger = {
			scope:second = {
				is_female = no
				any_vassal_or_below = {
					this = root
				}
			}
		}
	}

	text = {
		localization_key = relation_councillor_female_possessive
		trigger = {
			scope:second = {
				is_female = yes			
				is_councillor_of = root
			}
		}
	}

	text = {
		localization_key = relation_councillor_male_possessive
		trigger = {
			scope:second = {
				is_female = no				
				is_councillor_of = root
			}
		}
	}
	
	text = {
		localization_key = relation_vassal_female_possessive
		trigger = {
			scope:second = {
				is_female = yes
			}
			any_vassal_or_below = {
				this = scope:second
			}
		}
	}

	text = {
		localization_key = relation_vassal_male_possessive
		trigger = {
			scope:second = {
				is_female = no
			}
			any_vassal_or_below = {
				this = scope:second
			}
		}
	}

	text = {
		localization_key = relation_fellow_vassal_female_possessive
		trigger = {
			scope:second = {
				is_female = yes
				top_liege != this
			}
			top_liege != this
			liege ?= scope:second.liege
		}
	}

	text = {
		localization_key = relation_fellow_vassal_male_possessive
		trigger = {
			scope:second = {
				is_female = no
				top_liege != this
			}
			top_liege != this
			liege ?= scope:second.liege
		}
	}

	text = {
		localization_key = relation_court_physician_female_possessive
		trigger = {
			scope:second = {
				is_female = yes
				has_court_position = court_physician_court_position
				is_court_position_employer = {
					court_position = court_physician_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_court_physician_male_possessive
		trigger = {
			scope:second = {
				is_male = yes
				has_court_position = court_physician_court_position
				is_court_position_employer = {
					court_position = court_physician_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_keeper_of_swans_female_possessive
		trigger = {
			scope:second = {
				is_female = yes
				has_court_position = keeper_of_swans_court_position
				is_court_position_employer = {
					court_position = keeper_of_swans_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_keeper_of_swans_male_possessive
		trigger = {
			scope:second = {
				is_male = yes
				has_court_position = keeper_of_swans_court_position
				is_court_position_employer = {
					court_position = keeper_of_swans_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_travel_leader_female_possessive
		trigger = {
			scope:second = {
				is_female = yes
				has_court_position = travel_leader_court_position
				is_court_position_employer = {
					court_position = travel_leader_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_travel_leader_male_possessive
		trigger = {
			scope:second = {
				is_male = yes
				has_court_position = travel_leader_court_position
				is_court_position_employer = {
					court_position = travel_leader_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_master_of_horse_female_possessive
		trigger = {
			scope:second = {
				is_female = yes
				has_court_position = master_of_horse_court_position
				is_court_position_employer = {
					court_position = master_of_horse_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_master_of_horse_male_possessive
		trigger = {
			scope:second = {
				is_male = yes
				has_court_position = master_of_horse_court_position
				is_court_position_employer = {
					court_position = master_of_horse_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_court_jester_female_possessive
		trigger = {
			scope:second = {
				is_female = yes
				has_court_position = court_jester_court_position
				is_court_position_employer = {
					court_position = court_jester_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_court_jester_male_possessive
		trigger = {
			scope:second = {
				is_male = yes
				has_court_position = court_jester_court_position
				is_court_position_employer = {
					court_position = court_jester_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_master_of_hunt_female_possessive
		trigger = {
			scope:second = {
				is_female = yes
				has_court_position = master_of_hunt_court_position
				is_court_position_employer = {
					court_position = master_of_hunt_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_master_of_hunt_male_possessive
		trigger = {
			scope:second = {
				is_male = yes
				has_court_position = master_of_hunt_court_position
				is_court_position_employer = {
					court_position = master_of_hunt_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_high_almoner_female_possessive
		trigger = {
			scope:second = {
				is_female = yes
				has_court_position = high_almoner_court_position
				is_court_position_employer = {
					court_position = high_almoner_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_high_almoner_male_possessive
		trigger = {
			scope:second = {
				is_male = yes
				has_court_position = high_almoner_court_position
				is_court_position_employer = {
					court_position = high_almoner_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_cupbearer_female_possessive
		trigger = {
			scope:second = {
				is_female = yes
				has_court_position = cupbearer_court_position
				is_court_position_employer = {
					court_position = cupbearer_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_cupbearer_male_possessive
		trigger = {
			scope:second = {
				is_male = yes
				has_court_position = cupbearer_court_position
				is_court_position_employer = {
					court_position = cupbearer_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_seneschal_female_possessive
		trigger = {
			scope:second = {
				is_female = yes
				has_court_position = seneschal_court_position
				is_court_position_employer = {
					court_position = seneschal_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_seneschal_male_possessive
		trigger = {
			scope:second = {
				is_male = yes
				has_court_position = seneschal_court_position
				is_court_position_employer = {
					court_position = seneschal_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_antiquarian_female_possessive
		trigger = {
			scope:second = {
				is_female = yes
				has_court_position = antiquarian_court_position
				is_court_position_employer = {
					court_position = antiquarian_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_antiquarian_male_possessive
		trigger = {
			scope:second = {
				is_male = yes
				has_court_position = antiquarian_court_position
				is_court_position_employer = {
					court_position = antiquarian_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_court_tutor_female_possessive
		trigger = {
			scope:second = {
				is_female = yes
				has_court_position = court_tutor_court_position
				is_court_position_employer = {
					court_position = court_tutor_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_court_tutor_male_possessive
		trigger = {
			scope:second = {
				is_male = yes
				has_court_position = court_tutor_court_position
				is_court_position_employer = {
					court_position = court_tutor_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_royal_architect_female_possessive
		trigger = {
			scope:second = {
				is_female = yes
				has_court_position = royal_architect_court_position
				is_court_position_employer = {
					court_position = royal_architect_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_royal_architect_male_possessive
		trigger = {
			scope:second = {
				is_male = yes
				has_court_position = royal_architect_court_position
				is_court_position_employer = {
					court_position = royal_architect_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_court_poet_female_possessive
		trigger = {
			scope:second = {
				is_female = yes
				has_court_position = court_poet_court_position
				is_court_position_employer = {
					court_position = court_poet_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_court_poet_male_possessive
		trigger = {
			scope:second = {
				is_male = yes
				has_court_position = court_poet_court_position
				is_court_position_employer = {
					court_position = court_poet_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_bodyguard_female_possessive
		trigger = {
			scope:second = {
				is_female = yes
				has_court_position = bodyguard_court_position
				is_court_position_employer = {
					court_position = bodyguard_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_bodyguard_male_possessive
		trigger = {
			scope:second = {
				is_male = yes
				has_court_position = bodyguard_court_position
				is_court_position_employer = {
					court_position = bodyguard_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_champion_female_possessive
		trigger = {
			scope:second = {
				is_female = yes
				has_court_position = champion_court_position
				is_court_position_employer = {
					court_position = champion_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_champion_male_possessive
		trigger = {
			scope:second = {
				is_male = yes
				has_court_position = champion_court_position
				is_court_position_employer = {
					court_position = champion_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_court_musician_female_possessive
		trigger = {
			scope:second = {
				is_female = yes
				has_court_position = court_musician_court_position
				is_court_position_employer = {
					court_position = court_musician_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_court_musician_male_possessive
		trigger = {
			scope:second = {
				is_male = yes
				has_court_position = court_musician_court_position
				is_court_position_employer = {
					court_position = court_musician_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_food_taster_female_possessive
		trigger = {
			scope:second = {
				is_female = yes
				has_court_position = food_taster_court_position
				is_court_position_employer = {
					court_position = food_taster_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_food_taster_male_possessive
		trigger = {
			scope:second = {
				is_male = yes
				has_court_position = food_taster_court_position
				is_court_position_employer = {
					court_position = food_taster_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_lady_in_waiting_female_possessive
		trigger = {
			scope:second = {
				is_female = yes
				has_court_position = lady_in_waiting_court_position
				is_court_position_employer = {
					court_position = lady_in_waiting_court_position
					who = root
				}
			}
		}
	}

	text = { #Shouldn't happen, but who knows ¯\_(ツ)_/¯
		localization_key = relation_lady_in_waiting_male_possessive
		trigger = {
			scope:second = {
				is_male = yes
				has_court_position = lady_in_waiting_court_position
				is_court_position_employer = {
					court_position = lady_in_waiting_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_garuda_female_possessive
		trigger = {
			scope:second = {
				is_female = yes
				has_court_position = garuda_court_position
				is_court_position_employer = {
					court_position = garuda_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_garuda_male_possessive
		trigger = {
			scope:second = {
				is_male = yes
				has_court_position = garuda_court_position
				is_court_position_employer = {
					court_position = garuda_court_position
					who = root
				}
			}
		}
	}

	text = { #Shouldn't happen, but who knows ¯\_(ツ)_/¯
		localization_key = relation_chief_eunuch_female_possessive
		trigger = {
			scope:second = {
				is_female = yes
				has_court_position = chief_eunuch_court_position
				is_court_position_employer = {
					court_position = chief_eunuch_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_chief_eunuch_male_possessive
		trigger = {
			scope:second = {
				is_male = yes
				has_court_position = chief_eunuch_court_position
				is_court_position_employer = {
					court_position = chief_eunuch_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_court_gardener_female_possessive
		trigger = {
			scope:second = {
				is_female = yes
				has_court_position = court_gardener_court_position
				is_court_position_employer = {
					court_position = court_gardener_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_court_gardener_male_possessive
		trigger = {
			scope:second = {
				is_male = yes
				has_court_position = court_gardener_court_position
				is_court_position_employer = {
					court_position = court_gardener_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_chief_qadi_female_possessive
		trigger = {
			scope:second = {
				is_female = yes
				has_court_position = chief_qadi_court_position
				is_court_position_employer = {
					court_position = chief_qadi_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_chief_qadi_male_possessive
		trigger = {
			scope:second = {
				is_male = yes
				has_court_position = chief_qadi_court_position
				is_court_position_employer = {
					court_position = chief_qadi_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_wet_nurse_female_possessive
		trigger = {
			scope:second = {
				is_female = yes
				has_court_position = wet_nurse_court_position
				is_court_position_employer = {
					court_position = wet_nurse_court_position
					who = root
				}
			}
		}
	}

	text = { #Shouldn't happen, but who knows ¯\_(ツ)_/¯
		localization_key = relation_wet_nurse_male_possessive
		trigger = {
			scope:second = {
				is_male = yes
				has_court_position = wet_nurse_court_position
				is_court_position_employer = {
					court_position = wet_nurse_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_akolouthos_male_possessive
		trigger = {
			scope:second = {
				is_male = yes
				has_court_position = akolouthos_court_position
				is_court_position_employer = {
					court_position = akolouthos_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_akolouthos_female_possessive
		trigger = {
			scope:second = {
				is_female = yes
				has_court_position = akolouthos_court_position
				is_court_position_employer = {
					court_position = akolouthos_court_position
					who = root
				}
			}
		}
	}
	
	text = {
		localization_key = relation_court_astrologer_male_possessive
		trigger = {
			scope:second = { is_male = yes }
			has_court_position = court_astrologer_court_position
			is_court_position_employer = {
		        court_position = court_astrologer_court_position
		        who = root
		    }
		}
	}
	
	text = {
		localization_key = relation_court_astrologer_female_possessive
		trigger = {
			scope:second = { is_female = yes }
			has_court_position = court_astrologer_court_position
			is_court_position_employer = {
		        court_position = court_astrologer_court_position
		        who = root
		    }
		}
	}

	text = {
		localization_key = relation_kinswoman_possessive
		trigger = {
			scope:second = {
				is_female = yes
				is_lowborn = no
			}
			scope:second.dynasty = root.dynasty
		}
	}

	text = {
		localization_key = relation_kinsman_possessive
		trigger = {
			scope:second = {
				is_male = yes
				is_lowborn = no
			}
			scope:second.dynasty = root.dynasty
		}
	}

	text = {
		localization_key = relation_follower_female_possessive
		trigger = {
			is_landed_or_landless_administrative = yes
			scope:second = {
				is_courtier_of = root
				is_female = yes
			}
		}
	}

	text = {
		localization_key = relation_follower_male_possessive
		trigger = {
			is_landed_or_landless_administrative = yes
			scope:second = {
				is_courtier_of = root
				is_male = yes
			}
		}
	}

	text = {
		localization_key = relation_courtier_female_possessive
		trigger = {
			scope:second = {
				is_courtier_of = root
				is_female = yes
			}
		}
	}

	text = {
		localization_key = relation_courtier_male_possessive
		trigger = {
			scope:second = {
				is_courtier_of = root
				is_male = yes
			}
		}
	}

	text = {
		localization_key = relation_peasant_affair_female_possessive
		trigger = {
			any_owned_story = {
				type = story_peasant_affair
				var:peasant_character = {
					this = scope:second
					is_female = yes
				}
			}
		}
	}

	text = {
		localization_key = relation_peasant_affair_male_possessive
		trigger = {
			any_owned_story = {
				type = story_peasant_affair
				var:peasant_character = {
					this = scope:second
					is_male = yes
				}
			}
		}
	}

	text = {
		localization_key = relation_agent_possessive
		trigger = {
			any_scheme = {
				scheme_is_character_agent = scope:second
			}
		}
	}

	text = {
		localization_key = relation_prisoner_female_possessive
		trigger = {
			scope:second = {
				is_female = yes
				is_imprisoned_by = root
			}
		}
	}

	text = {
		localization_key = relation_prisoner_male_possessive
		trigger = {
			scope:second = {
				is_male = yes
				is_imprisoned_by = root
			}
		}
	}

	text = {
		localization_key = relation_jailer_female_possessive
		trigger = {
			is_imprisoned_by = scope:second
			scope:second = {
				is_female = yes
			}
		}
	}

	text = {
		localization_key = relation_jailer_male_possessive
		trigger = {
			is_imprisoned_by = scope:second
			scope:second = {
				is_male = yes
			}
		}
	}

	text = {
		localization_key = relation_host_female_possessive
		trigger = {
			host ?= scope:second
			scope:second = { is_female = yes }
		}
	}

	text = {
		localization_key = relation_host_male_possessive
		trigger = {
			host ?= scope:second
			scope:second = { is_male = yes }
		}
	}

	text = {
		localization_key = relation_guest_female_possessive
		trigger = {
			scope:second = {
				is_female = yes
				host ?= root
			}
		}
	}

	text = {
		localization_key = relation_guest_male_possessive
		trigger = {
			scope:second = {
				is_male = yes
				host ?= root
			}
		}
	}

	text = {
		localization_key = relation_old_foe_female_possessive
		trigger = {
			root = {
				any_memory = {
					OR = {
						has_memory_type = war_won
						has_memory_type = war_lost
					}
					any_memory_participant = {
						this = scope:second
					}
				}
			}
			scope:second = {
				is_female = yes
			}
		}
	}

	text = {
		localization_key = relation_old_foe_male_possessive
		trigger = {
			root = {
				any_memory = {
					OR = {
						has_memory_type = war_won
						has_memory_type = war_lost
					}
					any_memory_participant = {
						this = scope:second
					}
				}
			}
			scope:second = {
				is_male = yes
			}
		}
	}

	text = {
		localization_key = relation_fellow_pilgrim_female_possessive
		trigger = {
			root = {
				current_travel_plan ?= {
					travel_leader.involved_activity ?= {
						has_activity_type = activity_pilgrimage
					}
					any_entourage_character = {
						this = scope:second
					}
				}
			}
			scope:second = {
				is_female = yes
			}
		}
	}

	text = {
		localization_key = relation_fellow_pilgrim_male_possessive
		trigger = {
			root = {
				current_travel_plan ?= {
					travel_leader.involved_activity ?= {
						has_activity_type = activity_pilgrimage
					}
					any_entourage_character = {
						this = scope:second
					}
				}
			}
			scope:second = {
				is_male = yes
			}
		}
	}

	text = {
		localization_key = relation_fellow_traveler_female_possessive
		trigger = {
			root = {
				current_travel_plan ?= {
					any_entourage_character = {
						this = scope:second
					}
				}
			}
			scope:second = {
				is_female = yes
			}
		}
	}

	text = {
		localization_key = relation_fellow_traveler_male_possessive
		trigger = {
			root = {
				current_travel_plan ?= {
					any_entourage_character = {
						this = scope:second
					}
				}
			}
			scope:second = {
				is_male = yes
			}
		}
	}

	text = {
		localization_key = relation_fellow_contestant_female_possessive
		trigger = {
			root = {
				involved_activity ?= {
					has_activity_type = activity_tournament
					any_guest_subset_current_phase = { #you're participating
						name = contestant
						this = root
					}
					any_guest_subset_current_phase = { #they are participating
						name = contestant
						this = scope:second
					}
				}
			}
			scope:second = {
				is_female = yes
			}
		}
	}

	text = {
		localization_key = relation_fellow_contestant_male_possessive
		trigger = {
			root = {
				involved_activity ?= {
					has_activity_type = activity_tournament
					any_guest_subset_current_phase = { #you're participating
						name = contestant
						this = root
					}
					any_guest_subset_current_phase = { #they are participating
						name = contestant
						this = scope:second
					}
				}
			}
			scope:second = {
				is_male = yes
			}
		}
	}

	text = {
		localization_key = relation_fellow_attendee_female_possessive
		trigger = {
			root = {
				involved_activity ?= {
					has_activity_type = activity_tournament
					any_attending_character = { this = scope:second }
				}
			}
			scope:second = {
				is_female = yes
			}
		}
	}

	text = {
		localization_key = relation_fellow_attendee_male_possessive
		trigger = {
			root = {
				involved_activity ?= {
					has_activity_type = activity_tournament
					any_attending_character = { this = scope:second }
				}
			}
			scope:second = {
				is_male = yes
			}
		}
	}

	text = {
		localization_key = relation_acquaintance_female_possessive
		trigger = {
			scope:second = {
				is_female = yes
			}
		}
	}

	text = {
		localization_key = relation_acquaintance_male_possessive
		trigger = {
			scope:second = {
				is_male = yes
			}
		}
	}
}

LMF_RelationToMeShort = {
	type = character

	text = {
		localization_key = relation_you
		trigger = { scope:second = root }
	}

	text = {
		localization_key = relation_motherwife
		trigger = {
			scope:second = {
				OR = {
					this = root.mother
					this = root.mother.mother
					this = root.father.mother
				}
				any_spouse = { this = root }
			}
		}
	}

	text = {
		localization_key = relation_mother_concubine
		trigger = {
			scope:second = {
				OR = {
					this = root.mother
					this = root.mother.mother
					this = root.father.mother
				}
				any_consort = { this = root }
				is_concubine = yes
			}
		}
	}

	text = {
		localization_key = relation_sisterwife
		trigger = {
			scope:second = {
				any_sibling = { this = root }
				is_female = yes
				any_spouse = { this = root }
			}
		}
	}

	text = {
		localization_key = relation_sister_concubine
		trigger = {
			scope:second = {
				any_sibling = { this = root }
				is_female = yes
				any_consort = { this = root }
				is_concubine = yes
			}
		}
	}

	text = {
		localization_key = relation_daughterwife
		trigger = {
			scope:second = {
				OR = {
					any_parent = { this = root }
					any_parent = { any_parent = { this = root } }
				}
				is_female = yes
				any_spouse = { this = root }
			}
		}
	}

	text = {
		localization_key = relation_daughter_concubine
		trigger = {
			scope:second = {
				OR = {
					any_parent = { this = root }
					any_parent = { any_parent = { this = root } }
				}
				any_consort = { this = root }
				is_female = yes
				is_concubine = yes
			}
		}
	}

	text = {
		localization_key = relation_fatherhusband
		trigger = {
			scope:second = {
				OR = {
					this = root.father
					this = root.father.father
					this = root.mother.father
				}
				any_spouse = { this = root }
			}
		}
	}

	text = {
		localization_key = relation_father_consort
		trigger = {
			scope:second = {
				OR = {
					this = root.father
					this = root.father.father
					this = root.mother.father
				}
				any_consort = { this = root }
				is_concubine = yes
			}
		}
	}

	text = {
		localization_key = relation_brotherhusband
		trigger = {
			scope:second = {
				any_sibling = { this = root }
				is_female = no
				any_spouse = { this = root }
			}
		}
	}

	text = {
		localization_key = relation_brother_consort
		trigger = {
			scope:second = {
				any_sibling = { this = root }
				is_female = no
				any_consort = { this = root }
				is_concubine = yes
			}
		}
	}

	text = {
		localization_key = relation_sonhusband
		trigger = {
			scope:second = {
				OR = {
					any_parent = { this = root }
					any_parent = {
						even_if_dead = yes
						any_parent = {
							this = root
						}
					}
				}
				is_female = no
				any_spouse = { this = root }
			}
		}
	}

	text = {
		localization_key = relation_son_consort
		trigger = {
			scope:second = {
				OR = {
					any_parent = { this = root }
					any_parent = {
						even_if_dead = yes
						any_parent = {
							this = root
						}
					}
				}
				is_female = no
				any_consort = { this = root }
				is_concubine = yes
			}
		}
	}

	text = {
		localization_key = relation_wife
		trigger = {
			scope:second = {
				is_female = yes
				OR = {
					any_spouse = {
						even_if_dead = yes
						this = root
					}
					any_former_spouse = {
						even_if_dead = yes
						this = root
					}
				}
				is_concubine = no
			}
		}
	}

	text = {
		localization_key = relation_husband
		trigger = {
			scope:second = {
				is_male = yes
				OR = {
					any_spouse = {
						even_if_dead = yes
						this = root
					}
					any_former_spouse = {
						even_if_dead = yes
						this = root
					}
				}
				is_concubine = no
			}
		}
	}

	text = {
		localization_key = relation_mother
		trigger = {
			scope:second = {
				is_female = yes
				any_child = {
					this = root
				}
			}
		}
	}

	text = {
		localization_key = relation_father
		trigger = {
			scope:second = {
				is_female = no
				any_child = {
					this = root
				}
			}
		}
	}

	text = {
		localization_key = relation_daughter
		trigger = {
			scope:second = {
				is_female = yes
				is_child_of = root
			}
		}
	}

	text = {
		localization_key = relation_son
		trigger = {
			scope:second = {
				is_male = yes
				is_child_of = root
			}
		}
	}

	text = {
		localization_key = relation_grandmother
		trigger = {
			scope:second = {
				is_female = yes
				is_grandparent_of = root
			}
		}
	}

	text = {
		localization_key = relation_grandfather
		trigger = {
			scope:second = {
				is_male = yes
				is_grandparent_of = root
			}
		}
	}

	text = {
		localization_key = relation_granddaughter
		trigger = {
			scope:second = {
				is_female = yes
				any_parent = {
					even_if_dead = yes
					any_parent = {
						this = root
					}
				}
			}
		}
	}

	text = {
		localization_key = relation_grandson
		trigger = {
			scope:second = {
				is_female = no
				any_parent = {
					even_if_dead = yes
					any_parent = {
						this = root
					}
				}
			}
		}
	}

	text = {
		localization_key = relation_half_sister
		trigger = {
			scope:second = {
				is_female = yes
				is_sibling_of = root
				NAND = {
					father ?= root.father
					mother ?= root.mother
				}
			}
		}
	}

	text = {
		localization_key = relation_half_brother
		trigger = {
			scope:second = {
				is_female = no
				is_sibling_of = root
				NAND = {
					father ?= root.father
					mother ?= root.mother
				}
			}
		}
	}

	text = {
		localization_key = relation_sister
		trigger = {
			scope:second = {
				is_female = yes
				any_sibling = {
					this = root
				}
			}
		}
	}

	text = {
		localization_key = relation_brother
		trigger = {
			scope:second = {
				is_female = no
				any_sibling = {
					this = root
				}
			}
		}
	}

	text = {
		localization_key = relation_niece
		trigger = {
			scope:second = {
				is_female = yes
				is_sibling_child_of_root_trigger = yes
			}
		}
	}

	text = {
		localization_key = relation_nephew
		trigger = {
			scope:second = {
				is_female = no
				is_sibling_child_of_root_trigger = yes
			}
		}
	}

	text = {
		localization_key = relation_aunt
		trigger = {
			scope:second = {
				is_female = yes
				is_parent_sibling_of_root_trigger = yes
			}
		}
	}

	text = {
		localization_key = relation_uncle
		trigger = {
			scope:second = {
				is_female = no
				is_parent_sibling_of_root_trigger = yes
			}
		}
	}

	text = {
		localization_key = relation_hostage
		trigger = {
			scope:second = {
				is_hostage = yes
				warden ?= root
			}
		}
	}

	text = {
		localization_key = relation_warden
		trigger = {
			is_hostage = yes
			warden ?= scope:second
		}
	}

	text = {
		localization_key = relation_concubine_female
		trigger = {
			scope:second = {
				is_female = yes
				any_consort = { this = root }
				is_concubine = yes
			}
		}
	}

	text = {
		localization_key = relation_concubine_male
		trigger = {
			scope:second = {
				is_male = yes
				any_consort = { this = root }
				is_concubine = yes
			}
		}
	}

	text = {
		localization_key = relation_great_grandmother
		trigger = {
			scope:second = {
				is_female = yes
				is_great_grandparent_of = root
			}
		}
	}

	text = {
		localization_key = relation_great_grandfather
		trigger = {
			scope:second = {
				is_male = yes
				is_great_grandparent_of = root
			}
		}
	}

	text = {
		localization_key = relation_religious_head
		trigger = {
			faith.religious_head = scope:second
		}
	}
	
	text = {
		localization_key = relation_disciple
		trigger = {
			scope:second = {
				any_relation = {
					type = elder
					this = root
				}
			}
		}
	}

	text = {
		localization_key = relation_elder
		trigger = {
			scope:second = {
				any_relation = {
					type = disciple
					this = root
				}
			}
		}
	}
	
	text = {
		localization_key = relation_movement_leader
		trigger = {
			scope:second = {
				trigger_if = {
					limit = {
						any_character_situation = {
							situation_type = dynastic_cycle
						}
						government_has_flag = government_is_celestial
						root = { government_has_flag = government_is_celestial }
					}
				}
				is_any_movement_leader = yes
				top_participant_group:dynastic_cycle ?= root.top_participant_group:dynastic_cycle
			}
		}
	}

	text = {
		localization_key = relation_greatgranddaughter
		trigger = {
			scope:second = {
				is_female = yes
				is_great_grandchild_of = root
			}
		}
	}

	text = {
		localization_key = relation_greatgrandson
		trigger = {
			scope:second = {
				is_female = no
				is_great_grandchild_of = root
			}
		}
	}
	
	text = {
		localization_key = relation_greatgreatgranddaughter
		trigger = {
			scope:second = {
				is_female = yes
				any_parent = {
					even_if_dead = yes
					is_great_grandchild_of = root
				}
			}
		}
	}

	text = {
		localization_key = relation_greatgreatgrandson
		trigger = {
			scope:second = {
				is_female = no
				any_parent = {
					even_if_dead = yes
					is_great_grandchild_of = root
				}
			}
		}
	}

	text = {
		localization_key = relation_cousin
		trigger = {
			scope:second = {
				is_cousin_of = root
				is_male = yes
			}
		}
	}

	text = {
		localization_key = relation_cousin_female
		trigger = {
			scope:second = {
				is_cousin_of = root
				is_female = yes
			}
		}
	}
	
	text = {
		localization_key = relation_motherinlaw
		trigger = {
			scope:second = {
				is_female = yes
				any_child = {
					is_spouse_of = root
				}
			}
		}
	}
	
	text = {
		localization_key = relation_fatherinlaw
		trigger = {
			scope:second = {
				is_male = yes
				any_child = {
					is_spouse_of = root
				}
			}
		}
	}
	
	text = {
		localization_key = daughter_in_law
		trigger = {
			scope:second = {
				is_female = yes
				any_spouse = {
					is_child_of = root
				}
			}
		}
	}

	text = {
		localization_key = son_in_law
		trigger = {
			scope:second = {
				is_female = no
				any_spouse = {
					is_child_of = root
				}
			}
		}
	}
	
	text = {
		localization_key = relation_great_uncle
		trigger = {
			scope:second = {
				is_male = yes
				is_great_aunt_uncle_of = { CHARACTER = root }
			}
		}
	}
	
	text = {
		localization_key = relation_great_aunt
		trigger = {
			scope:second = {
				is_female = yes
				is_great_aunt_uncle_of = { CHARACTER = root }
			}
		}
	}
	
	text = {
		localization_key = relation_great_nephew
		trigger = {
			scope:second = {
				is_male = yes
				is_great_nibling_of = { CHARACTER = root }
			}
		}
	}
	
	text = {
		localization_key = relation_great_niece
		trigger = {
			scope:second = {
				is_female = yes
				is_great_nibling_of = { CHARACTER = root }
			}
		}
	}

	text = {
		localization_key = relation_soulmate_female
		trigger = {
			scope:second = {
				OR = {
					any_relation = {
						type = soulmate
						this = root
					}
					any_memory = {
						memory_type = soulmate_died
						memory_participant:dead_relation ?= root
					}
				}
				is_female = yes
			}
		}
	}

	text = {
		localization_key = relation_lover_female
		trigger = {
			scope:second = {
				OR = {
					any_relation = {
						type = lover
						this = root
					}
					any_memory = {
						memory_type = lover_died
						memory_participant:dead_relation ?= root
					}
				}
				is_female = yes
				trigger_if = { # not reflected in has_RelationToMe_relation trigger
					limit = { has_secret_relation_lover = root }
					any_secret = {
						type = secret_lover
						secret_target = { this = root }
						local_player_knows_this_secret = yes
					}
				}
			}
		}
	}

	text = {
		localization_key = relation_soulmate_male
		trigger = {
			scope:second = {
				OR = {
					any_relation = {
						type = soulmate
						this = root
					}
					any_memory = {
						memory_type = soulmate_died
						memory_participant:dead_relation ?= root
					}
				}
				is_female = no
			}
		}
	}

	text = {
		localization_key = relation_lover_male
		trigger = {
			scope:second = {
				OR = {
					any_relation = {
						type = lover
						this = root
					}
					any_memory = {
						memory_type = lover_died
						memory_participant:dead_relation ?= root
					}
				}
				is_female = no
				trigger_if = { # not reflected in has_RelationToMe_relation trigger
					limit = { has_secret_relation_lover = root }
					any_secret = {
						type = secret_lover
						secret_target = { this = root }
						local_player_knows_this_secret = yes
					}
				}
			}
		}
	}

	text = {
		localization_key = relation_sisterinlaw
		trigger = {
			scope:second = {
				is_female = yes
				is_sibling_in_law_of = { CHARACTER = root }
			}
		}
	}

	text = {
		localization_key = relation_brotherinlaw
		trigger = {
			scope:second = {
				is_female = no
				is_sibling_in_law_of = { CHARACTER = root }
			}
		}
	}

	text = {
		localization_key = relation_cousininlaw_female
		trigger = {
			scope:second = {
				is_female = yes
				is_cousin_in_law_of = { CHARACTER = root }
			}
		}
	}

	text = {
		localization_key = relation_cousininlaw_male
		trigger = {
			scope:second = {
				is_female = no
				is_cousin_in_law_of = { CHARACTER = root }
			}
		}
	}

	text = {
		localization_key = relation_auntinlaw
		trigger = {
			scope:second = {
				is_female = yes
				is_aunt_uncle_in_law_of = { CHARACTER = root }
			}
		}
	}

	text = {
		localization_key = relation_uncleinlaw
		trigger = {
			scope:second = {
				is_female = no
				is_aunt_uncle_in_law_of = { CHARACTER = root }
			}
		}
	}

	text = {
		localization_key = relation_grandmotherinlaw
		trigger = {
			scope:second = {
				is_female = yes
				any_child = {
					even_if_dead = yes
					any_child = { is_spouse_of = root }
				}
			}
		}
	}

	text = {
		localization_key = relation_grandfatherinlaw
		trigger = {
			scope:second = {
				is_female = no
				any_child = {
					even_if_dead = yes
					any_child = { is_spouse_of = root }
				}
			}
		}
	}

	text = {
		localization_key = relation_great_grandmotherinlaw
		trigger = {
			scope:second = {
				is_female = yes
				any_child = {
					even_if_dead = yes
					any_child = {
						even_if_dead = yes
						any_child = { is_spouse_of = root }
					}
				}
			}
		}
	}

	text = {
		localization_key = relation_great_grandfatherinlaw
		trigger = {
			scope:second = {
				is_female = no
				any_child = {
					even_if_dead = yes
					any_child = {
						even_if_dead = yes
						any_child = { is_spouse_of = root }
					}
				}
			}
		}
	}

	text = {
		localization_key = relation_granddaughterinlaw
		trigger = {
			scope:second = {
				is_female = yes
				is_granddaughterson_in_law_of_root_trigger = yes
			}
		}
	}

	text = {
		localization_key = relation_grandsoninlaw
		trigger = {
			scope:second = {
				is_female = no
				is_granddaughterson_in_law_of_root_trigger = yes
			}
		}
	}

	text = {
		localization_key = relation_great_granddaughterinlaw
		trigger = {
			scope:second = {
				is_female = yes
				is_great_granddaughterson_in_law_of_root_trigger = yes
			}
		}
	}

	text = {
		localization_key = relation_great_grandsoninlaw
		trigger = {
			scope:second = {
				is_female = no
				is_great_granddaughterson_in_law_of_root_trigger = yes
			}
		}
	}

	text = {
		localization_key = relation_nieceinlaw
		trigger = {
			scope:second = {
				is_female = yes
				is_nibling_in_law_of = { CHARACTER = root }
			}
		}
	}

	text = {
		localization_key = relation_nephewinlaw
		trigger = {
			scope:second = {
				is_female = no
				is_nibling_in_law_of = { CHARACTER = root }
			}
		}
	}
	
	text = {
		localization_key = relation_ceremonial_liege_female
		trigger = {
			scope:second = {
				is_female = yes
				top_liege = root.top_liege
				tgp_is_ceremonial_liege_trigger = yes
			}
		}
	}

	text = {
		localization_key = relation_ceremonial_liege_male
		trigger = {
			scope:second = {
				is_female = no
				top_liege = root.top_liege
				tgp_is_ceremonial_liege_trigger = yes
			}
		}
	}

	text = {
		localization_key = relation_stepdaughter
		trigger = {
			scope:second = {
				is_female = yes
				any_parent = {
					any_spouse = {
						this = root
						NOT = { is_parent_of = scope:second }
					}
				}
			}
		}
	}

	text = {
		localization_key = relation_stepson
		trigger = {
			scope:second = {
				is_male = yes
				any_parent = {
					any_spouse = {
						this = root
						NOT = { is_parent_of = scope:second }
					}
				}
			}
		}
	}

	text = {
		localization_key = relation_stepsister
		trigger = {
			scope:second = {
				is_female = yes
				any_parent = {
					any_spouse = {
						any_child = {
							this = root
							NOT = { is_sibling_of = scope:second }
						}
					}
				}
			}
		}
	}

	text = {
		localization_key = relation_stepbrother
		trigger = {
			scope:second = {
				is_male = yes
				any_parent = {
					any_spouse = {
						any_child = {
							this = root
							NOT = { is_sibling_of = scope:second }
						}
					}
				}
			}
		}
	}

	text = {
		localization_key = relation_stepmother
		trigger = {
			scope:second = {
				is_female = yes
				any_spouse = {
					any_child = {
						this = root
						NOT = { is_child_of = scope:second }
					}
				}
			}
		}
	}

	text = {
		localization_key = relation_stepfather
		trigger = {
			scope:second = {
				is_male = yes
				any_spouse = {
					any_child = {
						this = root
						NOT = { is_child_of = scope:second }
					}
				}
			}
		}
	}

	text = {
		localization_key = relation_liege_female
		trigger = {
			scope:second = {
				is_female = yes
				any_vassal_or_below = {
					this = root
				}
			}
		}
	}

	text = {
		localization_key = relation_liege_male
		trigger = {
			scope:second = {
				is_female = no
				any_vassal_or_below = {
					this = root
				}
			}
		}
	}

	text = {
		localization_key = relation_councillor_female
		trigger = {
			scope:second = {
				is_female = yes			
				is_councillor_of = root
			}
		}
	}

	text = {
		localization_key = relation_councillor_male
		trigger = {
			scope:second = {
				is_female = no				
				is_councillor_of = root
			}
		}
	}

	text = {
		localization_key = relation_vassal_female
		trigger = {
			scope:second = {
				is_female = yes			
			}
			any_vassal_or_below = {
				this = scope:second
			}
		}
	}

	text = {
		localization_key = relation_vassal_male
		trigger = {
			scope:second = {
				is_female = no				
			}
			any_vassal_or_below = {
				this = scope:second
			}
		}
	}

	text = {
		localization_key = relation_best_friend_female
		trigger = {
			scope:second = {
				OR = {
					has_relation_best_friend = root
					any_memory = {
						memory_type = best_friend_died
						memory_participant:dead_relation ?= root
					}
				}
				is_female = yes
			}
		}
	}

	text = {
		localization_key = relation_friend_female
		trigger = {
			scope:second = {
				OR = {
					has_relation_friend = root
					any_memory = {
						memory_type = best_friend_died
						memory_participant:dead_relation ?= root
					}
				}
				NOR = {
					has_relation_best_friend = root
					any_memory = {
						memory_type = best_friend_died
						memory_participant:dead_relation ?= root
					}
				}
				is_female = yes
			}
		}
	}

	text = {
		localization_key = relation_best_friend_male
		trigger = {
			scope:second = {
				OR = {
					has_relation_best_friend = root
					any_memory = {
						memory_type = best_friend_died
						memory_participant:dead_relation ?= root
					}
				}
				is_female = no
			}
		}
	}

	text = {
		localization_key = relation_friend_male
		trigger = {
			scope:second = {
				OR = {
					has_relation_friend = root
					any_memory = {
						memory_type = best_friend_died
						memory_participant:dead_relation ?= root
					}
				}
				NOR = {
					has_relation_best_friend = root
					any_memory = {
						memory_type = best_friend_died
						memory_participant:dead_relation ?= root
					}
				}
				is_female = no
			}
		}
	}

	text = {
		localization_key = relation_nemesis_female
		trigger = {
			scope:second = {
				OR = {
					any_relation = {
						type = nemesis
						this = root
					}
					any_memory = {
						memory_type = nemesis_died
						memory_participant:dead_relation ?= root
					}
				}
				is_female = yes
			}
		}
	}

	text = {
		localization_key = relation_rival_female
		trigger = {
			scope:second = {
				OR = {
					any_relation = {
						type = rival
						this = root
					}
					any_memory = {
						memory_type = rival_died
						memory_participant:dead_relation ?= root
					}
				}
				is_female = yes
			}
		}
	}

	text = {
		localization_key = relation_nemesis_male
		trigger = {
			scope:second = {
				OR = {
					any_relation = {
						type = nemesis
						this = root
					}
					any_memory = {
						memory_type = nemesis_died
						memory_participant:dead_relation ?= root
					}
				}
				is_female = no
			}
		}
	}

	text = {
		localization_key = relation_rival_male
		trigger = {
			scope:second = {
				OR = {
					any_relation = {
						type = rival
						this = root
					}
					any_memory = {
						memory_type = rival_died
						memory_participant:dead_relation ?= root
					}
				}
				is_female = no
			}
		}
	}

	text = {
		localization_key = relation_crush
		trigger = {
			any_relation = {
				type = crush
				this = scope:second
			}
		}
	}

	text = {
		localization_key = relation_bully
		trigger = {
			scope:second = {
				any_relation = {
					type = victim
					this = root
				}
			}
		}
	}

	text = {
		localization_key = relation_victim
		trigger = {
			scope:second = {
				any_relation = {
					type = bully
					this = root
				}
			}
		}
	}

	text = {
		localization_key = relation_ward
		trigger = {
			scope:second = {
				any_relation = {
					type = guardian
					this = root
				}
			}
		}
	}

	text = {
		localization_key = relation_guardian
		trigger = {
			scope:second = {
				any_relation = {
					type = ward
					this = root
				}
			}
		}
	}

	text = {
		localization_key = relation_foe
		trigger = {
			scope:second = {
				is_at_war_with = root
			}
		}
	}

	text = { #intrigue-mentor
		localization_key = relation_mentor
		trigger = {
			scope:second = {
				any_relation = {
					type = intrigue_student
					this = root
				}
			}
		}
	}

	text = { #intrigue-mentor
		localization_key = relation_student
		trigger = {
			scope:second = {
				any_relation = {
					type = intrigue_mentor
					this = root
				}
			}
		}
	}

	text = {
		localization_key = relation_mentor
		trigger = {
			scope:second = {
				any_relation = {
					type = student
					this = root
				}
			}
		}
	}

	text = {
		localization_key = relation_student
		trigger = {
			scope:second = {
				any_relation = {
					type = mentor
					this = root
				}
			}
		}
	}
	
	text = {
		localization_key = duke_viceroyalty_female_byzantine_group
		trigger = {
			culture = culture:greek
			scope:second = {
				is_female = yes
				government_allows = administrative
			}
			any_vassal_or_below = {
				this = scope:second
				government_allows = administrative
			}
		}
	}


	text = {
		localization_key = duke_viceroyalty_male_byzantine_group
		trigger = {
			culture = culture:greek
			scope:second = {
				is_female = no
				government_allows = administrative
			}
			any_vassal_or_below = {
				this = scope:second
				government_allows = administrative
			}
		}
	}
	
	text = {
		localization_key = relation_fellow_vassal_female
		trigger = {
			scope:second = {
				is_female = yes		
				top_liege != this
			}
			top_liege != this
			liege ?= scope:second.liege
		}
	}

	text = {
		localization_key = relation_fellow_vassal_male
		trigger = {
			scope:second = {
				is_female = no	
				top_liege != this
			}
			top_liege != this
			liege ?= scope:second.liege
		}
	}

	text = {
		localization_key = relation_court_physician_female
		trigger = {
			scope:second = {
				is_female = yes
				has_court_position = court_physician_court_position
				is_court_position_employer = {
					court_position = court_physician_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_court_physician_male
		trigger = {
			scope:second = {
				is_male = yes
				has_court_position = court_physician_court_position
				is_court_position_employer = {
					court_position = court_physician_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_keeper_of_swans_female
		trigger = {
			scope:second = {
				is_female = yes
				has_court_position = keeper_of_swans_court_position
				is_court_position_employer = {
					court_position = keeper_of_swans_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_keeper_of_swans_male
		trigger = {
			scope:second = {
				is_male = yes
				has_court_position = keeper_of_swans_court_position
				is_court_position_employer = {
					court_position = keeper_of_swans_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_travel_leader_female
		trigger = {
			scope:second = {
				is_female = yes
				has_court_position = travel_leader_court_position
				is_court_position_employer = {
					court_position = travel_leader_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_travel_leader_male
		trigger = {
			scope:second = {
				is_male = yes
				has_court_position = travel_leader_court_position
				is_court_position_employer = {
					court_position = travel_leader_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_master_of_horse_female
		trigger = {
			scope:second = {
				is_female = yes
				has_court_position = master_of_horse_court_position
				is_court_position_employer = {
					court_position = master_of_horse_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_master_of_horse_male
		trigger = {
			scope:second = {
				is_male = yes
				has_court_position = master_of_horse_court_position
				is_court_position_employer = {
					court_position = master_of_horse_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_court_jester_female
		trigger = {
			scope:second = {
				is_female = yes
				has_court_position = court_jester_court_position
				is_court_position_employer = {
					court_position = court_jester_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_court_jester_male
		trigger = {
			scope:second = {
				is_male = yes
				has_court_position = court_jester_court_position
				is_court_position_employer = {
					court_position = court_jester_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_master_of_hunt_female
		trigger = {
			scope:second = {
				is_female = yes
				has_court_position = master_of_hunt_court_position
				is_court_position_employer = {
					court_position = master_of_hunt_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_master_of_hunt_male
		trigger = {
			scope:second = {
				is_male = yes
				has_court_position = master_of_hunt_court_position
				is_court_position_employer = {
					court_position = master_of_hunt_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_high_almoner_female
		trigger = {
			scope:second = {
				is_female = yes
				has_court_position = high_almoner_court_position
				is_court_position_employer = {
					court_position = high_almoner_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_high_almoner_male
		trigger = {
			scope:second = {
				is_male = yes
				has_court_position = high_almoner_court_position
				is_court_position_employer = {
					court_position = high_almoner_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_cupbearer_female
		trigger = {
			scope:second = {
				is_female = yes
				has_court_position = cupbearer_court_position
				is_court_position_employer = {
					court_position = cupbearer_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_cupbearer_male
		trigger = {
			scope:second = {
				is_male = yes
				has_court_position = cupbearer_court_position
				is_court_position_employer = {
					court_position = cupbearer_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_seneschal_female
		trigger = {
			scope:second = {
				is_female = yes
				has_court_position = seneschal_court_position
				is_court_position_employer = {
					court_position = seneschal_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_seneschal_male
		trigger = {
			scope:second = {
				is_male = yes
				has_court_position = seneschal_court_position
				is_court_position_employer = {
					court_position = seneschal_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_antiquarian_female
		trigger = {
			scope:second = {
				is_female = yes
				has_court_position = antiquarian_court_position
				is_court_position_employer = {
					court_position = antiquarian_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_antiquarian_male
		trigger = {
			scope:second = {
				is_male = yes
				has_court_position = antiquarian_court_position
				is_court_position_employer = {
					court_position = antiquarian_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_court_tutor_female
		trigger = {
			scope:second = {
				is_female = yes
				has_court_position = court_tutor_court_position
				is_court_position_employer = {
					court_position = court_tutor_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_court_tutor_male
		trigger = {
			scope:second = {
				is_male = yes
				has_court_position = court_tutor_court_position
				is_court_position_employer = {
					court_position = court_tutor_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_royal_architect_female
		trigger = {
			scope:second = {
				is_female = yes
				has_court_position = royal_architect_court_position
				is_court_position_employer = {
					court_position = royal_architect_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_royal_architect_male
		trigger = {
			scope:second = {
				is_male = yes
				has_court_position = royal_architect_court_position
				is_court_position_employer = {
					court_position = royal_architect_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_court_poet_female
		trigger = {
			scope:second = {
				is_female = yes
				has_court_position = court_poet_court_position
				is_court_position_employer = {
					court_position = court_poet_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_court_poet_male
		trigger = {
			scope:second = {
				is_male = yes
				has_court_position = court_poet_court_position
				is_court_position_employer = {
					court_position = court_poet_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_bodyguard_female
		trigger = {
			scope:second = {
				is_female = yes
				has_court_position = bodyguard_court_position
				is_court_position_employer = {
					court_position = bodyguard_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_bodyguard_male
		trigger = {
			scope:second = {
				is_male = yes
				has_court_position = bodyguard_court_position
				is_court_position_employer = {
					court_position = bodyguard_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_champion_female
		trigger = {
			scope:second = {
				is_female = yes
				has_court_position = champion_court_position
				is_court_position_employer = {
					court_position = champion_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_champion_male
		trigger = {
			scope:second = {
				is_male = yes
				has_court_position = champion_court_position
				is_court_position_employer = {
					court_position = champion_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_court_musician_female
		trigger = {
			scope:second = {
				is_female = yes
				has_court_position = court_musician_court_position
				is_court_position_employer = {
					court_position = court_musician_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_court_musician_male
		trigger = {
			scope:second = {
				is_male = yes
				has_court_position = court_musician_court_position
				is_court_position_employer = {
					court_position = court_musician_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_food_taster_female
		trigger = {
			scope:second = {
				is_female = yes
				has_court_position = food_taster_court_position
				is_court_position_employer = {
					court_position = food_taster_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_food_taster_male
		trigger = {
			scope:second = {
				is_male = yes
				has_court_position = food_taster_court_position
				is_court_position_employer = {
					court_position = food_taster_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_akolouthos_male
		trigger = {
			scope:second = { is_male = yes }
			has_court_position = akolouthos_court_position
			is_court_position_employer = {
		        court_position = akolouthos_court_position
		        who = root
		    }
		}
	}

	text = {
		localization_key = relation_akolouthos_female
		trigger = {
			scope:second = { is_female = yes }
			has_court_position = akolouthos_court_position
			is_court_position_employer = {
		        court_position = akolouthos_court_position
		        who = root
		    }
		}
	}
	
	text = {
		localization_key = relation_court_astrologer_male
		trigger = {
			scope:second = { is_male = yes }
			has_court_position = court_astrologer_court_position
			is_court_position_employer = {
		        court_position = court_astrologer_court_position
		        who = root
		    }
		}
	}
	
	text = {
		localization_key = relation_court_astrologer_female
		trigger = {
			scope:second = { is_female = yes }
			has_court_position = court_astrologer_court_position
			is_court_position_employer = {
		        court_position = court_astrologer_court_position
		        who = root
		    }
		}
	}

	text = {
		localization_key = relation_lady_in_waiting_female
		trigger = {
			scope:second = {
				is_female = yes
				has_court_position = lady_in_waiting_court_position
				is_court_position_employer = {
					court_position = lady_in_waiting_court_position
					who = root
				}
			}
		}
	}

	text = { #Shouldn't happen, but who knows ¯\_(ツ)_/¯
		localization_key = relation_lady_in_waiting_male
		trigger = {
			scope:second = {
				is_male = yes
				has_court_position = lady_in_waiting_court_position
				is_court_position_employer = {
					court_position = lady_in_waiting_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_garuda_female
		trigger = {
			scope:second = {
				is_female = yes
				has_court_position = garuda_court_position
				is_court_position_employer = {
					court_position = garuda_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_garuda_male
		trigger = {
			scope:second = {
				is_male = yes
				has_court_position = garuda_court_position
				is_court_position_employer = {
					court_position = garuda_court_position
					who = root
				}
			}
		}
	}

	text = { #Shouldn't happen, but who knows ¯\_(ツ)_/¯
		localization_key = relation_chief_eunuch_female
		trigger = {
			scope:second = {
				is_female = yes
				has_court_position = chief_eunuch_court_position
				is_court_position_employer = {
					court_position = chief_eunuch_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_chief_eunuch_male
		trigger = {
			scope:second = {
				is_male = yes
				has_court_position = chief_eunuch_court_position
				is_court_position_employer = {
					court_position = chief_eunuch_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_court_gardener_female
		trigger = {
			scope:second = {
				is_female = yes
				has_court_position = court_gardener_court_position
				is_court_position_employer = {
					court_position = court_gardener_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_court_gardener_male
		trigger = {
			scope:second = {
				is_male = yes
				has_court_position = court_gardener_court_position
				is_court_position_employer = {
					court_position = court_gardener_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_chief_qadi_female
		trigger = {
			scope:second = {
				is_female = yes
				has_court_position = chief_qadi_court_position
				is_court_position_employer = {
					court_position = chief_qadi_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_chief_qadi_male
		trigger = {
			scope:second = {
				is_male = yes
				has_court_position = chief_qadi_court_position
				is_court_position_employer = {
					court_position = chief_qadi_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_wet_nurse_female
		trigger = {
			scope:second = {
				is_female = yes
				has_court_position = wet_nurse_court_position
				is_court_position_employer = {
					court_position = wet_nurse_court_position
					who = root
				}
			}
		}
	}

	text = { #Shouldn't happen, but who knows ¯\_(ツ)_/¯
		localization_key = relation_wet_nurse_male
		trigger = {
			scope:second = {
				is_male = yes
				has_court_position = wet_nurse_court_position
				is_court_position_employer = {
					court_position = wet_nurse_court_position
					who = root
				}
			}
		}
	}

	text = {
		localization_key = relation_knight
		trigger = {
			scope:second = { is_knight_of = root }
		}
	}
	
	text = {
		localization_key = relation_ally
		trigger = {
			scope:second = {
				is_allied_to = root
			}
		}
	}

	text = {
		localization_key = relation_kinswoman
		trigger = {
			scope:second = {
				is_female = yes
				is_lowborn = no
			}
			scope:second.dynasty = root.dynasty
		}
	}

	text = {
		localization_key = relation_kinsman
		trigger = {
			scope:second = {
				is_male = yes
				is_lowborn = no
			}
			scope:second.dynasty = root.dynasty
		}
	}

	text = {
		localization_key = relation_follower_female
		trigger = {
			is_landed_or_landless_administrative = no
			scope:second = {
				is_courtier_of = root
				is_female = yes
			}
		}
	}

	text = {
		localization_key = relation_follower_male
		trigger = {
			is_landed_or_landless_administrative = no
			scope:second = {
				is_courtier_of = root
				is_male = yes
			}
		}
	}

	text = {
		localization_key = relation_courtier_female
		trigger = {
			scope:second = {
				is_courtier_of = root
				is_female = yes
			}
		}
	}

	text = {
		localization_key = relation_courtier_male
		trigger = {
			scope:second = {
				is_courtier_of = root
				is_male = yes
			}
		}
	}

	text = {
		localization_key = relation_peasant_affair_female
		trigger = {
			any_owned_story = {
				type = story_peasant_affair
				var:peasant_character = {
					this = scope:second
					is_female = yes
				}
			}
		}
	}

	text = {
		localization_key = relation_peasant_affair_male
		trigger = {
			any_owned_story = {
				type = story_peasant_affair
				var:peasant_character = {
					this = scope:second
					is_male = yes
				}
			}
		}
	}

	text = {
		localization_key = relation_agent
		trigger = {
			any_scheme = {
				scheme_is_character_agent = scope:second
			}
		}
	}

	text = {
		localization_key = relation_host_female
		trigger = {
			host ?= scope:second
			scope:second = { is_female = yes }
			NOT = {
				liege ?= scope:second
			}
		}
	}

	text = {
		localization_key = relation_host_male
		trigger = {
			host ?= scope:second
			scope:second = { is_male = yes }
			NOT = {
				liege ?= scope:second
			}
		}
	}

	text = {
		localization_key = relation_leader_female
		trigger = {
			host ?= scope:second
			scope:second = { is_female = yes }
			liege ?= scope:second
			scope:second = { has_government = landless_adventurer_government }
		}
	}

	text = {
		localization_key = relation_leader_male
		trigger = {
			host ?= scope:second
			scope:second = { is_male = yes }
			liege ?= scope:second
			scope:second = { has_government = landless_adventurer_government }
		}
	}

	text = {
		localization_key = relation_liege_female
		trigger = {
			host ?= scope:second
			scope:second = { is_female = yes }
			liege ?= scope:second
		}
	}

	text = {
		localization_key = relation_liege_male
		trigger = {
			host ?= scope:second
			scope:second = { is_male = yes }
			liege ?= scope:second
		}
	}

	text = {
		localization_key = relation_prisoner_female
		trigger = {
			scope:second = {
				is_female = yes
				is_imprisoned_by = root
			}
		}
	}
	
	text = {
		localization_key = relation_movement_leader
		trigger = {
			scope:second = {
				trigger_if = {
					limit = {
						any_character_situation = {
							situation_type = dynastic_cycle
						}
						government_has_flag = government_is_celestial
						root = { government_has_flag = government_is_celestial }
					}
				}
				is_any_movement_leader = yes
				top_participant_group:dynastic_cycle ?= root.top_participant_group:dynastic_cycle
			}
		}
	}

	text = {
		localization_key = relation_prisoner_male
		trigger = {
			scope:second = {
				is_male = yes
				is_imprisoned_by = root
			}
		}
	}

	text = {
		localization_key = relation_jailer_female
		trigger = {
			is_imprisoned_by = scope:second
			scope:second = {
				is_female = yes
			}
		}
	}

	text = {
		localization_key = relation_jailer_male
		trigger = {
			is_imprisoned_by = scope:second
			scope:second = {
				is_male = yes
			}
		}
	}

	text = {
		localization_key = relation_guest_female
		trigger = {
			scope:second = {
				is_female = yes
				host ?= root
			}
		}
	}

	text = {
		localization_key = relation_guest_male
		trigger = {
			scope:second = {
				is_male = yes
				host ?= root
			}
		}
	}

	text = {
		localization_key = relation_old_foe_female
		trigger = {
			root = {
				any_memory = {
					OR = {
						has_memory_type = war_won
						has_memory_type = war_lost
					}
					any_memory_participant = {
						this = scope:second
					}
				}
			}
			scope:second = {
				is_female = yes
			}
		}
	}

	text = {
		localization_key = relation_old_foe_male
		trigger = {
			root = {
				any_memory = {
					OR = {
						has_memory_type = war_won
						has_memory_type = war_lost
					}
					any_memory_participant = {
						this = scope:second
					}
				}
			}
			scope:second = {
				is_male = yes
			}
		}
	}

	text = {
		localization_key = relation_fellow_pilgrim_female
		trigger = {
			root = {
				current_travel_plan ?= {
					travel_leader.involved_activity ?= {
						has_activity_type = activity_pilgrimage
					}
					any_entourage_character = {
						this = scope:second
					}
				}
			}
			scope:second = {
				is_female = yes
			}
		}
	}

	text = {
		localization_key = relation_fellow_pilgrim_male
		trigger = {
			root = {
				current_travel_plan ?= {
					travel_leader.involved_activity ?= {
						has_activity_type = activity_pilgrimage
					}
					any_entourage_character = {
						this = scope:second
					}
				}
			}
			scope:second = {
				is_male = yes
			}
		}
	}

	text = {
		localization_key = relation_fellow_traveler_female
		trigger = {
			root = {
				current_travel_plan ?= {
					any_entourage_character = {
						this = scope:second
					}
				}
			}
			scope:second = {
				is_female = yes
			}
		}
	}

	text = {
		localization_key = relation_fellow_traveler_male
		trigger = {
			root = {
				current_travel_plan ?= {
					any_entourage_character = {
						this = scope:second
					}
				}
			}
			scope:second = {
				is_male = yes
			}
		}
	}

	text = {
		localization_key = relation_fellow_contestant_female
		trigger = {
			root = {
				involved_activity ?= {
					has_activity_type = activity_tournament
					any_guest_subset_current_phase = { #you're participating
						name = contestant
						this = root
					}
					any_guest_subset_current_phase = { #they are participating
						name = contestant
						this = scope:second
					}
				}
			}
			scope:second = {
				is_female = yes
			}
		}
	}

	text = {
		localization_key = relation_fellow_contestant_male
		trigger = {
			root = {
				involved_activity ?= {
					has_activity_type = activity_tournament
					any_guest_subset_current_phase = { #you're participating
						name = contestant
						this = root
					}
					any_guest_subset_current_phase = { #they are participating
						name = contestant
						this = scope:second
					}
				}
			}
			scope:second = {
				is_male = yes
			}
		}
	}

	text = {
		localization_key = relation_fellow_attendee_female
		trigger = {
			root = {
				involved_activity ?= {
					has_activity_type = activity_tournament
					any_attending_character = { this = scope:second }
				}
			}
			scope:second = {
				is_female = yes
			}
		}
	}

	text = {
		localization_key = relation_fellow_attendee_male
		trigger = {
			root = {
				involved_activity ?= {
					has_activity_type = activity_tournament
					any_attending_character = { this = scope:second }
				}
			}
			scope:second = {
				is_male = yes
			}
		}
	}

	text = {
		localization_key = relation_acquaintance_female
		trigger = {
			scope:second = {
				is_female = yes
			}
		}
	}

	text = {
		localization_key = relation_acquaintance_male
		trigger = {
			scope:second = {
				is_male = yes
			}
		}
	}
}

