# Standard Values
@pos_compat_high = 30
@pos_compat_medium = 15
@pos_compat_low = 5

@neg_compat_high = -30
@neg_compat_medium = -15
@neg_compat_low = -5

# INTRIGUE OUTCOMES
education_intrigue_1 = {
	minimum_age = 16
	intrigue = 2
	category = education
	monthly_intrigue_lifestyle_xp_gain_mult = 0.1
	domain_limit = -1
	
	ruler_designer_cost = 0
	
	culture_modifier = {
		parameter = poorly_educated_leaders_distrusted
		feudal_government_opinion = -10
	}
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_education_intrigue_1_desc
			}
			desc = trait_education_intrigue_1_character_desc
		}
	}

	group = education_intrigue
	level = 1
	flag = level_1_education
	flag = civilian_province
}
education_intrigue_2 = {
	minimum_age = 16
	intrigue = 4
	category = education
	monthly_intrigue_lifestyle_xp_gain_mult = 0.2
	
	ruler_designer_cost = 20
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_education_intrigue_2_desc
			}
			desc = trait_education_intrigue_2_character_desc
		}
	}

	group = education_intrigue
	level = 2
	flag = level_2_education
	flag = civilian_province
}
education_intrigue_3 = {
	minimum_age = 16
	intrigue = 6
	category = education
	monthly_intrigue_lifestyle_xp_gain_mult = 0.3
	domain_limit = 1
	
	ruler_designer_cost = 40
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_education_intrigue_3_desc
			}
			desc = trait_education_intrigue_3_character_desc
		}
	}

	group = education_intrigue
	level = 3
	flag = level_3_education
	flag = civilian_province
}
education_intrigue_4 = {
	minimum_age = 16
	intrigue = 8
	category = education
	monthly_intrigue_lifestyle_xp_gain_mult = 0.4
	domain_limit = 2
	
	ruler_designer_cost = 80
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_education_intrigue_4_desc
			}
			desc = trait_education_intrigue_4_character_desc
		}
	}

	group = education_intrigue
	level = 4
	flag = level_4_education
	flag = civilian_province
}
education_intrigue_5 = {
	minimum_age = 16
	intrigue = 10
	diplomacy = 3
	category = education
	monthly_intrigue_lifestyle_xp_gain_mult = 0.5
	monthly_diplomacy_lifestyle_xp_gain_mult = 0.25
	owned_hostile_scheme_success_chance_max_add = 10
	flag = agent_acceptance_25
	domain_limit = 3
	
	ruler_designer_cost = 150
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_education_intrigue_5_desc
			}
			desc = trait_education_intrigue_5_character_desc
		}
	}

	random_creation_weight = 0
	group = education_intrigue
	level = 5
	flag = level_5_education
	flag = civilian_province
}

# DIPLOMACY OUTCOMES
education_diplomacy_1 = {
	minimum_age = 16
	diplomacy = 2
	category = education
	monthly_diplomacy_lifestyle_xp_gain_mult = 0.1
	domain_limit = -1
	
	ruler_designer_cost = 0
	
	culture_modifier = {
		parameter = poorly_educated_leaders_distrusted
		feudal_government_opinion = -10
	}
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_education_diplomacy_1_desc
			}
			desc = trait_education_diplomacy_1_character_desc
		}
	}

	group = education_diplomacy
	level = 1
	flag = level_1_education
	flag = civilian_province
}
education_diplomacy_2 = {
	minimum_age = 16
	diplomacy = 4
	category = education
	monthly_diplomacy_lifestyle_xp_gain_mult = 0.2
	
	ruler_designer_cost = 20

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_education_diplomacy_2_desc
			}
			desc = trait_education_diplomacy_2_character_desc
		}
	}

	group = education_diplomacy
	level = 2
	flag = level_2_education
	flag = civilian_province
}
education_diplomacy_3 = {
	minimum_age = 16
	diplomacy = 6
	category = education
	monthly_diplomacy_lifestyle_xp_gain_mult = 0.3
	domain_limit = 1
	
	ruler_designer_cost = 40
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_education_diplomacy_3_desc
			}
			desc = trait_education_diplomacy_3_character_desc
		}
	}

	group = education_diplomacy
	level = 3
	flag = level_3_education
	flag = civilian_province
}
education_diplomacy_4 = {
	minimum_age = 16
	diplomacy = 8
	category = education
	monthly_diplomacy_lifestyle_xp_gain_mult = 0.4
	domain_limit = 2
	
	ruler_designer_cost = 80

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_education_diplomacy_4_desc
			}
			desc = trait_education_diplomacy_4_character_desc
		}
	}
	
	culture_modifier = {
		parameter = elephant_bonuses_for_rank_4_education
		elephant_cavalry_damage_mult = 0.1
		elephant_cavalry_toughness_mult = 0.1
		elephant_cavalry_recruitment_cost_mult = -0.1
		elephant_cavalry_maintenance_mult = -0.1
		jungle_construction_gold_cost = -0.1
	}

	group = education_diplomacy
	level = 4
	flag = level_4_education
	flag = civilian_province
}
education_diplomacy_5 = {
	minimum_age = 16
	diplomacy = 10
	martial = 3
	category = education
	monthly_diplomacy_lifestyle_xp_gain_mult = 0.5
	monthly_martial_lifestyle_xp_gain_mult = 0.25
	owned_personal_scheme_success_chance_max_add = 10
	flag = offer_vassalisation_25
	flag = better_war_hostages
	domain_limit = 3
	
	ruler_designer_cost = 150

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_education_diplomacy_5_desc
			}
			desc = trait_education_diplomacy_5_character_desc
		}
	}
	
	culture_modifier = {
		parameter = elephant_bonuses_for_rank_4_education
		elephant_cavalry_damage_mult = 0.1
		elephant_cavalry_toughness_mult = 0.1
		elephant_cavalry_recruitment_cost_mult = -0.1
		elephant_cavalry_maintenance_mult = -0.1
		jungle_construction_gold_cost = -0.1
	}

	random_creation_weight = 0
	group = education_diplomacy
	level = 5
	flag = level_5_education
	flag = civilian_province
}

# STEWARDSHIP OUTCOMES
education_stewardship_1 = { #Indulgent wastrel
	minimum_age = 16
	stewardship = 2
	category = education
	monthly_stewardship_lifestyle_xp_gain_mult = 0.1
	domain_limit = -1
	
	ruler_designer_cost = 0
	
	culture_modifier = {
		parameter = poorly_educated_leaders_distrusted
		feudal_government_opinion = -10
	}
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_education_stewardship_1_desc
			}
			desc = trait_education_stewardship_1_character_desc
		}
	}

	group = education_stewardship
	level = 1
	flag = level_1_education
	flag = civilian_province
}
education_stewardship_2 = { #Thrifty clerk
	minimum_age = 16
	stewardship = 4
	category = education
	monthly_stewardship_lifestyle_xp_gain_mult = 0.2
	
	ruler_designer_cost = 20
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_education_stewardship_2_desc
			}
			desc = trait_education_stewardship_2_character_desc
		}
	}

	group = education_stewardship
	level = 2
	flag = level_2_education
	flag = civilian_province
}
education_stewardship_3 = {	#Fortune builder
	minimum_age = 16
	stewardship = 6
	category = education
	monthly_stewardship_lifestyle_xp_gain_mult = 0.3
	domain_limit = 1
	
	ruler_designer_cost = 40
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_education_stewardship_3_desc
			}
			desc = trait_education_stewardship_3_character_desc
		}
	}

	group = education_stewardship
	level = 3
	flag = level_3_education
	flag = civilian_province
}
education_stewardship_4 = {
	minimum_age = 16
	stewardship = 8
	category = education
	monthly_stewardship_lifestyle_xp_gain_mult = 0.4
	domain_limit = 2
	
	culture_modifier = {
		parameter = elephant_bonuses_for_rank_4_education
		world_innovation_elephants_development_growth_factor = 0.3
		elephant_cavalry_recruitment_cost_mult = -0.2
		elephant_cavalry_maintenance_mult = -0.2
		jungle_construction_gold_cost = -0.2
	}
	
	ruler_designer_cost = 80
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_education_stewardship_4_desc
			}
			desc = trait_education_stewardship_4_character_desc
		}
	}

	group = education_stewardship
	level = 4
	flag = level_4_education
	flag = civilian_province
}
education_stewardship_5 = {
	minimum_age = 16
	stewardship = 10
	learning = 3
	category = education
	monthly_stewardship_lifestyle_xp_gain_mult = 0.5
	monthly_learning_lifestyle_xp_gain_mult = 0.25
	vassal_tax_mult = 0.25
	domain_limit = 3
	
	culture_modifier = {
		parameter = elephant_bonuses_for_rank_4_education
		world_innovation_elephants_development_growth_factor = 0.3
		elephant_cavalry_recruitment_cost_mult = -0.2
		elephant_cavalry_maintenance_mult = -0.2
		jungle_construction_gold_cost = -0.2
	}
	
	ruler_designer_cost = 150
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_education_stewardship_5_desc
			}
			desc = trait_education_stewardship_5_character_desc
		}
	}

	random_creation_weight = 0
	group = education_stewardship
	level = 5
	flag = level_5_education
	flag = civilian_province
}

# MARTIAL OUTCOMES
education_martial_1 = {
	minimum_age = 16
	martial = 2
	category = education
	monthly_martial_lifestyle_xp_gain_mult = 0.1
	domain_limit = -1
	
	culture_modifier = {
		parameter = poorly_educated_leaders_distrusted
		feudal_government_opinion = -10
	}
	
	culture_modifier = {
		parameter = prowess_from_martial_education
		prowess = 1
	}
	
	culture_modifier = {
		parameter = martial_education_more_valued
		same_culture_opinion = 1
		attraction_opinion = 4
	}
	
	ruler_designer_cost = 0
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_education_martial_1_desc
			}
			desc = trait_education_martial_1_character_desc
		}
	}

	group = education_martial
	level = 1
	flag = level_1_education
	flag = military_province
	
	add_commander_trait = yes
}
education_martial_2 = { #Tough soldier
	minimum_age = 16
	martial = 4
	category = education
	monthly_martial_lifestyle_xp_gain_mult = 0.2
	
	culture_modifier = {
		parameter = prowess_from_martial_education
		prowess = 2
	}
	
	culture_modifier = {
		parameter = martial_education_more_valued
		same_culture_opinion = 2
		attraction_opinion = 6
	}
	
	ruler_designer_cost = 20
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_education_martial_2_desc
			}
			desc = trait_education_martial_2_character_desc
		}
	}

	group = education_martial
	level = 2
	flag = level_2_education
	flag = military_province
	add_commander_trait = yes
}
education_martial_3 = { #Skilled tactician
	minimum_age = 16
	martial = 6
	category = education
	monthly_martial_lifestyle_xp_gain_mult = 0.3
	domain_limit = 1
	
	culture_modifier = {
		parameter = prowess_from_martial_education
		prowess = 3
	}
	
	culture_modifier = {
		parameter = martial_education_more_valued
		same_culture_opinion = 3
		attraction_opinion = 8
	}
	
	ruler_designer_cost = 40
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_education_martial_3_desc
			}
			desc = trait_education_martial_3_character_desc
		}
	}

	group = education_martial
	level = 3
	flag = level_3_education
	flag = military_province
	add_commander_trait = yes
}
education_martial_4 = { #Brilliant strategist
	minimum_age = 16
	martial = 8
	category = education
	monthly_martial_lifestyle_xp_gain_mult = 0.4
	domain_limit = 2
	
	culture_modifier = {
		parameter = prowess_from_martial_education
		prowess = 4
	}
	
	culture_modifier = {
		parameter = martial_education_more_valued
		same_culture_opinion = 4
		attraction_opinion = 10
	}
	
	culture_modifier = {
		parameter = elephant_bonuses_for_rank_4_education
		elephant_cavalry_damage_mult = 0.2
		elephant_cavalry_toughness_mult = 0.1
		elephant_cavalry_pursuit_add = 20
		jungle_advantage = 5
	}
	
	ruler_designer_cost = 80
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_education_martial_4_desc
			}
			desc = trait_education_martial_4_character_desc
		}
	}

	group = education_martial
	level = 4
	flag = level_4_education
	flag = military_province
	add_commander_trait = yes
}
education_martial_5 = {
	minimum_age = 16
	martial = 10
	stewardship = 3
	category = education
	monthly_martial_lifestyle_xp_gain_mult = 0.5
	monthly_stewardship_lifestyle_xp_gain_mult = 0.25
	army_siege_value_mult = 0.5
	movement_speed = 0.2
	domain_limit = 3
	
	culture_modifier = {
		parameter = prowess_from_martial_education
		prowess = 5
	}
	
	culture_modifier = {
		parameter = martial_education_more_valued
		same_culture_opinion = 5
		attraction_opinion = 10
	}
	
	culture_modifier = {
		parameter = elephant_bonuses_for_rank_4_education
		elephant_cavalry_damage_mult = 0.2
		elephant_cavalry_toughness_mult = 0.1
		elephant_cavalry_pursuit_add = 20
		jungle_advantage = 5
	}
	
	ruler_designer_cost = 150
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_education_martial_5_desc
			}
			desc = trait_education_martial_5_character_desc
		}
	}

	random_creation_weight = 0
	group = education_martial
	level = 5
	flag = level_5_education
	flag = military_province
	add_commander_trait = yes
}

# LEARNING OUTCOMES
education_learning_1 = {
	minimum_age = 16
	learning = 2
	category = education
	monthly_learning_lifestyle_xp_gain_mult = 0.1
	domain_limit = -1
	
	culture_modifier = {
		parameter = poorly_educated_leaders_distrusted
		feudal_government_opinion = -10
	}
	
	culture_modifier = {
		parameter = prowess_from_religious_traits
		prowess = 1
	}

	culture_modifier = {
		parameter = innovation_from_learning_traits
		cultural_head_fascination_mult = 0.05
	}
	
	faith_modifier = {
		parameter = neow_innovation_from_learning_traits
		cultural_head_fascination_mult = 0.05
	}

	culture_modifier = {
		parameter = build_bonuses_on_religious_traits
		church_holding_build_speed = -0.05
		church_holding_holding_build_speed = -0.05
	}
	
	ruler_designer_cost = 0
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_education_learning_1_desc
			}
			desc = trait_education_learning_1_character_desc
		}
	}

	group = education_learning
	level = 1
	flag = level_1_education
	flag = civilian_province
}
education_learning_2 = {
	minimum_age = 16
	learning = 4
	category = education
	monthly_learning_lifestyle_xp_gain_mult = 0.2
	
	culture_modifier = {
		parameter = prowess_from_religious_traits
		prowess = 2
	}

	culture_modifier = {
		parameter = innovation_from_learning_traits
		cultural_head_fascination_mult = 0.1
	}
	
	faith_modifier = {
		parameter = neow_innovation_from_learning_traits
		cultural_head_fascination_mult = 0.1
	}

	culture_modifier = {
		parameter = build_bonuses_on_religious_traits
		church_holding_build_speed = -0.1
		church_holding_holding_build_speed = -0.1
	}
	
	ruler_designer_cost = 20
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_education_learning_2_desc
			}
			desc = trait_education_learning_2_character_desc
		}
	}

	group = education_learning
	level = 2
	flag = level_2_education
	flag = civilian_province
}
education_learning_3 = {
	minimum_age = 16
	learning = 6
	category = education
	monthly_learning_lifestyle_xp_gain_mult = 0.3
	domain_limit = 1
	
	culture_modifier = {
		parameter = prowess_from_religious_traits
		prowess = 3
	}

	culture_modifier = {
		parameter = innovation_from_learning_traits
		cultural_head_fascination_mult = 0.15
	}
	
	faith_modifier = {
		parameter = neow_innovation_from_learning_traits
		cultural_head_fascination_mult = 0.15
	}

	culture_modifier = {
		parameter = build_bonuses_on_religious_traits
		church_holding_build_speed = -0.15
		church_holding_holding_build_speed = -0.15
	}

	ruler_designer_cost = 40
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_education_learning_3_desc
			}
			desc = trait_education_learning_3_character_desc
		}
	}

	group = education_learning
	level = 3
	flag = level_3_education
	flag = civilian_province
}
education_learning_4 = {
	minimum_age = 16
	learning = 8
	category = education
	monthly_learning_lifestyle_xp_gain_mult = 0.4
	domain_limit = 2
	
	culture_modifier = {
		parameter = prowess_from_religious_traits
		prowess = 4
	}

	culture_modifier = {
		parameter = innovation_from_learning_traits
		cultural_head_fascination_mult = 0.2
	}
	
	faith_modifier = {
		parameter = neow_innovation_from_learning_traits
		cultural_head_fascination_mult = 0.2
	}

	culture_modifier = {
		parameter = build_bonuses_on_religious_traits
		church_holding_build_speed = -0.2
		church_holding_holding_build_speed = -0.2
		church_holding_build_gold_cost = -0.05
	}
	
	culture_modifier = {
		parameter = elephant_bonuses_for_rank_4_education
		world_innovation_elephants_development_growth_factor = 0.3
		elephant_cavalry_maintenance_mult = -0.2
		elephant_cavalry_toughness_mult = 0.1
		elephant_cavalry_screen_add = 20
		jungle_attrition_mult = -0.35
	}
	
	ruler_designer_cost = 80
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_education_learning_4_desc
			}
			desc = trait_education_learning_4_character_desc
		}
	}
	
	group = education_learning
	level = 4
	flag = level_4_education
	flag = civilian_province
}
education_learning_5 = {
	minimum_age = 16
	learning = 10
	intrigue = 3
	category = education
	monthly_learning_lifestyle_xp_gain_mult = 0.5
	monthly_intrigue_lifestyle_xp_gain_mult = 0.25
	development_growth = 0.1
	county_fertility_growth_mult = small_county_fertility_growth_gain
	domain_limit = 3
	
	culture_modifier = {
		parameter = prowess_from_religious_traits
		prowess = 4
	}

	culture_modifier = {
		parameter = innovation_from_learning_traits
		cultural_head_fascination_mult = 0.25
	}
	
	faith_modifier = {
		parameter = neow_innovation_from_learning_traits
		cultural_head_fascination_mult = 0.25
	}

	culture_modifier = {
		parameter = build_bonuses_on_religious_traits
		church_holding_build_speed = -0.2
		church_holding_holding_build_speed = -0.2
		church_holding_build_gold_cost = -0.05
	}
	
	culture_modifier = {
		parameter = elephant_bonuses_for_rank_4_education
		world_innovation_elephants_development_growth_factor = 0.3
		elephant_cavalry_maintenance_mult = -0.2
		elephant_cavalry_toughness_mult = 0.1
		elephant_cavalry_screen_add = 20
		jungle_attrition_mult = -0.35
	}
	
	ruler_designer_cost = 150
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_education_learning_5_desc
			}
			desc = trait_education_learning_5_character_desc
		}
	}
	
	random_creation_weight = 0
	group = education_learning
	level = 5
	flag = level_5_education
	flag = civilian_province
}

################### LIFESTYLE ##################
diplomat = {
	category = lifestyle

	diplomacy = 3
	personal_scheme_phase_duration_add = medium_scheme_phase_duration_bonus_value
	independent_ruler_opinion = 20
	monthly_influence = 1
	
	ruler_designer_cost = 50

	culture_modifier = {
		parameter = astute_diplomat_bonus
		diplomacy = 2
		independent_ruler_opinion = 10
		vassal_opinion = 10
	}

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_diplomat_desc
			}
			desc = trait_diplomat_character_desc
		}
	}

	#AI Values
	ai_energy = 20
	ai_sociability = low_positive_ai_value
	ai_amenity_target_baseline = 0.2

	compatibility = {
		diplomat = @pos_compat_medium
		family_first = @pos_compat_medium
		august = @pos_compat_medium
		gregarious = @pos_compat_low
		shy = @neg_compat_low
	}
}

family_first = {
	category = lifestyle

	fertility = 0.2
	dynasty_house_opinion = 10
	close_relative_opinion = 15
	stress_loss_mult = 0.2
	domain_limit = 1
	
	ruler_designer_cost = 50

	name = {
		first_valid = {
			triggered_desc = {
				trigger = { NOT = { exists = this } }
				desc = trait_family_first_neutral
			}
			triggered_desc = {
				trigger = { is_female = yes }
				desc = trait_family_first_female
			}
			desc = trait_family_first_male
		}
	}

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_family_first_desc
			}
			desc = trait_family_first_character_desc
		}
	}

	#AI Values
	ai_energy = 20
	ai_sociability = low_positive_ai_value

	culture_modifier = {
		parameter = bonuses_from_patriarch_matriarch_trait
		levy_size = 0.1
		monthly_prestige = 1
	}
	
	compatibility = {
		diplomat = @pos_compat_medium
		family_first = @pos_compat_medium
		august = @pos_compat_medium
		gregarious = @pos_compat_low
		shy = @neg_compat_low
	}
}

august = {
	category = lifestyle
	
	diplomacy = 2
	martial = 1
	monthly_prestige = 1
	flag = initial_legitimacy_boost
	
	ruler_designer_cost = 50

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_august_desc
			}
			desc = trait_august_character_desc
		}
	}

	#AI Values
	ai_energy = 20
	ai_amenity_target_baseline = 0.2
	ai_amenity_spending = 0.1
	
	compatibility = {
		diplomat = @pos_compat_medium
		family_first = @pos_compat_medium
		august = @pos_compat_medium
		gregarious = @pos_compat_low
		shy = @neg_compat_low
	}
}

lifestyle_reveler = {
	category = lifestyle
	icon = reveler.dds

	# Modifiers
	courtly_opinion = 5
	intrigue = 1
	same_opinion = 15
	culture_modifier = {
		parameter = reveler_traits_more_valued
		monthly_prestige = 0.25
	}
	
	track = {
		50 = {
			courtly_opinion = 5
			diplomacy = 1
			intrigue = 1
			culture_modifier = {
				parameter = reveler_traits_more_valued
				monthly_prestige = 0.5
			}
		}
		100 = {
			courtly_opinion = 5
			diplomacy = 2
			intrigue = 1
			owned_hostile_scheme_success_chance_add = 10
			culture_modifier = {
				parameter = reveler_traits_more_valued
				monthly_prestige = 0.75
			}
		}
	}

	ruler_designer_cost = 20

	# AI Values
	ai_greed = 25
	ai_sociability = medium_positive_ai_value
	ai_amenity_target_baseline = 0.2

	# Loc
	name = {
		first_valid = {
			#Legendary Reveler
			triggered_desc = {
				trigger = {
					exists = this
					has_trait_xp = {
						trait = lifestyle_reveler
						value >= 100
					}
				}
				desc = trait_reveler_3
			}
			#Famous Reveler
			triggered_desc = {
				trigger = { 
					exists = this
					has_trait_xp = {
						trait = lifestyle_reveler
						value >= 50
					}
				}
				desc = trait_reveler_2
			}
			#Eager Reveler
			desc = trait_reveler_1
		}
	}

	# Loc
	desc = {
		first_valid = {
			#The trait can never go higher than the first level if it's not assigned to a character
			triggered_desc = {
				trigger = { 
					NOT = { exists = this } 
				}
				desc = trait_reveler_1_desc
			}
			triggered_desc = {
				trigger = { 
					has_trait_xp = {
						trait = lifestyle_reveler
						value >= 100
					}
				}
				desc = trait_reveler_3_character_desc
			}
			triggered_desc = {
				trigger = { 
					has_trait_xp = {
						trait = lifestyle_reveler
						value >= 50
					}
				}
				desc = trait_reveler_2_character_desc
			}
			desc = trait_reveler_1_character_desc
		}
	}

	compatibility = {
		gregarious = @pos_compat_low
		shy = @neg_compat_low
		lustful = @pos_compat_low
		chaste = @neg_compat_low
		drunkard = @pos_compat_low
		temperate = @neg_compat_low
		gluttonous = @pos_compat_low
	}
}

lifestyle_blademaster = {
	category = lifestyle
	icon = blademaster.dds

	# Modifiers
	negate_health_penalty_add = 0.25
	prowess = 3
	culture_modifier = {
		parameter = trait_county_opinion_modifiers
		county_opinion_add = 2
	}
	culture_modifier = {
		parameter = blademaster_trait_bonuses
		attraction_opinion = 5
		monthly_prestige = 0.25
	}
	culture_modifier = {
		parameter = blademaster_traits_give_learning
		learning = 2
	}	

	track = {
		50 = {
			negate_health_penalty_add = 0.25
			prowess = 3
			culture_modifier = {
				parameter = trait_county_opinion_modifiers
				county_opinion_add = 3
			}			
			culture_modifier = {
				parameter = blademaster_trait_bonuses
				attraction_opinion = 5
				monthly_prestige = 0.25
			}
			culture_modifier = {
				parameter = blademaster_traits_give_learning
				learning = 2
			}
		}
		100 = {
			negate_health_penalty_add = 0.5
			prowess = 6
			
			culture_modifier = {
				parameter = trait_county_opinion_modifiers
				county_opinion_add = 5
			}
			
			culture_modifier = {
				parameter = blademaster_trait_bonuses
				attraction_opinion = 5
				monthly_prestige = 0.5
			}

			culture_modifier = {
				parameter = blademaster_traits_give_learning
				learning = 2
			}
		}
	}

	ruler_designer_cost = 20

	# Loc
	name = {
		first_valid = {
			#Legendary Blademaster
			triggered_desc = {
				trigger = {
					exists = this
					has_trait_xp = {
						trait = lifestyle_blademaster
						value >= 100
					}
				}
				desc = trait_blademaster_3
			}
			#Blademaster
			triggered_desc = {
				trigger = { 
					exists = this
					has_trait_xp = {
						trait = lifestyle_blademaster
						value >= 50
					}
				}
				desc = trait_blademaster_2
			}
			#Aspiring Blademaster
			desc = trait_blademaster_1
		}
	}

	# Loc
	desc = {
		first_valid = {
			#The trait can never go higher than the first level if it's not assigned to a character
			triggered_desc = {
				trigger = { 
					NOT = { exists = this } 
				}
				desc = trait_blademaster_1_desc
			}
			triggered_desc = {
				trigger = { 
					has_trait_xp = {
						trait = lifestyle_blademaster
						value >= 100
					}
				}
				desc = trait_blademaster_3_character_desc
			}
			triggered_desc = {
				trigger = { 
					has_trait_xp = {
						trait = lifestyle_blademaster
						value >= 50
					}
				}
				desc = trait_blademaster_2_character_desc
			}
			desc = trait_blademaster_1_character_desc
		}
	}

	compatibility = {
		brave = @pos_compat_low
		craven = @neg_compat_low
	}
}

lifestyle_hunter = {
	icon = hunter.dds
	category = lifestyle
	same_opinion = 10
	ruler_designer_cost = 20
	stress_loss_mult = 0.05
	prowess = 1
	culture_modifier = {
		parameter = hunting_traits_more_valued
		monthly_prestige = 0.5
	}
	culture_modifier = {
		parameter = hunting_traits_more_pious
		monthly_piety = 0.3
	}
	culture_modifier = {
		parameter = forest_trait_bonuses
		forest_advantage = 1
		taiga_advantage = 1
	}
	culture_modifier = {
		parameter = jungle_trait_bonuses
		jungle_advantage = 1
	}

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_lifestyle_hunter_desc
			}
			desc = trait_lifestyle_hunter_character_desc
		}
	}

	tracks = {
		hunter = {
			50 = {
				stress_loss_mult = 0.05
				prowess = 1
				health = 0.05
				learning = 1
				glory_hound_opinion = 5
				culture_modifier = {
					parameter = hunting_traits_more_valued
					monthly_prestige = 0.5
					glory_hound_same_culture_opinion = 5
				}
				culture_modifier = {
					parameter = hunting_traits_more_pious
					monthly_piety = 0.3
					glory_hound_same_faith_opinion = 5
				}
				culture_modifier = {
					parameter = forest_trait_bonuses
					forest_advantage = 1
					taiga_advantage = 1
				}
				culture_modifier = {
					parameter = jungle_trait_bonuses
					jungle_advantage = 1
				}			
			}
			100 = {
				stress_loss_mult = 0.1
				prowess = 2
				health = 0.15
				learning = 1
				glory_hound_opinion = 10
				culture_modifier = {
					parameter = hunting_traits_more_valued
					monthly_prestige = 0.5
					glory_hound_same_culture_opinion = 5
				}
				culture_modifier = {
					parameter = hunting_traits_more_pious
					monthly_piety = 0.4
					glory_hound_same_faith_opinion = 5
				}
				culture_modifier = {
					parameter = forest_trait_bonuses
					forest_advantage = 1
					taiga_advantage = 1
				}
				culture_modifier = {
					parameter = jungle_trait_bonuses
					jungle_advantage = 1
				}
			}
		}
		falconer = {
			50 = {
				attraction_opinion = 5
				stewardship = 1
				learning = 1
				courtly_opinion = 5
				monthly_prestige = 0.25
				culture_modifier = {
					parameter = hunting_traits_more_valued
					monthly_prestige = 0.5
					courtly_same_culture_opinion = 5
				}
				culture_modifier = {
					parameter = hunting_traits_more_pious
					monthly_piety = 0.15
					courtly_same_faith_opinion = 5
				}
			}
			100 = {
				attraction_opinion = 5
				stewardship = 2
				learning = 1
				courtly_opinion = 10
				monthly_prestige = 0.5
				culture_modifier = {
					parameter = hunting_traits_more_valued
					monthly_prestige = 0.5
					courtly_same_culture_opinion = 5
				}
				culture_modifier = {
					parameter = hunting_traits_more_pious
					monthly_piety = 0.4
					courtly_same_faith_opinion = 5
				}
			}
		}
	}

	compatibility = {
		brave = @pos_compat_low
		diligent = @pos_compat_low
		craven = @neg_compat_low
		lazy = @neg_compat_low
	}

	ai_energy = 15
}

strategist = {
	category = lifestyle

	martial = 3
	diplomacy = 1
	enemy_hard_casualty_modifier = 0.25
	no_water_crossing_penalty = yes
	
	culture_modifier = {
		parameter = formation_fighting_strategist
		max_combat_roll = 4
		enemy_terrain_advantage = -0.2
	}

	culture_modifier = {
		parameter = martial_traits_give_out_hcav_bonus
		heavy_cavalry_damage_mult = 0.1
	}
	
	ruler_designer_cost = 50

	ai_rationality = 30

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_strategist_desc
			}
			desc = trait_strategist_character_desc
		}
	}

	compatibility = {
		strategist = @pos_compat_medium
		overseer = @pos_compat_medium
		gallant = @pos_compat_medium
		brave = @pos_compat_low
		craven = @neg_compat_low
	}
}

overseer = {
	category = lifestyle

	stewardship = 2
	martial = 2
	monthly_county_control_growth_add = 0.5
	epidemic_resistance = 5

	culture_modifier = {
		parameter = martial_traits_give_out_hcav_bonus
		heavy_cavalry_recruitment_cost_mult = -0.1
		heavy_cavalry_maintenance_mult = -0.1
	}
	
	ruler_designer_cost = 50

	ai_rationality = 20

	compatibility = {
		strategist = @pos_compat_medium
		overseer = @pos_compat_medium
		gallant = @pos_compat_medium
		brave = @pos_compat_low
		craven = @neg_compat_low
	}
}

gallant = {
	category = lifestyle
	
	martial = 2
	prowess = 4
	attraction_opinion = 20
	accolade_glory_gain_mult = 0.2
	monthly_prestige_gain_mult = 0.2
	
	culture_modifier = {
		parameter = poet_trait_romance_bonuses
		courting_scheme_phase_duration_add = medium_scheme_phase_duration_bonus_value
	}

	culture_modifier = {
		parameter = martial_traits_give_out_hcav_bonus
		heavy_cavalry_toughness_mult = 0.1
	}
	
	ruler_designer_cost = 50

	ai_boldness = medium_positive_ai_value
	ai_honor = low_positive_ai_value
	ai_sociability = low_positive_ai_value
	ai_amenity_target_baseline = 0.1
	ai_amenity_spending = 0.05

	compatibility = {
		strategist = @pos_compat_medium
		overseer = @pos_compat_medium
		gallant = @pos_compat_medium
		brave = @pos_compat_low
		craven = @neg_compat_low
	}
}

architect = {
	category = lifestyle

	stewardship = 2
	build_speed = -0.15
	holding_build_speed = -0.15
	domicile_build_speed = -0.15
	build_gold_cost = -0.1
	holding_build_gold_cost = -0.1
	domicile_build_gold_cost = -0.1

	culture_modifier = {
		parameter = architect_trait_prestige
		monthly_prestige = 0.5
	}

	culture_modifier = {
		parameter = stewardship_traits_give_out_cav_bonus
		archer_cavalry_toughness_add = 4
		heavy_cavalry_toughness_add = 4
		light_cavalry_toughness_add = 4
	}
	
	ruler_designer_cost = 50
	
	ai_rationality = 10
	ai_energy = 5

	compatibility = {
		architect = @pos_compat_medium
		administrator = @pos_compat_medium
		avaricious = @pos_compat_medium
		diligent = @pos_compat_low
		lazy = @neg_compat_low
		lifestyle_gardener = @pos_compat_low
	}
}

administrator = {
	category = lifestyle

	stewardship = 3
	diplomacy = 1
	parochial_opinion = 10
	vassal_opinion = 5
	tributary_opinion = 5
	epidemic_resistance = 10
	
	ruler_designer_cost = 50

	culture_modifier = {
		parameter = legalistic_administrator_bonuses
		long_reign_bonus_mult = 0.25
	}

	culture_modifier = {
		parameter = stewardship_traits_give_out_cav_bonus
		archer_cavalry_max_size_add = 4 #change it
		heavy_cavalry_max_size_add = 4
		light_cavalry_max_size_add = 4
	}

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_administrator_desc
			}
			desc = trait_administrator_character_desc
		}
	}

	ai_rationality = 20
	ai_energy = 10
	ai_amenity_spending = 0.1

	compatibility = {
		architect = @pos_compat_medium
		administrator = @pos_compat_medium
		avaricious = @pos_compat_medium
		diligent = @pos_compat_low
		lazy = @neg_compat_low
	}
}

avaricious = {
	category = lifestyle

	stewardship = 2
	tax_mult = 0.15

	culture_modifier = {
		parameter = maritime_mercantilism_avaricious_bonus
		stewardship = 2
		tax_mult = 0.10
	}

	culture_modifier = {
		parameter = stewardship_traits_give_out_cav_bonus
		archer_cavalry_maintenance_mult = -0.4
		heavy_cavalry_maintenance_mult = -0.4
		light_cavalry_maintenance_mult = -0.4
	}
	
	ruler_designer_cost = 50

	ai_rationality = -20
	ai_greed = 30
	ai_honor = -20
	ai_compassion = -30
	ai_energy = 20
	ai_amenity_spending = -0.1
	
	compatibility = {
		architect = @pos_compat_medium
		administrator = @pos_compat_medium
		avaricious = @pos_compat_medium
		diligent = @pos_compat_low
		lazy = @neg_compat_low
	}
}

schemer = {
	category = lifestyle
	
	intrigue = 5
	hostile_scheme_phase_duration_add = medium_scheme_phase_duration_bonus_value
	
	ruler_designer_cost = 50

	ai_honor = -20

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_schemer_desc
			}
			desc = trait_schemer_character_desc
		}
	}
	
	compatibility = {
		schemer = @pos_compat_medium
		seducer = @pos_compat_medium
		torturer = @pos_compat_medium
		deceitful = @pos_compat_low
		honest = @neg_compat_low
	}
}

seducer = {
	category = lifestyle

	intrigue = 3
	attraction_opinion = 40
	fertility = 0.2
	
	ruler_designer_cost = 50

	name = {
		first_valid = {
			triggered_desc = {
				trigger = {
					exists = this
					is_female = yes
				}
				desc = trait_seducer_female
			}
			desc = trait_seducer
		}
	}

	ai_honor = -10
	ai_sociability = low_positive_ai_value
	
	compatibility = {
		schemer = @pos_compat_medium
		seducer = @pos_compat_medium
		torturer = @pos_compat_medium
		deceitful = @pos_compat_low
		honest = @neg_compat_low
	}
}

torturer = {
	category = lifestyle

	dread_gain_mult = 0.5
	prowess = 4
	levy_size = 0.1
	enemy_hostile_scheme_phase_duration_add = medium_scheme_phase_duration_malus_value
	
	ruler_designer_cost = 50

	ai_honor = -30
	ai_vengefulness = 20
	ai_boldness = 20
	
	compatibility = {
		schemer = @pos_compat_medium
		seducer = @pos_compat_medium
		torturer = @pos_compat_medium
		deceitful = @pos_compat_low
		honest = @neg_compat_low
	}
}

whole_of_body = {
	category = lifestyle

	health = 0.5
	fertility = 0.2
	stress_gain_mult = -0.2
	
	ruler_designer_cost = 75

	ai_energy = 20

	compatibility = {
		whole_of_body = @pos_compat_medium
		scholar = @pos_compat_medium
		theologian = @pos_compat_medium
		intellect_good_1 = @pos_compat_low
		intellect_good_2 = @pos_compat_low
		intellect_good_3 = @pos_compat_low
		pensive = @pos_compat_low
		shrewd = @pos_compat_low
		diligent = @pos_compat_low
		lazy = @neg_compat_low
		intellect_bad_1 = @neg_compat_low
		intellect_bad_2 = @neg_compat_low
		intellect_bad_3 = @neg_compat_low
	}
}

scholar = {
	category = lifestyle

	learning = 3
	owned_personal_scheme_success_chance_add = 10
	owned_hostile_scheme_success_chance_add = 10
	development_growth_factor = 0.15
	development_decline_factor = -0.15
	county_fertility_growth_mult = 0.15
	
	ruler_designer_cost = 50

	culture_modifier = {
		parameter = prowess_from_religious_traits
		prowess = 2
	}

	culture_modifier = {
		parameter = innovation_from_learning_traits
		cultural_head_fascination_mult = 0.1
	}
	
	faith_modifier = {
		parameter = neow_innovation_from_learning_traits
		cultural_head_fascination_mult = 0.1
	}

	culture_modifier = {
		parameter = build_bonuses_on_religious_traits
		church_holding_build_speed = -0.1
		church_holding_holding_build_speed = -0.1
		church_holding_build_gold_cost = -0.05
		church_holding_holding_build_gold_cost = -0.05
	}

	culture_modifier = { #for FP3's "Irrigation Expert" tradition
		parameter = innovative_traits_more_valued
		drylands_tax_mult = 0.1
		desert_tax_mult = 0.1
		desert_mountains_tax_mult = 0.1
	}

	ai_rationality = 30

	compatibility = {
		whole_of_body = @pos_compat_medium
		scholar = @pos_compat_medium
		theologian = @pos_compat_medium
		lifestyle_gardener = @pos_compat_medium
		intellect_good_1 = @pos_compat_low
		intellect_good_2 = @pos_compat_low
		intellect_good_3 = @pos_compat_low
		pensive = @pos_compat_low
		shrewd = @pos_compat_low
		diligent = @pos_compat_low
		lazy = @neg_compat_low
		intellect_bad_1 = @neg_compat_low
		intellect_bad_2 = @neg_compat_low
		intellect_bad_3 = @neg_compat_low
	}
}

theologian = {
	category = lifestyle
	
	learning = 3
	monthly_piety_gain_mult = 0.2
	domain_limit = 1
	
	ruler_designer_cost = 50

	culture_modifier = {
		parameter = prowess_from_religious_traits
		prowess = 2
	}

	culture_modifier = {
		parameter = build_bonuses_on_religious_traits
		church_holding_build_gold_cost = -0.1
		church_holding_holding_build_gold_cost = -0.1
	}

	ai_rationality = 10
	ai_zeal = 20

	compatibility = {
		whole_of_body = @pos_compat_medium
		scholar = @pos_compat_medium
		theologian = @pos_compat_medium
		intellect_good_1 = @pos_compat_low
		intellect_good_2 = @pos_compat_low
		intellect_good_3 = @pos_compat_low
		pensive = @pos_compat_low
		shrewd = @pos_compat_low
		diligent = @pos_compat_low
		lazy = @neg_compat_low
		intellect_bad_1 = @neg_compat_low
		intellect_bad_2 = @neg_compat_low
		intellect_bad_3 = @neg_compat_low
	}
}

lifestyle_mystic = {
	category = lifestyle
	icon = mystic.dds

	# Modifiers
	learning = 1
	culture_modifier = {
		parameter = prowess_from_religious_traits
		prowess = 1
	}
	culture_modifier = {
		parameter = build_bonuses_on_religious_traits
		church_holding_build_gold_cost = -0.05
		church_holding_holding_build_gold_cost = -0.05
	}
	culture_modifier = {
		parameter = mystic_trait_gives_bonuses
		monthly_income_mult = 0.02
	}

	track = {
		50 = {
			learning = 1
			culture_modifier = {
				parameter = prowess_from_religious_traits
				prowess = 1
			}

			culture_modifier = {
				parameter = build_bonuses_on_religious_traits
				church_holding_build_gold_cost = -0.05
				church_holding_holding_build_gold_cost = -0.05
			}
			
			culture_modifier = {
				parameter = mystic_trait_gives_bonuses
				monthly_income_mult = 0.02
			}			
		}
		100 = {
			learning = 2	
			culture_modifier = {
				parameter = prowess_from_religious_traits
				prowess = 1
			}
			culture_modifier = {
				parameter = build_bonuses_on_religious_traits
				church_holding_build_gold_cost = -0.05
				church_holding_holding_build_gold_cost = -0.05
			}				
			culture_modifier = {
				parameter = mystic_trait_gives_bonuses
				monthly_income_mult = 0.04
			}
		}
	}

	ruler_designer_cost = 20

	# AI Values
	ai_rationality = -10
	ai_zeal = -10

	# Loc
	name = {
		first_valid = {
			#Miracle Worker
			triggered_desc = {
				trigger = {
					exists = this
					has_trait_xp = {
						trait = lifestyle_mystic
						value >= 100
					}
				}
				desc = trait_mystic_3
			}
			#Mystic
			triggered_desc = {
				trigger = { 
					exists = this
					has_trait_xp = {
						trait = lifestyle_mystic
						value >= 50
					}
				}
				desc = trait_mystic_2
			}
			#Wise Woman/Man
			triggered_desc = {
				trigger = {
					exists = this
					is_female = yes 
				}
				desc = trait_mystic_female_1
			}
			desc = trait_mystic_male_1
		}
	}

	# Loc
	desc = {
		first_valid = {
			#The trait can never go higher than the first level if it's not assigned to a character
			triggered_desc = {
				trigger = { 
					NOT = { exists = this } 
				}
				desc = trait_mystic_1_desc
			}
			triggered_desc = {
				trigger = { 
					has_trait_xp = {
						trait = lifestyle_mystic
						value >= 100
					}
				}
				desc = trait_mystic_3_character_desc
			}
			triggered_desc = {
				trigger = { 
					has_trait_xp = {
						trait = lifestyle_mystic
						value >= 50
					}
				}
				desc = trait_mystic_2_character_desc
			}
			desc = trait_mystic_1_character_desc
		}
	}
}

lifestyle_physician = {
	category = lifestyle
	icon = physician.dds

	# Modifiers
	learning = 1
	negate_health_penalty_add = 0.25
	
	track = {
		50 = {
			learning = 1
			negate_health_penalty_add = 0.25
		}
		100 = {
			learning = 2
			negate_health_penalty_add = 0.5
		}
	}
	
	ruler_designer_cost = 20
	
	# AI Values
	ai_rationality = 10

	# Loc
	name = {
		first_valid = {
			#Renowned Physician
			triggered_desc = {
				trigger = {
					exists = this
					has_trait_xp = {
						trait = lifestyle_physician
						value >= 100
					}
				}
				desc = trait_physician_3
			}
			#Physician
			triggered_desc = {
				trigger = { 
					exists = this
					has_trait_xp = {
						trait = lifestyle_physician
						value >= 50
					}
				}
				desc = trait_physician_2
			}
			#Novice Physician
			desc = trait_physician_1
		}
	}

	# Loc
	desc = {
		first_valid = {
			#The trait can never go higher than the first level if it's not assigned to a character
			triggered_desc = {
				trigger = { 
					NOT = { exists = this } 
				}
				desc = trait_physician_1_desc
			}
			triggered_desc = {
				trigger = { 
					has_trait_xp = {
						trait = lifestyle_physician
						value >= 100
					}
				}
				desc = trait_physician_3_character_desc
			}
			triggered_desc = {
				trigger = { 
					has_trait_xp = {
						trait = lifestyle_physician
						value >= 50
					}
				}
				desc = trait_physician_2_character_desc
			}
			desc = trait_physician_1_character_desc
		}
	}

	compatibility = {
		whole_of_body = @pos_compat_low
		scholar = @pos_compat_low
		theologian = @pos_compat_low
	}
}

#Herbalist has been made into a 1 tiered lifestyle trait because no lvl up system exists in the game
lifestyle_herbalist = {
	index = 256
	category = lifestyle

	# Modifiers
	learning = 2
	intrigue = 2
	negate_health_penalty_add = 0.5	
	culture_modifier = {
		parameter = forest_trait_bonuses
		forest_attrition_mult = -0.5
		taiga_attrition_mult = -0.5
	}	
	culture_modifier = {
		parameter = jungle_trait_bonuses
		jungle_attrition_mult = -0.5
	}	
	culture_modifier = {
		parameter = herbalist_trait_gives_bonuses
		monthly_prestige_gain_mult = 0.05
		monthly_learning_lifestyle_xp_gain_mult = 0.05
		diplomacy = 1
	}

	ruler_designer_cost = 50

	# AI Values
	ai_rationality = 10

	# Loc
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = lifestyle_herbalist_desc
			}
			desc = lifestyle_herbalist_character_desc
		}
	}

	compatibility = {
		lifestyle_mystic = @pos_compat_medium
		whole_of_body = @pos_compat_low
		scholar = @pos_compat_low
		theologian = @pos_compat_low
		zealous = @neg_compat_low
		lifestyle_gardener = @pos_compat_medium
	}
}

#Gardener has been made into a 1 tiered lifestyle trait because no lvl up system exists in the game
lifestyle_gardener = {
	category = lifestyle
	icon = gardener.dds
	
	stewardship = 2
	stress_gain_mult = -0.2
	courtier_and_guest_opinion = 10

	culture_modifier = { #for FP3's "Irrigation Expert" tradition
		parameter = innovative_traits_more_valued
		drylands_tax_mult = 0.1
		desert_tax_mult = 0.1
		desert_mountains_tax_mult = 0.1
	}
	
	ruler_designer_cost = 50

	# Loc
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = lifestyle_gardener_desc
			}
			desc = lifestyle_gardener_character_desc
		}
	}

	# AI Values
	ai_rationality = 10

	compatibility = {
		lifestyle_gardener = @pos_compat_medium
		lifestyle_herbalist = @pos_compat_medium
		scholar = @pos_compat_medium
		architect = @pos_compat_low
	}
}

################ PERSONALITY ###############
lustful = {
	category = personality
	opposites = {
		chaste
	}
	#Asexual characters may still have the lustful trait. This is intended to represent asexuals who, whilst not generally experiencing attraction to other people, might still have a high libido.
	fertility = 0.25
	intrigue = 2
	seduce_scheme_phase_duration_add = minor_scheme_phase_duration_bonus_value

	same_opinion = 10
	opposite_opinion = -10
	
	ruler_designer_cost = 25

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_lustful_desc
			}
			desc = trait_lustful_character_desc
		}
	}
	
	ai_honor = very_low_negative_ai_value
	ai_greed = low_positive_ai_value
	ai_energy = very_low_positive_ai_value
	ai_zeal = very_low_negative_ai_value
	ai_sociability = medium_positive_ai_value
	ai_amenity_target_baseline = 0.15
	ai_amenity_spending = 0.1

	compatibility = {
		lustful = @pos_compat_high
		gregarious = @pos_compat_low
		lifestyle_reveler = @pos_compat_low
		seducer = @pos_compat_low
		chaste = @neg_compat_high
		celibate = @neg_compat_high
		shy = @neg_compat_low
	}
}

chaste = {
	category = personality
	opposites = {
		lustful
	}
	
 	fertility = -0.25
 	seduce_scheme_phase_duration_add = major_scheme_phase_duration_malus_value
	learning = 2
	
	same_opinion = 10
	opposite_opinion = -10
	
	ruler_designer_cost = 20

	culture_modifier = {
		parameter = introverted_trait_bonuses
		same_culture_opinion = 10
		monthly_piety_gain_mult = 0.1
	}

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_chaste_desc
			}
			desc = trait_chaste_character_desc
		}
	}
	
	ai_honor = low_positive_ai_value
	ai_greed = low_negative_ai_value
	ai_energy = very_low_positive_ai_value
	ai_zeal = very_low_positive_ai_value
	ai_sociability = low_negative_ai_value

	compatibility = {
		chaste = @pos_compat_medium
		celibate = @pos_compat_medium
		temperate = @pos_compat_low
		calm = @pos_compat_low
		lustful = @neg_compat_high
		deviant = @neg_compat_high
		lovers_pox = @neg_compat_low
		early_great_pox = @neg_compat_low
		great_pox = @neg_compat_low
		lifestyle_reveler = @neg_compat_low
		seducer = @neg_compat_low
	}
}

gluttonous = {
	category = personality
	opposites = {
		temperate
	}

	stewardship = -2
	stress_loss_mult = 0.1
	
	attraction_opinion = -5
	same_opinion = 10
	opposite_opinion = -10
	
	ruler_designer_cost = 20


	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_gluttonous_desc
			}
			desc = trait_gluttonous_character_desc
		}
	}

	ai_greed = medium_positive_ai_value
	ai_energy = very_low_negative_ai_value
	ai_amenity_target_baseline = 0.2
	
	compatibility = {
		gluttonous = @pos_compat_medium
		drunkard = @pos_compat_low
		greedy = @pos_compat_low
		ambitious = @pos_compat_low
		lifestyle_reveler = @pos_compat_medium
		temperate = @neg_compat_medium
	}
}

temperate = {
	category = personality
	opposites = {
		gluttonous
	}
	stewardship = 2
	health = 0.25
	
	courtly_opinion = -10
	
	same_opinion = 10
	opposite_opinion = -10
	
	ruler_designer_cost = 40

	culture_modifier = {
		parameter = introverted_trait_bonuses
		same_culture_opinion = 10
		monthly_piety_gain_mult = 0.1
	}

	culture_modifier = {
		parameter = temperate_trait_bonuses
		same_culture_opinion = 10
		monthly_piety = 0.5
	}

	culture_modifier = {
		parameter = stress_loss_bonus_from_harmonious_traits
		stress_loss_mult = 0.15
	}

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_temperate_desc
			}
			desc = trait_temperate_character_desc
		}
	}
	
	ai_greed = medium_negative_ai_value
	ai_energy = very_low_positive_ai_value
	ai_vengefulness = very_low_negative_ai_value

	compatibility = {
		temperate = @pos_compat_medium
		calm = @pos_compat_low
		content = @pos_compat_low
		chaste = @pos_compat_low
		gluttonous = @neg_compat_medium
		drunkard = @neg_compat_low
		greedy = @neg_compat_low
		lustful = @neg_compat_low
		lifestyle_reveler = @neg_compat_medium
	}
}

greedy = {
	category = personality
	opposites = {
		generous
	}
	diplomacy = -2

	monthly_income_mult = 0.05
	monthly_income_per_stress_level_mult = 0.1
	courtly_opinion = -15
	
	ai_war_chance = 0.5
	ai_amenity_spending = -0.25
	ai_amenity_target_baseline = -0.4
	
	ruler_designer_cost = 30

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_greedy_desc
			}
			desc = trait_greedy_character_desc
		}
	}

	ai_honor = very_low_negative_ai_value
	ai_greed = dominant_positive_ai_value
	ai_compassion = low_negative_ai_value
	
	compatibility = {
		greedy = @pos_compat_low
		ambitious = @pos_compat_low
		generous = @neg_compat_high
		content = @neg_compat_medium
		compassionate = @neg_compat_medium	
	}
}

generous = {
	category = personality
	opposites = {
		greedy
	}
	
	diplomacy = 3
	monthly_income_mult = -0.1
	courtly_opinion = 15
	
	opposite_opinion = -15
	
	
	ruler_designer_cost = 20

	culture_modifier = {
		parameter = trait_county_opinion_modifiers
		county_opinion_add = 5
	}

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_generous_desc
			}
			desc = trait_generous_character_desc
		}
	}

	ai_honor = low_positive_ai_value
	ai_greed = dominant_negative_ai_value
	ai_compassion = medium_positive_ai_value
	ai_sociability = very_low_positive_ai_value
	ai_amenity_spending = 0.2

	compatibility = {
		generous = @pos_compat_high
		compassionate = @pos_compat_medium	
		content = @pos_compat_low
		forgiving = @pos_compat_low
		greedy = @neg_compat_high
		ambitious = @neg_compat_low
	}
}

lazy = {
	category = personality
	opposites = {
		diligent
	}
	diplomacy = -1
	intrigue = -1
	stewardship = -1
	martial = -1
	learning = -1

	character_travel_speed = -10
	
	stress_loss_mult = 0.5
	
	ruler_designer_cost = -10

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_lazy_desc
			}
			desc = trait_lazy_character_desc
		}
	}
	
	ai_vengefulness = very_low_negative_ai_value
	ai_greed = very_low_positive_ai_value
	ai_energy = high_negative_ai_value
	ai_boldness = low_negative_ai_value
	ai_compassion = very_low_negative_ai_value
	ai_sociability = very_low_negative_ai_value

	compatibility = {
		lazy = @pos_compat_medium
		content = @pos_compat_low
		calm = @pos_compat_low
		gluttonous = @pos_compat_low
		diligent = @neg_compat_medium
		ambitious = @neg_compat_low
		eccentric = @neg_compat_low
	}
}

diligent = {
	category = personality
	opposites = {
		lazy
	}
	diplomacy = 2
	stewardship = 3
	learning = 3
	
	parochial_opinion = 5
	
	stress_loss_mult = -0.5
	
	culture_modifier = {
		parameter = hard_working_traits_more_valued
		farmlands_tax_mult = 0.2
		floodplains_tax_mult = 0.2
	}

	culture_modifier = {
		parameter = pragmatic_traits_county_opinion_modifiers
		county_opinion_add = 10
	}
	
	culture_modifier = {
		parameter = honorable_trait_bonuses
		same_culture_opinion = 10
		monthly_prestige_gain_mult = 0.05
	}

	same_opinion = 10
	opposite_opinion = -10

	flag = can_improve_capital_decision
	
	culture_modifier = {
		parameter = trait_county_opinion_modifiers
		county_opinion_add = 5
	}
	
	culture_modifier = {
		parameter = winter_trait_bonuses
		winter_movement_speed = 0.1
	}
	
	culture_modifier = {
		parameter = dry_trait_bonuses
		drylands_min_combat_roll = 2
		desert_min_combat_roll = 2
	}

	culture_modifier = {
		parameter = build_bonuses_on_religious_traits
		church_holding_build_speed = -0.2
		church_holding_holding_build_speed = -0.2
	}
	
	ruler_designer_cost = 40
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_diligent_desc
			}
			desc = trait_diligent_character_desc
		}
	}

	ai_vengefulness = very_low_positive_ai_value
	ai_rationality = low_positive_ai_value
	ai_energy = very_high_positive_ai_value
	ai_boldness = medium_positive_ai_value
	ai_amenity_target_baseline = 0.1
	ai_amenity_spending = 0.1

	compatibility = {
		diligent = @pos_compat_medium
		ambitious = @pos_compat_low
		patient = @pos_compat_low
		whole_of_body = @pos_compat_low
		scholar = @pos_compat_low
		theologian = @pos_compat_low
		pensive = @pos_compat_low
		architect = @pos_compat_low
		administrator = @pos_compat_low
		avaricious = @pos_compat_low
		lazy = @neg_compat_medium
		content = @neg_compat_low
	}
}

wrathful = {
	category = personality
	opposites = {
		calm
	}
	diplomacy = -1
	martial = 3
	intrigue = -1
	
	parochial_opinion = -10
	glory_hound_opinion = 5
	
	courtly_opinion = -10
	
	dread_baseline_add = 20
	
	culture_modifier = {
		parameter = forest_trait_bonuses
		forest_max_combat_roll = 2
		taiga_max_combat_roll = 2
	}
	
	culture_modifier = {
		parameter = jungle_trait_bonuses
		jungle_max_combat_roll = 2
	}
	
	culture_modifier = {
		parameter = mountain_trait_bonuses
		mountains_max_combat_roll = 2
		desert_mountains_max_combat_roll = 2
	}
	
	culture_modifier = {
		parameter = dry_trait_bonuses
		drylands_max_combat_roll = 2
		desert_max_combat_roll = 2
	}

	ai_war_chance = 0.25

	flag = can_duel_criminals_interaction
	
	ruler_designer_cost = 30
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_wrathful_desc
			}
			desc = trait_wrathful_character_desc
		}
	}

	ai_rationality = medium_negative_ai_value
	ai_energy = very_low_positive_ai_value
	ai_boldness = medium_positive_ai_value
	ai_compassion = low_negative_ai_value
	ai_vengefulness = low_positive_ai_value

	compatibility = {
		wrathful = @pos_compat_low
		stubborn = @pos_compat_low
		honest = @pos_compat_low
		vengeful = @pos_compat_low
		calm = @neg_compat_medium
		patient = @neg_compat_medium
		forgiving = @neg_compat_low
		compassionate = @neg_compat_low
		eccentric = @neg_compat_low
	}
}

calm = {
	category = personality
	opposites = {
		wrathful
	}
	diplomacy = 1
	intrigue = 1
	enemy_scheme_secrecy_add = -10
	
	opposite_opinion = -10
	same_opinion = 10
	
	stress_loss_mult = 0.1
	dread_decay_mult = 0.5
	
	culture_modifier = {
		parameter = winter_trait_bonuses
		winter_advantage = 3
	}
	
	culture_modifier = {
		parameter = forest_trait_bonuses
		forest_min_combat_roll = 1
		taiga_min_combat_roll = 1
	}
	
	culture_modifier = {
		parameter = jungle_trait_bonuses
		jungle_min_combat_roll = 1
	}
	
	culture_modifier = {
		parameter = mountain_trait_bonuses
		mountains_min_combat_roll = 2
		desert_mountains_min_combat_roll = 2
	}
	
	culture_modifier = {
		parameter = dry_trait_bonuses
		drylands_min_combat_roll = 2
		desert_min_combat_roll = 2
	}
	
	culture_modifier = {
		parameter = stress_loss_bonus_from_harmonious_traits
		stress_loss_mult = 0.15
	}

	ai_war_chance = -0.25
	
	ruler_designer_cost = 25
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_calm_desc
			}
			desc = trait_calm_character_desc
		}
	}

	ai_rationality = very_high_positive_ai_value
	ai_energy = very_low_negative_ai_value
	ai_boldness = low_negative_ai_value
	ai_vengefulness = very_low_negative_ai_value

	compatibility = {
		calm = @pos_compat_medium
		patient = @pos_compat_medium
		chaste = @pos_compat_low
		temperate = @pos_compat_low
		lazy = @pos_compat_low
		wrathful = @neg_compat_high
		impatient = @neg_compat_medium
	}
}

patient = {
	category = personality
	opposites = {
		impatient
	}

	learning = 2
	enemy_hostile_scheme_phase_duration_add = minor_scheme_phase_duration_malus_value
	parochial_opinion = 10
	liege_opinion = 5
	
	culture_modifier = {
		parameter = winter_trait_bonuses
		winter_advantage = 3
	}
	
	culture_modifier = {
		parameter = forest_trait_bonuses
		forest_min_combat_roll = 2
		taiga_min_combat_roll = 2
	}
	
	culture_modifier = {
		parameter = jungle_trait_bonuses
		jungle_min_combat_roll = 2
	}
	
	culture_modifier = {
		parameter = hard_working_traits_more_valued
		farmlands_tax_mult = 0.2
		floodplains_tax_mult = 0.2
	}

	culture_modifier = { #for FP3's "Irrigation Expert" tradition
		parameter = innovative_traits_more_valued
		drylands_tax_mult = 0.1
		desert_tax_mult = 0.1
		desert_mountains_tax_mult = 0.1
	}
	
	culture_modifier = {
		parameter = stress_loss_bonus_from_harmonious_traits
		stress_loss_mult = 0.15
	}

	opposite_opinion = -15
	
	ai_war_cooldown = 0.5
	
	ruler_designer_cost = 30

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_patient_desc
			}
			desc = trait_patient_character_desc
		}
	}

	ai_rationality = medium_positive_ai_value
	ai_energy = very_low_negative_ai_value
	ai_boldness = low_negative_ai_value
	ai_vengefulness = very_low_positive_ai_value

	compatibility = {
		patient = @pos_compat_medium
		calm = @pos_compat_medium
		stubborn = @pos_compat_low
		temperate = @pos_compat_low
		eccentric = @pos_compat_low
		impatient = @neg_compat_high
		wrathful = @neg_compat_low
		fickle = @neg_compat_low
	}
}

impatient = {
	category = personality
	opposites = {
		patient
	}
	learning = -2
	monthly_prestige_gain_mult = 0.2
	hostile_scheme_phase_duration_add = minor_scheme_phase_duration_bonus_value
	character_travel_speed_mult = 0.25
	character_travel_safety = -10
	
	courtly_opinion = -10
	parochial_opinion = -10
	opinion_of_liege = -5
	opposite_opinion = -15
	
	culture_modifier = {
		parameter = forest_trait_bonuses
		forest_max_combat_roll = 1
		taiga_max_combat_roll = 1
	}
	
	culture_modifier = {
		parameter = jungle_trait_bonuses
		jungle_max_combat_roll = 1
	}
	
	ai_war_cooldown = -0.5

	flag = can_accelerate_schemes_decision
	
	ruler_designer_cost = 25
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_impatient_desc
			}
			desc = trait_impatient_character_desc
		}
	}

	ai_rationality = medium_negative_ai_value
	ai_energy = very_low_positive_ai_value
	ai_boldness = low_positive_ai_value
	ai_vengefulness = very_low_negative_ai_value
	ai_amenity_target_baseline = 0.15
	ai_amenity_spending = 0.1

	compatibility = {
		impatient = @pos_compat_low
		wrathful = @pos_compat_low
		brave = @pos_compat_low
		patient = @neg_compat_medium
		calm = @neg_compat_low
		temperate = @neg_compat_low
		eccentric = @neg_compat_high
	}
}

arrogant = {
	category = personality
	opposites = {
		humble
	}
	
	monthly_prestige = 1
	
	owned_scheme_secrecy_add = -10
	
	opinion_of_liege = -5
	opinion_of_vassal = -5
	opposite_opinion = -15
	
	ruler_designer_cost = 20

	culture_modifier = {
		parameter = mountain_trait_bonuses
		mountains_advantage = 2
		desert_mountains_advantage = 2
	}

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_arrogant_desc
			}
			desc = trait_arrogant_character_desc
		}
	}

	ai_honor = low_negative_ai_value
	ai_greed = low_positive_ai_value
	ai_rationality = low_negative_ai_value
	ai_boldness = medium_positive_ai_value
	ai_energy = very_low_positive_ai_value
	ai_compassion = low_negative_ai_value
	ai_sociability = low_positive_ai_value
	ai_amenity_target_baseline = 1

	compatibility = {
		arrogant = @pos_compat_low
		greedy = @pos_compat_medium
		ambitious = @pos_compat_medium
		beauty_good_1 = @pos_compat_low
		beauty_good_2 = @pos_compat_low
		beauty_good_3 = @pos_compat_low
		humble = @neg_compat_medium
		content = @neg_compat_medium
		generous = @neg_compat_low
		beauty_bad_1 = @neg_compat_low
		beauty_bad_2 = @neg_compat_low
		beauty_bad_3 = @neg_compat_low
	}
}

humble = {
	category = personality
	opposites = {
		arrogant
	}
	
	monthly_piety = 0.5

	clergy_opinion = 10
	zealot_opinion = 10
	opinion_of_liege = 10
	opinion_of_vassal = 10
	opposite_opinion = -15
	
	ruler_designer_cost = 20

	culture_modifier = {
		parameter = mountain_trait_bonuses
		mountains_attrition_mult = -0.25
		desert_mountains_attrition_mult = -0.25
	}
	
	culture_modifier = {
		parameter = dry_trait_bonuses
		drylands_attrition_mult = -0.2
		desert_attrition_mult = -0.2
	}

	culture_modifier = {
		parameter = build_bonuses_on_religious_traits
		church_holding_build_gold_cost = -0.15
		church_holding_holding_build_gold_cost = -0.15
	}
	
	culture_modifier = {
		parameter = introverted_trait_bonuses
		same_culture_opinion = 10
		monthly_piety_gain_mult = 0.1
	}

	culture_modifier = {
		parameter = honorable_trait_bonuses
		same_culture_opinion = 10
		monthly_prestige_gain_mult = 0.05
	}

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_humble_desc
			}
			desc = trait_humble_character_desc
		}
	}

	ai_honor = low_positive_ai_value
	ai_greed = high_negative_ai_value
	ai_energy = very_low_negative_ai_value
	ai_compassion = low_positive_ai_value
	ai_amenity_target_baseline = -0.2

	compatibility = {
		humble = @pos_compat_high
		content = @pos_compat_low
		generous = @pos_compat_low
		compassionate = @pos_compat_low
		just = @pos_compat_low
		arrogant = @neg_compat_high
		greedy = @neg_compat_medium
		ambitious = @neg_compat_medium
	}
}

deceitful = {
	category = personality
	opposites = {
		honest
	}
	diplomacy = -2
	intrigue = 4
	
	culture_modifier = {
		parameter = forest_trait_bonuses
		forest_advantage = 2
		taiga_advantage = 2
	}
	
	culture_modifier = {
		parameter = jungle_trait_bonuses
		jungle_advantage = 2
	}

	culture_modifier = {
		parameter = palace_politics_trait_bonuses
		monthly_influence = 0.25
	}
	
	opposite_opinion = -10

	flag = can_improve_hostile_schemes_decision
	
	ruler_designer_cost = 30
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_deceitful_desc
			}
			desc = trait_deceitful_character_desc
		}
	}

	ai_honor = high_negative_ai_value
	ai_compassion = very_low_negative_ai_value
	ai_rationality = very_low_positive_ai_value
	ai_boldness = very_low_negative_ai_value

	compatibility = {
		deceitful = @pos_compat_medium
		charming = @pos_compat_medium
		ambitious = @pos_compat_low
		honest = @neg_compat_medium
		just = @neg_compat_medium
		trusting = @neg_compat_medium #"Why are they so gullible?!"
		paranoid = @neg_compat_low #"Why are they so hard to fool?!"
		compassionate = @neg_compat_low
		eccentric = @neg_compat_low #"What even is this person"
	}
}

honest = {
	category = personality
	opposites = {
		deceitful
	}
	diplomacy = 2
	intrigue = -4
	
	courtly_opinion = 5
	opposite_opinion = -10
	same_opinion = 10
	
	culture_modifier = {
		parameter = dry_trait_bonuses
		drylands_attrition_mult = -0.15
		desert_attrition_mult = -0.15
	}
	
	culture_modifier = {
		parameter = trait_county_opinion_modifiers
		county_opinion_add = 5
	}
	
	ruler_designer_cost = 20

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_honest_desc
			}
			desc = trait_honest_character_desc
		}
	}

	ai_honor = high_positive_ai_value
	ai_boldness = very_low_positive_ai_value
	ai_compassion = very_low_positive_ai_value
	ai_sociability = low_positive_ai_value

	compatibility = {
		honest = @pos_compat_high
		just = @pos_compat_medium
		trusting = @pos_compat_medium
		compassionate = @pos_compat_low
		deceitful = @neg_compat_high
		charming = @neg_compat_medium
		paranoid = @neg_compat_medium
	}
}

craven = {
	category = personality
	opposites = {
		brave
	}
	martial = -2
	prowess = -3
	intrigue = 2
	
	attraction_opinion = -10
	glory_hound_opinion = -15
	courtly_opinion = -5
	same_opinion = 20
	
	owned_scheme_secrecy_add = 10
	enemy_hostile_scheme_phase_duration_add = minor_scheme_phase_duration_malus_value
	character_travel_safety_mult = 0.25
	
	culture_modifier = {
		parameter = craven_and_content_traits_looked_down_upon
		same_culture_opinion = -15
	}

	culture_modifier = {
		parameter = craven_trait_costs_prestige
		monthly_prestige = -0.5
	}
	
	ruler_designer_cost = -10
	
	flag = lower_chance_of_dying_in_combat

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_craven_desc
			}
			desc = trait_craven_character_desc
		}
	}

	ai_energy = low_negative_ai_value
	ai_boldness = dominant_negative_ai_value
	ai_rationality = very_low_positive_ai_value
	ai_sociability = low_negative_ai_value

	compatibility = {
		craven = @pos_compat_low
		patient = @pos_compat_low
		calm = @pos_compat_low
		content = @pos_compat_low
		brave = @neg_compat_medium
		wrathful = @neg_compat_high
		sadistic = @neg_compat_high
		callous = @neg_compat_medium
		impatient = @neg_compat_low
		ambitious = @neg_compat_low
		deceitful = @neg_compat_low
	}
}

brave = {
	category = personality
	opposites = {
		craven
	}
	martial = 2
	prowess = 3
	
	attraction_opinion = 10
	glory_hound_opinion = 10
	opposite_opinion = -10
	same_opinion = 10
	
	culture_modifier = {
		parameter = trait_county_opinion_modifiers
		county_opinion_add = 10
	}
	
	culture_modifier = {
		parameter = mountain_trait_bonuses
		mountains_max_combat_roll = 3
		desert_mountains_max_combat_roll = 3
	}
	
	culture_modifier = {
		parameter = winter_trait_bonuses
		winter_movement_speed = 0.1
	}
	
	culture_modifier = {
		parameter = hill_trait_bonuses
		hills_advantage = 4
		hills_attrition_mult = -0.25
	}
	
	culture_modifier = {
		parameter = honorable_trait_bonuses
		same_culture_opinion = 10
		monthly_prestige_gain_mult = 0.05
	}

	ruler_designer_cost = 40
	
	flag = higher_chance_of_dying_in_battle
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_brave_desc
			}
			desc = trait_brave_character_desc
		}
	}

	ai_energy = low_positive_ai_value
	ai_boldness = dominant_positive_ai_value
	ai_rationality = low_negative_ai_value
	ai_sociability = low_positive_ai_value
	ai_amenity_target_baseline = 0.1

	compatibility = {
		brave = @pos_compat_high
		ambitious = @pos_compat_medium
		rowdy = @pos_compat_medium
		gallant = @pos_compat_low
		lifestyle_blademaster = @pos_compat_low
		strategist = @pos_compat_low
		overseer = @pos_compat_low
		gallant = @pos_compat_low
		craven = @neg_compat_high
		lazy = @neg_compat_medium
		calm = @neg_compat_low
		content = @neg_compat_low
	}
}

shy = {
	category = personality
	opposites = {
		gregarious
	}
	diplomacy = -2
	learning = 1
	enemy_hostile_scheme_phase_duration_add = medium_scheme_phase_duration_malus_value
	personal_scheme_phase_duration_add = medium_scheme_phase_duration_malus_value
	learn_language_scheme_phase_duration_add = medium_scheme_phase_duration_bonus_value
	character_travel_safety_mult = 0.25
	epidemic_resistance = 5
	
	attraction_opinion = -5
	same_opinion = 10
	parochial_opinion = 10

	flag = trait_unlocks_t4_withdraw_from_view
	
	culture_modifier = {
		parameter = introverted_trait_bonuses
		same_culture_opinion = 10
		monthly_piety_gain_mult = 0.1
	}

	culture_modifier = {
		parameter = palace_politics_trait_maluses
		monthly_influence = -0.25
	}
	
	ruler_designer_cost = -10

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_shy_desc
			}
			desc = trait_shy_character_desc
		}
	}

	ai_boldness = low_negative_ai_value
	ai_zeal = very_low_negative_ai_value
	ai_vengefulness = very_low_negative_ai_value
	ai_sociability = dominant_negative_ai_value
	ai_amenity_target_baseline = -0.1

	compatibility = {
		shy = @pos_compat_medium
		content = @pos_compat_low
		calm = @pos_compat_low
		craven = @pos_compat_low
		chaste = @pos_compat_low
		celibate = @pos_compat_low
		eccentric = @pos_compat_low
		gregarious = @neg_compat_high
		curious = @neg_compat_medium
		wrathful = @neg_compat_medium
		ambitious = @neg_compat_low
		lustful = @neg_compat_low
	}
}

gregarious = {
	category = personality
	opposites = {
		shy
	}
	diplomacy = 2
	personal_scheme_phase_duration_add = minor_scheme_phase_duration_bonus_value
	
	attraction_opinion = 5
	same_opinion = 10
	courtly_opinion = 5

	monthly_influence = 0.1
	
	culture_modifier = {
		parameter = trait_county_opinion_modifiers
		county_opinion_add = 5
	}
	
	culture_modifier = {
		parameter = gregarious_trait_gives_bonuses
		monthly_diplomacy_lifestyle_xp_gain_mult = 0.1
	}
	
	ruler_designer_cost = 30

	culture_modifier = {
		parameter = life_is_a_joke_trait_same_culture_opinion
		same_culture_opinion = 5
	}


	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_gregarious_desc
			}
			desc = trait_gregarious_character_desc
		}
	}

	ai_boldness = low_positive_ai_value
	ai_compassion = medium_positive_ai_value
	ai_sociability = dominant_positive_ai_value
	ai_amenity_target_baseline = 0.5

	compatibility = {
		gregarious = @pos_compat_high
		curious = @pos_compat_medium
		charming = @pos_compat_high
		compassionate = @pos_compat_medium
		honest = @pos_compat_medium
		lustful = @pos_compat_medium
		lifestyle_reveler = @pos_compat_medium
		diplomat = @pos_compat_medium
		family_first = @pos_compat_medium
		august = @pos_compat_medium
		gallant = @pos_compat_medium
		eccentric = @pos_compat_medium
		trusting = @pos_compat_low
		shy = @neg_compat_medium
		callous = @neg_compat_medium
		sadistic = @neg_compat_medium
		chaste = @neg_compat_low
		celibate = @neg_compat_low
		craven = @neg_compat_low
	}
}

ambitious = {
	category = personality
	opposites = {
		content
	}
	
	intrigue = 1
	stewardship = 1
	diplomacy = 1
	martial = 1
	learning = 1
	prowess = 1
	
	culture_modifier = {
		parameter = mountain_trait_bonuses
		mountains_advantage = 2
		desert_mountains_advantage = 2
	}
	
	culture_modifier = {
		parameter = dry_trait_bonuses
		drylands_max_combat_roll = 3
		desert_max_combat_roll = 3
	}
	
	culture_modifier = {
		parameter = ambitious_trait_penalty
		same_culture_opinion = -15
	}

	culture_modifier = {
		parameter = palace_politics_trait_bonuses
		monthly_influence = 0.35
	}
	
	opinion_of_liege = -15
	same_opinion = -15
	glory_hound_opinion = 10
	
	stress_gain_mult = 0.25
	
	ai_war_cooldown = -0.25
	ai_war_chance = 1
	ai_amenity_target_baseline = 0.25
	ai_amenity_spending = 0.1
	
	ruler_designer_cost = 40
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_ambitious_desc
			}
			desc = trait_ambitious_character_desc
		}
	}

	ai_honor = low_negative_ai_value
	ai_greed = very_high_positive_ai_value
	ai_energy = very_high_positive_ai_value
	ai_boldness = high_positive_ai_value
	ai_zeal = very_low_positive_ai_value
	ai_sociability = low_positive_ai_value

	compatibility = {
		ambitious = @pos_compat_low
		diligent = @pos_compat_low
		greedy = @pos_compat_low
		brave = @pos_compat_low
		rowdy = @pos_compat_low
		content = @neg_compat_medium
		lazy = @neg_compat_medium
		craven = @neg_compat_medium
		generous = @neg_compat_low
		trusting = @neg_compat_low
	}
}

content = {
	category = personality
	opposites = {
		ambitious
	}
	intrigue = -1
	learning = 2
	
	opinion_of_liege = 20
	opinion_of_vassal = 10
	same_opinion = 20
	parochial_opinion = 10
	
	stress_loss_mult = 0.1
	
	ai_war_chance = -0.25
	
	ruler_designer_cost = 20

	culture_modifier = {
		parameter = craven_and_content_traits_looked_down_upon
		same_culture_opinion = -15
	}
	
	culture_modifier = {
		parameter = hill_trait_bonuses
		hills_advantage = 2
	}
	
	culture_modifier = {
		parameter = introverted_trait_bonuses
		same_culture_opinion = 10
		monthly_piety_gain_mult = 0.1
	}

	culture_modifier = {
		parameter = life_is_a_joke_trait_same_culture_opinion 
		same_culture_opinion = 5
	}

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_content_desc
			}
			desc = trait_content_character_desc
		}
	}

	ai_honor = very_low_positive_ai_value
	ai_greed = high_negative_ai_value
	ai_energy = medium_negative_ai_value
	ai_boldness = medium_negative_ai_value
	ai_zeal = very_low_negative_ai_value
	ai_vengefulness = very_low_negative_ai_value
	ai_sociability = very_low_negative_ai_value
	ai_amenity_spending = -0.1

	compatibility = {
		content = @pos_compat_medium
		lazy = @pos_compat_low
		calm = @pos_compat_low
		generous = @pos_compat_low
		forgiving = @pos_compat_low
		ambitious = @neg_compat_medium
		diligent = @neg_compat_low
		greedy = @neg_compat_low
		brave = @neg_compat_low
		vengeful = @neg_compat_low
	}
}

arbitrary = {
	category = personality
	opposites = {
		just
	}
	stewardship = -2
	learning = -1
	intrigue = 3
	
	stress_gain_mult = -0.5
	dread_baseline_add = 15

	culture_modifier = {
		parameter = palace_politics_trait_bonuses
		monthly_influence = 0.15
	}
	
	vassal_opinion = -5
	
	flag = can_dismiss_hooks_interaction
	flag = trait_unlocks_t2_arbitrary_arrests
	
	ruler_designer_cost = 30

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_arbitrary_desc
			}
			desc = trait_arbitrary_character_desc
		}
	}

	ai_honor = dominant_negative_ai_value
	ai_rationality = low_negative_ai_value
	ai_zeal = very_low_negative_ai_value
	ai_compassion = very_low_negative_ai_value
	ai_boldness = very_low_positive_ai_value

	compatibility = {
		eccentric = @pos_compat_medium
		arbitrary = @pos_compat_low
		fickle = @pos_compat_low
		just = @neg_compat_medium
		zealous = @neg_compat_low
		stubborn = @neg_compat_low
		honest = @neg_compat_low
	}
}

just = {
	category = personality
	opposites = {
		arbitrary
	}
	stewardship = 2
	learning = 1
	intrigue = -3
	
	parochial_opinion = 15
	minority_opinion = 15
	opposite_opinion = -10
	same_opinion = 10
	flag = initial_legitimacy_boost
	
	culture_modifier = {
		parameter = just_trait_gives_bonuses
		monthly_prestige_gain_mult = 0.05
		diplomacy_per_prestige_level = 1
	}
	
	culture_modifier = {
		parameter = honorable_trait_bonuses
		same_culture_opinion = 10
		monthly_prestige_gain_mult = 0.05
	}

	ruler_designer_cost = 40

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_just_desc
			}
			desc = trait_just_character_desc
		}
	}

	ai_honor = dominant_positive_ai_value
	ai_zeal = very_low_positive_ai_value
	ai_vengefulness = very_low_positive_ai_value
	ai_rationality = low_positive_ai_value
	ai_amenity_target_baseline = 0.05
	ai_amenity_spending = 0.05

	compatibility = {
		just = @pos_compat_high
		zealous = @pos_compat_medium
		honest = @pos_compat_medium
		compassionate = @pos_compat_medium
		gallant = @pos_compat_medium
		trusting = @pos_compat_low
		brave = @pos_compat_low
		arbitrary = @neg_compat_high
		deceitful = @neg_compat_medium
		sadistic = @neg_compat_medium
		callous = @neg_compat_medium
		fickle = @neg_compat_low
		greedy = @neg_compat_low
		eccentric = @neg_compat_low
	}
}

cynical = {
	category = personality
	opposites = {
		zealous
	}
	intrigue = 2
	learning = 2
	
	monthly_piety_gain_mult = -0.2
	faith_conversion_piety_cost_mult = -0.2

	opposite_opinion = -10
	same_opinion = 10
	zealot_opinion = -15

	culture_modifier = {
		parameter = build_bonuses_on_religious_traits
		church_holding_build_gold_cost = 0.2
		church_holding_holding_build_gold_cost = 0.2
	}

	culture_modifier = {
		parameter = life_is_a_joke_trait_same_culture_opinion
		same_culture_opinion = 5
	}
	
	ruler_designer_cost = 30

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_cynical_desc
			}
			desc = trait_cynical_character_desc
		}
	}

	ai_rationality = medium_positive_ai_value
	ai_energy = low_negative_ai_value
	ai_zeal = dominant_negative_ai_value
	ai_compassion = very_low_negative_ai_value

	compatibility = {
		cynical = @pos_compat_high
		whole_of_body = @pos_compat_medium
		scholar = @pos_compat_medium
		theologian = @pos_compat_medium
		honest = @pos_compat_low
		intellect_good_1 = @pos_compat_low
		intellect_good_2 = @pos_compat_low
		intellect_good_3 = @pos_compat_low
		shrewd = @pos_compat_low
		zealous = @neg_compat_high
		intellect_bad_1 = @neg_compat_medium
		intellect_bad_2 = @neg_compat_medium
		intellect_bad_3 = @neg_compat_medium
		trusting = @neg_compat_low
	}
}

zealous = {
	category = personality
	opposites = {
		cynical
	}
	martial = 2
	
	monthly_piety_gain_mult = 0.2
	faith_conversion_piety_cost_mult = 0.2
	
	opposite_opinion = -10
	same_opinion_if_same_faith = 15
	opinion_of_different_faith = -35
	zealot_opinion = 15
	
	culture_modifier = {
		parameter = dry_trait_bonuses
		drylands_advantage = 2
		desert_advantage = 2
	}

	culture_modifier = {
		parameter = build_bonuses_on_religious_traits
		church_holding_build_gold_cost = -0.25
		church_holding_holding_build_gold_cost = -0.25
	}
	
	ruler_designer_cost = 30

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_zealous_desc
			}
			desc = trait_zealous_character_desc
		}
	}

	ai_rationality = low_negative_ai_value
	ai_energy = low_positive_ai_value
	ai_zeal = dominant_positive_ai_value

	compatibility = {
		zealous = @pos_compat_high
		just = @pos_compat_medium
		devoted = @pos_compat_medium
		ambitious = @pos_compat_low
		trusting = @pos_compat_low
		whole_of_body = @pos_compat_low
		scholar = @pos_compat_low
		theologian = @pos_compat_low
		cynical = @neg_compat_high
		craven = @neg_compat_medium
		content = @neg_compat_low
		paranoid = @neg_compat_low
		drunkard = @neg_compat_low
		lifestyle_herbalist = @neg_compat_low
		lifestyle_mystic = @neg_compat_low
		eccentric = @neg_compat_low
	}
}

paranoid = {
	category = personality
	opposites = {
		trusting
	}
	diplomacy = -1
	intrigue = 3
	
	stress_gain_mult = 1
	dread_gain_mult = 0.25
	
	enemy_scheme_secrecy_add = -10
	enemy_personal_scheme_success_chance_add = -25
	
	character_travel_speed = -10
	character_travel_safety = 10

	flag = trait_unlocks_t2_countermeasures
	
	culture_modifier = {
		parameter = forest_trait_bonuses
		forest_min_combat_roll = 2
		taiga_min_combat_roll = 2
	}
	
	culture_modifier = {
		parameter = jungle_trait_bonuses
		jungle_min_combat_roll = 2
	}
	
	culture_modifier = {
		parameter = hill_trait_bonuses
		hills_min_combat_roll = 2
	}

	culture_modifier = {
		parameter = palace_politics_trait_bonuses
		monthly_influence = 0.15
	}
	
	opinion_of_vassal = -10
	
	ruler_designer_cost = -10
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_paranoid_desc
			}
			desc = trait_paranoid_character_desc
		}
	}

	ai_honor = low_negative_ai_value
	ai_boldness = low_negative_ai_value
	ai_rationality = low_negative_ai_value
	ai_vengefulness = low_positive_ai_value
	ai_compassion = very_low_negative_ai_value
	ai_sociability = medium_negative_ai_value
	ai_amenity_target_baseline = -0.1

	compatibility = {
		paranoid = @pos_compat_low
		cynical = @pos_compat_low
		honest = @pos_compat_low
		trusting = @neg_compat_high
		forgiving = @neg_compat_medium
		deceitful = @neg_compat_high
		sadistic = @neg_compat_high
		callous = @neg_compat_high
		vengeful = @neg_compat_high
		gregarious = @neg_compat_medium
		lustful = @neg_compat_medium
		greedy = @neg_compat_medium
		ambitious = @neg_compat_medium
		eccentric = @neg_compat_medium
	}
}

trusting = {
	category = personality
	opposites = {
		paranoid
	}
	diplomacy = 2
	intrigue = -2
	
	enemy_hostile_scheme_success_chance_add = 15
	
	opinion_of_liege = 15
	opinion_of_vassal = 15
	character_travel_safety = -10
	flag = can_offer_strong_hook_to_agents

	culture_modifier = {
		parameter = palace_politics_trait_maluses
		monthly_influence = -0.25
	}
	
	ruler_designer_cost = 10
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_trusting_desc
			}
			desc = trait_trusting_character_desc
		}
	}

	ai_honor = medium_positive_ai_value
	ai_rationality = low_negative_ai_value
	ai_vengefulness = low_negative_ai_value
	ai_compassion = low_positive_ai_value
	ai_sociability = medium_positive_ai_value

	compatibility = {
		trusting = @pos_compat_medium
		honest = @pos_compat_medium
		compassionate = @pos_compat_low
		paranoid = @neg_compat_medium
		deceitful = @neg_compat_medium
		callous = @neg_compat_low
		sadistic = @neg_compat_low
		vengeful = @neg_compat_low
	}
}

compassionate = {
	category = personality
	opposites = {
		callous
		sadistic
	}
	diplomacy = 2
	intrigue = -2
	minority_opinion = 15
	courtly_opinion = 10
	
	dread_decay_mult = 1
	dread_baseline_add = -15
	
	opposite_opinion = -15
	attraction_opinion = 5
	
	culture_modifier = {
		parameter = trait_county_opinion_modifiers
		county_opinion_add = 5
	}
	
	culture_modifier = {
		parameter = stress_loss_bonus_from_harmonious_traits
		stress_loss_mult = 0.15
	}

	ruler_designer_cost = 10
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_compassionate_desc
			}
			desc = trait_compassionate_character_desc
		}
	}

	ai_honor = medium_positive_ai_value
	ai_greed = low_negative_ai_value
	ai_compassion = dominant_positive_ai_value
	ai_sociability = medium_positive_ai_value
	ai_amenity_target_baseline = 0.1
	ai_amenity_spending = 0.05

	compatibility = {
		compassionate = @pos_compat_high
		generous = @pos_compat_high
		honest = @pos_compat_medium
		just = @pos_compat_medium
		forgiving = @pos_compat_medium
		trusting = @pos_compat_low
		gregarious = @pos_compat_low
		curious = @pos_compat_medium
		calm = @pos_compat_low
		patient = @pos_compat_low
		eccentric = @pos_compat_low
		callous = @neg_compat_high
		sadistic = @neg_compat_high
		deceitful = @neg_compat_medium
		arbitrary = @neg_compat_medium
		vengeful = @neg_compat_medium
		greedy = @neg_compat_low
		paranoid = @neg_compat_low
		wrathful = @neg_compat_low
		torturer = @neg_compat_low
	}
}

callous = {
	category = personality
	opposites = {
		compassionate
		sadistic
	}
	diplomacy = -2
	intrigue = 2
	
	courtly_opinion = -10
	
	tyranny_gain_mult = -0.2
	dread_gain_mult = 0.25
	dread_decay_mult = -0.25
	
	culture_modifier = {
		parameter = winter_trait_bonuses
		winter_movement_speed = 0.1
	}
	
	attraction_opinion = -5
	close_relative_opinion = -5
	
	ruler_designer_cost = 40

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_callous_desc
			}
			desc = trait_callous_character_desc
		}
	}

	ai_honor = medium_negative_ai_value
	ai_rationality = very_low_positive_ai_value
	ai_compassion = dominant_negative_ai_value
	ai_sociability = very_low_negative_ai_value

	compatibility = {
		callous = @pos_compat_low
		arbitrary = @pos_compat_low
		compassionate = @neg_compat_high
		curious = @neg_compat_low
		generous = @neg_compat_high
		just = @neg_compat_medium
		forgiving = @neg_compat_medium
		trusting = @neg_compat_low
	}
}

sadistic = {
	category = personality
	opposites = {
		compassionate
		callous
	}
	intrigue = 2
	prowess = 4
	
	dread_baseline_add = 35
	
	general_opinion = -10
	
	courtly_opinion = -10
	
	ruler_designer_cost = 40
	
	flag = can_murder_own_children
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_sadistic_desc
			}
			desc = trait_sadistic_character_desc
		}
	}

	ai_honor = very_high_negative_ai_value
	ai_compassion = dominant_negative_ai_value
	
	compatibility = {
		sadistic = @pos_compat_medium
		torturer = @pos_compat_low
		callous = @pos_compat_low
		arbitrary = @pos_compat_low
		compassionate = @neg_compat_high
		generous = @neg_compat_high
		just = @neg_compat_medium
		forgiving = @neg_compat_medium
		trusting = @neg_compat_low
		curious = @neg_compat_low
	}
}

stubborn = {
	category = personality
	opposites = {
		fickle
		eccentric
	}
	stewardship = 3
	negate_health_penalty_add = 0.25
	
	culture_modifier = {
		parameter = winter_trait_bonuses
		winter_movement_speed = 0.1
	}
	
	culture_modifier = {
		parameter = mountain_trait_bonuses
		mountains_min_combat_roll = 2
		desert_mountains_min_combat_roll = 2
	}
	
	culture_modifier = {
		parameter = hill_trait_bonuses
		hills_min_combat_roll = 5
	}
	
	liege_opinion = -5
	minority_opinion = -5
	parochial_opinion = -10
	courtly_opinion = -10
	
	ruler_designer_cost = 30
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_stubborn_desc
			}
			desc = trait_stubborn_character_desc
		}
	}

	ai_honor = medium_positive_ai_value
	ai_rationality = very_low_negative_ai_value
	ai_vengefulness = medium_positive_ai_value
	ai_amenity_target_baseline = 0.1
	ai_amenity_spending = 0.05

	compatibility = {
		patient = @pos_compat_low
		forgiving = @neg_compat_low
		fickle = @neg_compat_low
	}
}

fickle = {
	category = personality
	opposites = {
		stubborn
		eccentric
	}
	intrigue = 1
	diplomacy = 2
	stewardship = -2
	
	culture_modifier = {
		parameter = forest_trait_bonuses
		forest_max_combat_roll = 2
		taiga_max_combat_roll = 2
	}
	
	culture_modifier = {
		parameter = jungle_trait_bonuses
		jungle_max_combat_roll = 2
	}

	culture_modifier = {
		parameter = life_is_a_joke_trait_same_culture_opinion 
		same_culture_opinion = 5
	}
	
	enemy_hostile_scheme_phase_duration_add = medium_scheme_phase_duration_malus_value
	
	ruler_designer_cost = 25
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_fickle_desc
			}
			desc = trait_fickle_character_desc
		}
	}

	ai_honor = low_negative_ai_value
	ai_rationality = low_negative_ai_value
	ai_boldness = low_positive_ai_value
	ai_vengefulness = low_negative_ai_value

	compatibility = {
		fickle = @pos_compat_low
		forgiving = @pos_compat_low
		stubborn = @neg_compat_medium
	}
}

eccentric = {
	category = personality
	opposites = {
		fickle
		stubborn
	}
	learning = 2
	diplomacy = -2

	stress_gain_mult = 0.5
	stress_loss_mult = 0.5
	monthly_lifestyle_xp_gain_mult = 0.2
	same_opinion = 10
	flag = trait_unlocks_t2_withdraw_from_view

	culture_modifier = {
		parameter = life_is_a_joke_trait_same_culture_opinion 
		same_culture_opinion = 5
	}
	
	ruler_designer_cost = 15
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_eccentric_desc
			}
			desc = trait_eccentric_character_desc
		}
	}

	ai_rationality = dominant_negative_ai_value
	ai_honor = low_negative_ai_value
	ai_boldness = very_high_positive_ai_value
	ai_sociability = low_negative_ai_value

	compatibility = {
		patient = @pos_compat_high
		arbitrary = @pos_compat_low
		shy = @pos_compat_low
		gregarious = @pos_compat_low
		compassionate = @pos_compat_low
		stubborn = @neg_compat_medium
		fickle = @neg_compat_medium
		zealous = @neg_compat_medium
		just = @neg_compat_medium
		wrathful = @neg_compat_medium
		impatient = @neg_compat_medium
		deceitful = @neg_compat_medium
		paranoid = @neg_compat_medium
	}
	random_creation_weight = 0.05
}

vengeful = {
	category = personality
	opposites = {
		forgiving
	}
	diplomacy = -2
	intrigue = 2
	prowess = 2
	dread_gain_mult = 0.15
	
	culture_modifier = {
		parameter = dry_trait_bonuses
		drylands_advantage = 3
		desert_advantage = 3
	}
	
	culture_modifier = {
		parameter = hill_trait_bonuses
		hills_max_combat_roll = 5
	}
	
	culture_modifier = {
		parameter = vengeful_positive_forgiving_negative
		same_culture_opinion = 15
		hostile_scheme_phase_duration_add = medium_scheme_phase_duration_bonus_value
	}
	
	ruler_designer_cost = 30
	
	flag = extra_scheme_success_chance_vs_rivals
	flag = can_fabricate_hooks_on_rivals
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_vengeful_desc
			}
			desc = trait_vengeful_character_desc
		}
	}

	ai_honor = very_low_negative_ai_value
	ai_rationality = very_low_negative_ai_value
	ai_energy = very_low_positive_ai_value
	ai_vengefulness = dominant_positive_ai_value
	ai_compassion = low_negative_ai_value

	compatibility = {
		forgiving = @neg_compat_high
		content = @neg_compat_medium
		compassionate = @neg_compat_low
	}
}

forgiving = {
	category = personality
	opposites = {
		vengeful
	}
	diplomacy = 2
	intrigue = -2
	learning = 1
	
	prisoner_opinion = 15
	opposite_opinion = -10
	same_opinion = 10
	minority_opinion = 15

	flag = can_abandon_hooks_interaction
	
	ruler_designer_cost = 25

	culture_modifier = {
		parameter = trait_county_opinion_modifiers
		county_opinion_add = 5
	}
	
	culture_modifier = {
		parameter = vengeful_positive_forgiving_negative
		same_culture_opinion = -10
	}

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_forgiving_desc
			}
			desc = trait_forgiving_character_desc
		}
	}

	ai_honor = low_positive_ai_value
	ai_rationality = very_low_positive_ai_value
	ai_energy = very_low_negative_ai_value
	ai_vengefulness = dominant_negative_ai_value
	ai_compassion = medium_positive_ai_value

	compatibility = {
		forgiving = @pos_compat_high
		compassionate = @pos_compat_medium
		honest = @pos_compat_medium
		generous = @pos_compat_low
		just = @pos_compat_low
		trusting = @pos_compat_low
		gregarious = @pos_compat_low
		calm = @pos_compat_low
		patient = @pos_compat_low
		vengeful = @neg_compat_high
		callous = @neg_compat_medium
		sadistic = @neg_compat_medium
		deceitful = @neg_compat_medium
		arbitrary = @neg_compat_low
		paranoid = @neg_compat_low
		wrathful = @neg_compat_low
	}
}

############### Child Personality ##############
rowdy = {
	
	category = childhood
	minimum_age = 3
	maximum_age = 15
	martial = 1
	intrigue = 1
	
	ruler_designer_cost = 5

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_rowdy_desc
			}
			desc = trait_rowdy_character_desc
		}
	}

	ai_energy = 25
	ai_boldness = 25
	ai_rationality = -15
	ai_compassion = -15
	ai_vengefulness = 15
	ai_honor = -15
	ai_sociability = 15

	compatibility = {
		rowdy = @pos_compat_high
		brave = @pos_compat_high
		ambitious = @pos_compat_high
		bossy = @pos_compat_low
		curious = @pos_compat_low
		pensive = @neg_compat_low
		craven = @neg_compat_low
		calm = @neg_compat_low
	}
}

charming = {
	
	category = childhood
	minimum_age = 3
	maximum_age = 15
	intrigue = 1
	diplomacy = 1
	learn_language_scheme_phase_duration_add = medium_scheme_phase_duration_bonus_value
	
	ruler_designer_cost = 5

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_charming_desc
			}
			desc = trait_charming_character_desc
		}
	}

	ai_vengefulness = 15
	ai_greed = 25
	ai_honor = -15
	ai_rationality = 15
	ai_compassion = 15
	ai_sociability = 25
	ai_amenity_target_baseline = 0.1
	ai_amenity_spending = 0.05

	compatibility = {
		charming = @pos_compat_low
		gregarious = @pos_compat_medium
		deceitful = @pos_compat_low
		ambitious = @pos_compat_low
		bossy = @pos_compat_low
		curious = @neg_compat_medium
		honest = @neg_compat_medium
		content = @neg_compat_medium
		just = @neg_compat_medium
		shy = @neg_compat_high
	}
}

curious = {
	
	category = childhood
	minimum_age = 3
	maximum_age = 15
	diplomacy = 1
	learning = 1
	learn_language_scheme_phase_duration_add = major_scheme_phase_duration_bonus_value
	
	ruler_designer_cost = 5

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_curious_desc
			}
			desc = trait_curious_character_desc
		}
	}

	ai_compassion = 25
	ai_honor = 15
	ai_vengefulness = -15
	ai_boldness = 25
	ai_energy = 15
	ai_sociability = 15

	compatibility = {
		curious = @pos_compat_high
		gregarious = @pos_compat_medium
		compassionate = @pos_compat_medium
		rowdy = @pos_compat_medium
		charming = @pos_compat_low
		shy = @neg_compat_high
		callous = @neg_compat_medium
		sadistic = @neg_compat_medium
		deceitful = @neg_compat_low
	}
}

pensive = {
	
	category = childhood
	minimum_age = 3
	maximum_age = 15
	learning = 1
	stewardship = 1
	learn_language_scheme_phase_duration_add = major_scheme_phase_duration_bonus_value
	
	ruler_designer_cost = 5

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_pensive_desc
			}
			desc = trait_pensive_character_desc
		}
	}

	ai_rationality = 25
	ai_greed = -15
	ai_energy = 15
	ai_boldness = -15
	ai_honor = 15
	ai_sociability = -25

	compatibility = {
		pensive = @pos_compat_high
		whole_of_body = @pos_compat_high
		scholar = @pos_compat_high
		theologian = @pos_compat_high
		diligent = @pos_compat_low
		intellect_good_1 = @pos_compat_low
		intellect_good_2 = @pos_compat_low
		intellect_good_3 = @pos_compat_low
		shrewd = @pos_compat_low
		rowdy = @neg_compat_medium
		bossy = @neg_compat_low
		lazy = @neg_compat_low
	}
}

bossy = {
	
	category = childhood
	minimum_age = 3
	maximum_age = 15
	stewardship = 1
	martial = 1
	
	ruler_designer_cost = 5

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_bossy_desc
			}
			desc = trait_bossy_character_desc
		}
	}

	ai_boldness = 25
	ai_greed = 25
	ai_vengefulness = 15
	ai_honor = 15
	ai_rationality = 15

	compatibility = {
		bossy = @pos_compat_low
		ambitious = @pos_compat_low
		greedy = @pos_compat_low
		rowdy = @pos_compat_low
		content = @neg_compat_low
		pensive = @neg_compat_low
	}
}

############### Stress Traits ##############

drunkard = { # Substance Abuse (Alcohol)
	category = fame
	stewardship = -2
	prowess = -2
	health = -0.15
	stress_loss_mult = 0.2

	same_opinion = 10
	character_travel_safety = -10
	
	ruler_designer_cost = -10

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_drunkard_desc
			}
			desc = trait_drunkard_character_desc
		}
	}

	ai_rationality = -10
	ai_energy = -15

	compatibility = {
		temperate = @neg_compat_low
	}
}

hashishiyah = { # Substance Abuse (Hashish)
	category = fame
	stewardship = -2
	learning = -2
	stress_loss_mult = 0.2

	same_opinion = 10
	
	ruler_designer_cost = 5

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_hashishiyah_desc
			}
			desc = trait_hashishiyah_character_desc
		}
	}

	ai_energy = -15
	ai_vengefulness = -10

	compatibility = {
		temperate = @neg_compat_low
	}
}

rakish = { # Brothel-frequenter.
	category = fame
	intrigue = 1
	diplomacy = -1
	stress_loss_mult = 0.2

	same_opinion = 5
	attraction_opinion = -5
	
	ruler_designer_cost = 0

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_rakish_desc
			}
			desc = trait_rakish_character_desc
		}
	}

	ai_honor = -10
	ai_greed = 10
	ai_energy = -10
	ai_zeal = -10
	ai_sociability = low_positive_ai_value

	compatibility = {
		chaste = @neg_compat_low
	}	
}

reclusive = { # Hides away from relationships and responsibilities.
	category = fame
	diplomacy = -2
	stewardship = -1
	stress_loss_mult = 0.2
	epidemic_resistance = 10
	
	ruler_designer_cost = -5

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_reclusive_desc
			}
			desc = trait_reclusive_character_desc
		}
	}

	flag = trait_unlocks_t3_withdraw_from_view

	ai_energy = -10
	ai_boldness = -10
	ai_sociability = medium_negative_ai_value

	compatibility = {
		gregarious = @neg_compat_low
	}	
}

irritable = { # Prone to outbursts and tantrums.
	category = fame
	diplomacy = -2
	martial = -1
	prowess = 2
	dread_gain_mult = 0.1
	stress_loss_mult = 0.2

	ai_war_chance = 0.25
	ai_war_cooldown = -0.25

	flag = can_duel_anyone_interaction
	
	ruler_designer_cost = 0

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_irritable_desc
			}
			desc = trait_irritable_character_desc
		}
	}

	attraction_opinion = -5

	ai_rationality = -20
	ai_energy = 10
	ai_boldness = 10
	ai_vengefulness = 10
	ai_compassion = -10

	compatibility = {
		compassionate = @neg_compat_low
		gregarious = @neg_compat_low
		calm = @neg_compat_low
	}
}

flagellant = { # Habitually self-harms; whipping is the 'primary' one but cutting, burning, etc. could also be options.
	category = fame
	prowess = -2
	health = -0.15
	stress_loss_mult = 0.2
	
	ruler_designer_cost = -10

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_flagellant_desc
			}
			desc = trait_flagellant_character_desc
		}
	}

	ai_honor = 10
	ai_zeal = 25
	ai_boldness = 5

	compatibility = {
		cynical = @neg_compat_low
	}		
}

profligate = { # Subject to compulsive spending. Maybe also gambling?
	category = fame
	opposites = {
		improvident
	}

	monthly_prestige = 0.5
	monthly_income_mult = -0.10
	stress_loss_mult = 0.2
	courtly_opinion = 10
	
	ruler_designer_cost = 10

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_profligate_desc
			}
			desc = trait_profligate_character_desc
		}
	}

	ai_greed = 10
	ai_compassion = -10
	ai_amenity_target_baseline = 0.15
	ai_amenity_spending = 0.2

	compatibility = {
		generous = @neg_compat_low
	}
}

improvident = { # Habitually gives money to charity.
	category = fame
	opposites = {
		profligate
	}

	monthly_income_mult = -0.15
	monthly_piety = 0.5
	diplomacy = 1
	stress_loss_mult = 0.2
	zealot_opinion = 10
	
	ruler_designer_cost = -5

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_improvident_desc
			}
			desc = trait_improvident_character_desc
		}
	}

	ai_greed = -10
	ai_compassion = 10
	ai_amenity_spending = 0.15

	compatibility = {
		greedy = @neg_compat_low
	}
}

contrite = { # Compulsively reveals own/other's Secrets. If no known Secrets, may reveal 'minor secrets', e.g., things which aren't true Secrets but may harm other's Opinions of the character.
	category = fame
	intrigue = -2
	stress_loss_mult = 0.2
	
	ruler_designer_cost = -5

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_contrite_desc
			}
			desc = trait_contrite_character_desc
		}
	}

	ai_honor = 10
	ai_zeal = 10
	ai_vengefulness = -10
	ai_compassion = 10

	compatibility = {
		gregarious = @neg_compat_low
		deceitful = @neg_compat_low
	}	
}

comfort_eater = { # Eats food to relieve stress.
	category = fame
	opposites = {
		inappetetic
	}

	stewardship = -1
	stress_loss_mult = 0.2
	
	ruler_designer_cost = -5

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_comfort_eater_desc
			}
			desc = trait_comfort_eater_character_desc
		}
	}

	ai_greed = 5
	ai_energy = -5

	compatibility = {
		temperate = @neg_compat_low
	}
}

inappetetic = { # Avoids eating food when stressed
	category = fame
	opposites = {
		comfort_eater
	}

	diplomacy = -1
	prowess = -3
	stress_loss_mult = 0.2
	
	ruler_designer_cost = -5

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_inappetetic_desc
			}
			desc = trait_inappetetic_character_desc
		}
	}

	ai_greed = -5
	ai_energy = -10

	compatibility = {
		gluttonous = @neg_compat_low
	}
}

journaller = { # Writes down thoughts to relieve stress (Healthy)
	category = fame
	learning = 1
	stress_loss_mult = 0.2
	
	ruler_designer_cost = 15

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_journaller_desc
			}
			desc = trait_journaller_character_desc
		}
	}

	ai_rationality = 10
}

confider = { # Has a close friend to relieve stress (Healthy)
	diplomacy = 1
	stress_loss_mult = 0.2
	
	ruler_designer_cost = 15

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_confider_desc
			}
			desc = trait_confider_character_desc
		}
	}

	ai_compassion = 10
	ai_sociability = low_positive_ai_value
}

athletic = { # Exercises to relieve stress (Healthy)
	category = fame
	prowess = 1
	health = 0.25
	stress_loss_mult = 0.2
	
	culture_modifier = {
		parameter = hard_working_traits_more_valued
		farmlands_development_growth_factor = 0.2
		floodplains_development_growth_factor = 0.2
		county_fertility_growth_mult = tiny_county_fertility_growth_gain
	}
	
	ruler_designer_cost = 40
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_athletic_desc
			}
			desc = trait_athletic_character_desc
		}
	}

	ai_energy = 25
	ai_boldness = 5
}

############### Health ##############
pregnant = {
	category = health
	prowess = -2

	flag = no_message
	
	shown_in_ruler_designer = no

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_pregnant_desc
			}
			desc = trait_pregnant_character_desc
		}
	}

	ai_energy = -15
}

depressed_1 = {
	category = health
	group_equivalence = depressed
	level = 1
	
	diplomacy = -1
	stewardship = -1
	martial = -1
	intrigue = -1
	health = -0.5
	
	fertility = -0.1
	
	shown_in_ruler_designer = no

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_depressed_1_desc
			}
			desc = trait_depressed_1_character_desc
		}
	}

	ai_energy = -15
	ai_sociability = medium_negative_ai_value
}

depressed_genetic = {
	birth = 0.5
	random_creation = 0.5
	genetic = yes
	category = health
	group_equivalence = depressed
	level = 2
	
	diplomacy = -1
	stewardship = -1
	martial = -1
	intrigue = -1
	health = -0.5
	
	fertility = -0.1

	shown_in_encyclopedia = no
	
	ruler_designer_cost = -20

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_depressed_genetic_desc
			}
			desc = trait_depressed_genetic_character_desc
		}
	}

	ai_energy = -15
	#ai_sociability = medium_negative_ai_value
}

lunatic_1 = { # Highly event driven, Schizophrenia

	group_equivalence = lunatic
	level = 1
	
	vassal_opinion = -10
	attraction_opinion = -10
	same_opinion = 10
	enemy_hostile_scheme_phase_duration_add = minor_scheme_phase_duration_malus_value
	health = -0.25
	category = health
	
	shown_in_ruler_designer = no

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_lunatic_1_desc
			}
			desc = trait_lunatic_1_character_desc
		}
	}

	ai_honor = -10
	ai_rationality = -200
	ai_boldness = 50
}

lunatic_genetic = { # Highly event driven, Schizophrenia
	birth = 0.5
	random_creation = 0.5
	genetic = yes
	category = health

	group_equivalence = lunatic
	level = 2
	health = -0.25
	
	vassal_opinion = -10
	attraction_opinion = -10
	enemy_hostile_scheme_phase_duration_add = minor_scheme_phase_duration_malus_value
	same_opinion = 10

	shown_in_encyclopedia = no
	
	ruler_designer_cost = -15

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_lunatic_genetic_desc
			}
			desc = trait_lunatic_genetic_character_desc
		}
	}

	ai_honor = -10
	ai_rationality = -200
	ai_boldness = 50
}

possessed_1 = { # Highly event driven, Temporal lobe epilepsy

	group_equivalence = possessed
	level = 1

	category = health

	monthly_learning_lifestyle_xp_gain_mult = 0.1
	health = -0.5

	attraction_opinion = -10
	same_opinion = 15
	
	shown_in_ruler_designer = no

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_possessed_1_desc
			}
			desc = trait_possessed_1_character_desc
		}
	}

	ai_rationality = -30
	ai_boldness = 25
	ai_vengefulness = 25
}

possessed_genetic = { # Highly event driven, Temporal lobe epilepsy
	birth = 0.5
	random_creation = 0.5
	genetic = yes
	category = health

	group_equivalence = possessed
	level = 2
	
	monthly_learning_lifestyle_xp_gain_mult = 0.1
	health = -0.5

	attraction_opinion = -10
	same_opinion = 15

	shown_in_encyclopedia = no
	
	ruler_designer_cost = -20

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_possessed_genetic_desc
			}
			desc = trait_possessed_genetic_character_desc
		}
	}

	ai_rationality = -30
	ai_boldness = 25
	ai_vengefulness = 25
}

ill = {
	opposites = {
		pneumonic
	}
	
	health = -1
	elderly_health = -1
	prowess_mult = -0.4
	fertility = -0.2

	category = health

	dread_baseline_add = -10
	dread_loss_mult = 1
	
	ruler_designer_cost = 0

	flag = illness
	flag = debilitating_illness
	flag = blocks_getting_non_epidemic_disease
	flag = is_healthy_trigger_flag

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_ill_desc
			}
			desc = trait_ill_character_desc
		}
	}

	ai_energy = -25
}

pneumonic = {
	opposites = {
		ill
	}
	
	diplomacy = -2
	stewardship = -2
	martial = -2
	intrigue = -2
	learning = -2
	health = -3
	elderly_health = -2
	prowess_mult = -0.8
	fertility = -0.5

	category = health

	dread_baseline_add = -10
	dread_loss_mult = 1
	
	ruler_designer_cost = 0

	flag = illness
	flag = debilitating_illness
	flag = blocks_getting_non_epidemic_disease

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_pneumonic_desc
			}
			desc = trait_pneumonic_character_desc
		}
	}

	ai_energy = -50
}

great_pox = { #Syphilis
	inherit_chance = 10
	
	diplomacy = -1
	stewardship = -1
	martial = -1
	intrigue = -1
	learning = -1
	health = -1
	fertility = -0.2

	category = health
	
	dread_baseline_add = -20
	dread_loss_mult = 1

	attraction_opinion = -10
	
	ruler_designer_cost = -10

	flag = illness
	flag = blocks_getting_non_epidemic_disease

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_great_pox_desc
			}
			desc = trait_great_pox_character_desc
		}
	}

	ai_energy = -15
}

early_great_pox = { #Great pox, but looks like lover's pox

	dread_baseline_add = -5	#Mimic's Lover's Pox loss at this stage.

	attraction_opinion = -20
	category = health
	
	shown_in_ruler_designer = no
	shown_in_encyclopedia = no

	flag = illness

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_early_great_pox_desc
			}
			desc = trait_early_great_pox_character_desc
		}
	}
}

lovers_pox = {
	inherit_chance = 10
	
	dread_baseline_add = -5

	attraction_opinion = -20
	category = health
	
	ruler_designer_cost = 0

	flag = illness

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_lovers_pox_desc
			}
			desc = trait_lovers_pox_character_desc
		}
	}
}

leper = {
	health = -1.5
	prowess_mult = -0.8
	fertility = -0.95
	category = health

	dread_baseline_add = -20
	dread_loss_mult = 1

	attraction_opinion = -35
	general_opinion = -10
	
	ruler_designer_cost = -30

	flag = illness
	flag = debilitating_illness
	flag = blocks_getting_non_epidemic_disease

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_leper_desc
			}
			desc = trait_leper_character_desc
		}
	}

	ai_energy = -15
}

# 'Wounded'
wounded_1 = {
	martial = -1
	intrigue = -1
	health = -1
	prowess = -2
	category = health

	dread_baseline_add = -10
	dread_loss_mult = 1

	disables_combat_leadership = yes
	
	shown_in_ruler_designer = no

	flag = no_message

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_wounded_1_desc
			}
			desc = trait_wounded_1_character_desc
		}
	}

	ai_energy = -20

	group = wounded
	level = 1
}

# 'Severly Injured'
wounded_2 = {
	martial = -2
	intrigue = -2
	health = -2
	prowess = -4
	fertility = -0.25
	category = health

	dread_baseline_add = -15
	dread_loss_mult = 1
	
	attraction_opinion = -10

	disables_combat_leadership = yes
	
	shown_in_ruler_designer = no

	flag = no_message
	flag = is_healthy_trigger_flag

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_wounded_2_desc
			}
			desc = trait_wounded_2_character_desc
		}
	}

	ai_energy = -30
	
	group = wounded
	level = 2
}

# 'Near Death'
wounded_3 = {
	martial = -4
	intrigue = -4
	health = -4
	prowess = -8
	fertility = -0.75
	category = health

	dread_baseline_add = -20
	dread_loss_mult = 1

	attraction_opinion = -20
	
	disables_combat_leadership = yes
	
	shown_in_ruler_designer = no

	flag = no_message
	flag = is_healthy_trigger_flag

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_wounded_3_desc
			}
			desc = trait_wounded_3_character_desc
		}
	}

	ai_energy = -40
	
	group = wounded
	level = 3
}

maimed = {
	
	diplomacy = -2
	martial = -2
	stewardship = -2
	intrigue = -2
	learning = -2
	prowess = -4
	
	culture_modifier = {
		parameter = wounds_and_scars_give_bonuses
		monthly_prestige_gain_mult = 0.2
		same_culture_opinion = 15
	}

	culture_modifier = {
		parameter = palace_politics_trait_maluses
		monthly_influence = -0.35
	}

	category = health

	dread_baseline_add = -15
	dread_loss_mult = 1
	
	attraction_opinion = -10
	
	same_opinion = 5
	
	shown_in_ruler_designer = no

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_maimed_desc
			}
			desc = trait_maimed_character_desc
		}
	}
}

one_eyed = {
	category = health
	learning = 1
	prowess = -2
	
	dread_baseline_add = 10

	attraction_opinion = -5
	
	culture_modifier = {
		parameter = wounds_and_scars_give_bonuses
		monthly_prestige_gain_mult = 0.1
		same_culture_opinion = 5
	}

	culture_modifier = {
		parameter = palace_politics_trait_maluses
		monthly_influence = -0.35
	}
	
	ruler_designer_cost = 10
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_one_eyed_desc
			}
			desc = trait_one_eyed_character_desc
		}
	}

	ai_energy = -10
}

one_legged = {
	category = health
	learning = 1
	prowess = -4
	
	dread_baseline_add = -10

	attraction_opinion = -10
	
	culture_modifier = {
		parameter = wounds_and_scars_give_bonuses
		monthly_prestige_gain_mult = 0.15
		same_culture_opinion = 10
	}

	culture_modifier = {
		parameter = palace_politics_trait_maluses
		monthly_influence = -0.35
	}
	
	ruler_designer_cost = -5

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_one_legged_desc
			}
			desc = trait_one_legged_character_desc
		}
	}

	ai_energy = -10
}

disfigured = {
	category = health
	diplomacy = -4
	fertility = -0.2
	
	#No dread loss: you're not actually worse for wear physically or mentally.

	attraction_opinion = -20

	culture_modifier = {
		parameter = wounds_and_scars_give_bonuses
		monthly_prestige_gain_mult = 0.15
		same_culture_opinion = 10
	}
	
	culture_modifier = {
		parameter = palace_politics_trait_maluses
		monthly_influence = -1
	}
	
	ruler_designer_cost = -10

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_disfigured_desc
			}
			desc = trait_disfigured_character_desc
		}
	}

	ai_sociability = low_negative_ai_value
}

infirm = {
	diplomacy = -1
	martial = -1
	prowess_mult = -0.2
	health = -0.25
	fertility = -0.1
	ai_energy = -10
	
	flag = infirm_random_xp_gain
	flag = age_related_ailment
	flag = is_healthy_trigger_flag

	category = health

	disables_combat_leadership = yes
	
	ruler_designer_cost = -20
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_infirm_desc
			}
			desc = trait_infirm_character_desc
		}
	}
	
	tracks = {
		infirm = {
			25 = {
				diplomacy = -1
				martial = -1
				stewardship = -1
				prowess_mult = -0.2
				health = -0.25
				fertility = -0.1
				dread_baseline_add = -5
				dread_loss_mult = 0.25
				attraction_opinion = -5
				ai_energy = -10
			}
			50 = {
				diplomacy = -2
				martial = -2
				stewardship = -2
				prowess_mult = -0.2
				health = -0.25
				fertility = -0.1
				dread_baseline_add = -10
				dread_loss_mult = 0.25
				attraction_opinion = -5
				ai_energy = -10
			}
			75 = {
				diplomacy = -2
				martial = -2
				stewardship = -2
				prowess_mult = -0.2
				health = -0.25
				fertility = -0.1
				dread_baseline_add = -10
				dread_loss_mult = 0.25
				attraction_opinion = -5
				ai_energy = -10
			}
			100 = {
				diplomacy = -2
				martial = -2
				stewardship = -2
				prowess_mult = -0.2
				health = -0.25
				fertility = -0.1
				dread_baseline_add = -10
				dread_loss_mult = 0.25
				attraction_opinion = -5
				ai_energy = -10
			}
		}
	}
}

withering_mind = {
	learning = -2
	monthly_lifestyle_xp_gain_mult = -0.25
	stress_gain_mult = 0.2
	ai_rationality = -25
	
	flag = withering_mind_random_xp_gain
	flag = incapable_on_max_level
	flag = age_related_ailment
	flag = is_healthy_trigger_flag

	category = health
	
	ruler_designer_cost = -20
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_withering_mind_desc
			}
			desc = trait_withering_mind_character_desc
		}
	}
	
	tracks = {
		withering_mind = {
			25 = {
				diplomacy_mult = -0.25
				martial_mult = -0.25
				stewardship_mult = -0.25
				intrigue_mult = -0.25
				learning_mult = -0.25
				monthly_lifestyle_xp_gain_mult = -0.25
				stress_gain_mult = 0.2
				ai_rationality = -25
			}
			50 = {
				diplomacy_mult = -0.25
				martial_mult = -0.25
				stewardship_mult = -0.25
				intrigue_mult = -0.25
				learning_mult = -0.25
				monthly_lifestyle_xp_gain_mult = -0.25
				stress_gain_mult = 0.2
				ai_rationality = -25
			}
			75 = {
				diplomacy_mult = -0.25
				martial_mult = -0.25
				stewardship_mult = -0.25
				intrigue_mult = -0.25
				learning_mult = -0.25
				monthly_lifestyle_xp_gain_mult = -0.5
				stress_gain_mult = 0.2
				ai_rationality = -25
			}
			100 = {
				diplomacy_mult = -0.25
				martial_mult = -0.25
				stewardship_mult = -0.25
				intrigue_mult = -0.25
				learning_mult = -0.25
				monthly_lifestyle_xp_gain_mult = -0.5
				stress_gain_mult = 0.2
				ai_rationality = -25
			}
		}
	}
}

clouded_eyes = {
	martial = -1
	prowess = -2
	
	flag = clouded_eyes_random_xp_gain
	flag = age_related_ailment
	flag = is_healthy_trigger_flag
	flag = blind_on_max_level

	category = health
	
	ruler_designer_cost = -20
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_clouded_eyes_desc
			}
			desc = trait_clouded_eyes_character_desc
		}
	}
	
	tracks = {
		clouded_eyes = {
			25 = {
				martial = -1
				prowess = -2
			}
			50 = {
				martial = -1
				prowess = -2
			}
			75 = {
				martial = -1
				stewardship = -1
				intrigue = -1
				prowess = -2
				
				dread_baseline_add = -5

				attraction_opinion = -5
			}
			100 = {
				martial = -2
				stewardship = -1
				intrigue = -1
				prowess = -2
				
				health = -0.25
				
				dread_baseline_add = -5

				attraction_opinion = -5
			}
		}
	}
}

faltering_heart = {
	health = -0.1
	prowess = -1
	character_travel_safety = -2
	stress_gain_mult = 0.2
	stress_loss_mult = -0.2
	
	flag = faltering_heart_random_xp_gain
	flag = age_related_ailment
	flag = is_healthy_trigger_flag
	flag = death_on_max_level

	category = health
	
	ruler_designer_cost = -20
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_faltering_heart_desc
			}
			desc = trait_faltering_heart_character_desc
		}
	}
	
	tracks = {
		faltering_heart = {
			25 = {
				health = -0.1
				prowess = -1
				character_travel_safety = -2
				stress_gain_mult = 0.2
				stress_loss_mult = -0.2
			}
			50 = {
				health = -0.1
				prowess = -1
				character_travel_safety = -2
				stress_gain_mult = 0.2
				stress_loss_mult = -0.2
			}
			75 = {
				health = -0.1
				prowess = -1
				character_travel_safety = -2
				stress_gain_mult = 0.2
				stress_loss_mult = -0.2
			}
			100 = {
				health = -100
			}
		}
	}
}

fragile_bones = {
	character_travel_speed_mult = -0.1
	prowess_mult = -0.1
	advantage = -3
	life_expectancy = -3
	enemy_hostile_scheme_success_chance_max_add = 5
	
	flag = fragile_bones_random_xp_gain
	flag = age_related_ailment
	flag = is_healthy_trigger_flag
	flag = wounds_twice_as_bad

	category = health
	
	ruler_designer_cost = -20
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_fragile_bones_desc
			}
			desc = trait_fragile_bones_character_desc
		}
	}
	
	tracks = {
		fragile_bones = {
			25 = {
				character_travel_speed_mult = -0.1
				prowess_mult = -0.1
				advantage = -3
				life_expectancy = -3
				enemy_hostile_scheme_success_chance_max_add = 10
			}
			50 = {
				character_travel_speed_mult = -0.1
				prowess_mult = -0.1
				advantage = -3
				life_expectancy = -3
				enemy_hostile_scheme_success_chance_max_add = 10
			}
			75 = {
				character_travel_speed_mult = -0.1
				prowess_mult = -0.1
				advantage = -5
				life_expectancy = -5
				enemy_hostile_scheme_success_chance_max_add = 15
			}
			100 = {
				character_travel_speed_mult = -0.1
				prowess_mult = -0.1
				advantage = -10
				life_expectancy = -10
				enemy_hostile_scheme_success_chance_max_add = 15
			}
		}
	}
}

incapable = {
	diplomacy_mult = -1
	martial_mult = -1
	stewardship_mult = -1
	intrigue_mult = -1
	learning_mult = -1
	prowess_mult = -1
	health = -2
	
	dread_baseline_add = -25
	dread_loss_mult = 1
	category = health

	incapacitating = yes
	
	can_have_children = no

	disables_combat_leadership = yes
	
	shown_in_ruler_designer = no
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_incapable_desc
			}
			desc = trait_incapable_character_desc
		}
	}

	ai_energy = -100
	
	flag = is_healthy_trigger_flag
}

gout_ridden = {
	diplomacy_mult = -0.1
	martial_mult = -0.1
	prowess_mult = -0.2
	health = -1
	
	dread_baseline_add = -5
	category = health
	attraction_opinion = -15
	
	ruler_designer_cost = -5

	flag = illness
	flag = debilitating_illness
	flag = blocks_getting_non_epidemic_disease

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_gout_ridden_desc
			}
			desc = trait_gout_ridden_character_desc
		}
	}

	ai_energy = -15
}

consumption = { # Tuberculosis
	diplomacy = -2
	stewardship = -1
	intrigue = -2
	prowess_mult = -0.4
	health = -2.5
	child_health = -1
	elderly_health = -2
	category = health

	dread_baseline_add = -10
	dread_loss_mult = 1

	attraction_opinion = -10
	
	ruler_designer_cost = 0

	flag = illness
	flag = debilitating_illness
	flag = contagious_deadly_disease
	flag = epidemic_disease
	flag = blocks_getting_non_epidemic_disease

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_consumption_desc
			}
			desc = trait_consumption_character_desc
		}
	}

	ai_energy = -50
}

cancer = {
	health = -3
	elderly_health = -1
	fertility = -0.20
	category = health

	dread_baseline_add = -15
	dread_loss_mult = 1
	
	ruler_designer_cost = -10

	flag = illness
	flag = debilitating_illness
	flag = blocks_getting_non_epidemic_disease

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_cancer_desc
			}
			desc = trait_cancer_character_desc
		}
	}

	ai_energy = -25
}

typhus = {
	diplomacy = -1
	stewardship = -2
	intrigue = -1
	learning = -2
	prowess_mult = -0.8
	health = -4.5
	elderly_health = -1
	fertility = -0.2

	category = health

	dread_baseline_add = -15
	dread_loss_mult = 1

	attraction_opinion = -10
	
	ruler_designer_cost = 0

	flag = illness
	flag = debilitating_illness
	flag = contagious_deadly_disease
	flag = epidemic_disease
	flag = blocks_getting_non_epidemic_disease

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_typhus_desc
			}
			desc = trait_typhus_character_desc
		}
	}

	ai_energy = -50
}

bubonic_plague = {
	diplomacy = -2
	martial = -3
	stewardship = -2
	intrigue = -3
	learning = -2
	prowess_mult = -0.8
	health = -7
	elderly_health = -2
	fertility = -0.50

	category = health
	
	dread_baseline_add = -30
	dread_loss_mult = 1

	attraction_opinion = -30
	
	shown_in_ruler_designer = no

	flag = illness
	flag = debilitating_illness
	flag = contagious_deadly_disease
	flag = epidemic_disease
	flag = blocks_getting_non_epidemic_disease

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_bubonic_plague_desc
			}
			desc = trait_bubonic_plague_character_desc
		}
	}

	ai_energy = -75
}

smallpox = {
	diplomacy = -2
	stewardship = -1
	learning = -2
	prowess_mult = -0.8
	health = -4.5
	elderly_health = -1.5
	fertility = -0.25

	category = health
	
	dread_baseline_add = -15
	dread_loss_mult = 1

	attraction_opinion = -10
	
	ruler_designer_cost = 0

	flag = illness
	flag = debilitating_illness
	flag = contagious_deadly_disease
	flag = epidemic_disease
	flag = blocks_getting_non_epidemic_disease

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_smallpox_desc
			}
			desc = trait_smallpox_character_desc
		}
	}

	ai_energy = -75
}

measles = {
	diplomacy = -2
	stewardship = -1
	intrigue = -1
	learning = -2
	prowess_mult = -0.4
	health = -3
	child_health = -3

	category = health
	
	dread_baseline_add = -5

	attraction_opinion = -10
	
	ruler_designer_cost = 0

	flag = illness
	flag = debilitating_illness
	flag = contagious_deadly_disease
	flag = epidemic_disease
	flag = blocks_getting_non_epidemic_disease

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_measles_desc
			}
			desc = trait_measles_character_desc
		}
	}

	ai_energy = -75
}

dysentery = { # Bloody Flux
	diplomacy = -2
	martial = -1
	intrigue = -2
	prowess_mult = -0.8
	health = -3.5
	elderly_health = -2

	category = health
	
	dread_baseline_add = -50

	attraction_opinion = -5
	
	ruler_designer_cost = 0

	flag = illness
	flag = debilitating_illness
	flag = contagious_deadly_disease
	flag = epidemic_disease
	flag = blocks_getting_non_epidemic_disease

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_dysentery_desc
			}
			desc = trait_dysentery_character_desc
		}
	}

	ai_energy = -75
}

ergotism = { # Holy Fire
	diplomacy = -6
	stewardship = -1
	intrigue = -2
	learning = -2
	health = -3.5

	category = health
	
	dread_baseline_add = -25

	attraction_opinion = -10
	
	ruler_designer_cost = 0

	flag = illness
	flag = debilitating_illness
	flag = epidemic_disease
	flag = blocks_getting_non_epidemic_disease

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_ergotism_desc
			}
			desc = trait_ergotism_character_desc
		}
	}

	ai_energy = -75
}

# Young children only
sickly = {
	maximum_age = 6
	child_health = -2.5

	category = health

	dread_baseline_add = -20
	dread_loss_mult = 1
	
	shown_in_ruler_designer = no

	flag = illness
	flag = debilitating_illness

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_sickly_desc
			}
			desc = trait_sickly_character_desc
		}
	}

	ai_energy = -30
}

# The character is visibly scarred from an old wound
scarred = {
	name = {
		first_valid = {
			triggered_desc = {
				trigger = {
					trigger_if = {
						limit = {
							NOT = { exists = this }
						}
					}
					trigger_else_if = {
						limit = { has_trait = scarred }
						has_trait_xp = {
							trait = scarred
							track = scarred
							value < 50
						}
					}
					trigger_else = {
						NOT = { has_trait = scarred }
					}
				}
				desc = trait_scarred
			}
			triggered_desc = {
				trigger = {
					has_trait = scarred
					has_trait_xp = {
						trait = scarred
						track = scarred
						value = 100
					}
				}
				desc = trait_scarred_3
			}
			desc = trait_scarred_2
		}
	}

	monthly_prestige = 0.1
	
	attraction_opinion = 5
	
	culture_modifier = {
		parameter = wounds_and_scars_give_bonuses
		monthly_prestige_gain_mult = 0.1
		same_culture_opinion = 5
	}
	
	category = health
	
	ruler_designer_cost = 10
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_scarred_desc
			}
			desc = trait_scarred_character_desc
		}
	}

	tracks = {
		scarred = {
			trait_second_level = { # Gnarled
				monthly_prestige = 0.05
				attraction_opinion = -5
				child_opinion = -10
				health = -0.1
			}
			trait_third_level = { # Marred
				attraction_opinion = -20
				child_opinion = -20
				health = -0.1
				dread_gain_mult = 0.1
			}
		}
	}
}

#This is the normal eunuch trait (for eunuchs castrated as teens/adults)
eunuch_1 = { 
	category = health
	group_equivalence = eunuch
	attraction_opinion = -10
	glory_hound_opinion = -10

	flag = can_not_marry
	inheritance_blocker = all
	claim_inheritance_blocker = all
	can_have_children = no
	opposites = {
		beardless_eunuch #You can't have both
	}

	valid_sex = male

	shown_in_ruler_designer = yes

	culture_modifier = {
		parameter = eunuch_trait_bonuses

		# Eunuchs were historically considered to be both innocuous as well as duplicitous. This semi-paradoxical belief made rulers favor them for various court positions, especially ones close to their family.
		liege_opinion = 10
		ai_honor = -10

		# Simultaneously, eunuchs were seen as unfit to hold leadership positions, as they are impotent.
		vassal_opinion = -10
		ai_greed = -10

		# Eunuchs in this society have various privileges (due to their assumed innocuousness) that make them better at both spying as well as administrative tasks and scholastic pursuits.
		stewardship = 2
		intrigue = 2
		learning = 2
		monthly_influence_mult = 0.5
	}

	culture_modifier = {
		parameter = court_machinations_eunuch_trait_bonuses

		# In China Eunuchs have a similar role to the one described above but they also serve as commanders, governors and be accomplished scholars. They still had a clear rivalry with the other scholar officials of the empire.

		liege_opinion = 15 #Emperors loyal subjects and often agents
		same_culture_opinion = -15 #Everyone else distrusts them
		ai_honor = -10

		martial = 1
		intrigue = 3
		learning = 2
		monthly_influence_mult = 0.5
		monthly_merit_mult = 0.5
		monthly_merit = 0.1
	}

	ruler_designer_cost = -10

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_eunuch_1_desc
			}
			desc = trait_eunuch_1_character_desc
		}
	}

	ai_energy = -15

	level = 1
}

beardless_eunuch = {
	category = health
	group_equivalence = eunuch
	attraction_opinion = -10
	glory_hound_opinion = -20

	opposites = {
		eunuch_1 #You can't have both
	}

	flag = can_not_marry
	inheritance_blocker = all
	claim_inheritance_blocker = all
	can_have_children = no

	valid_sex = male
	
	shown_in_ruler_designer = yes

	prowess = -4

	culture_modifier = {
		parameter = eunuch_trait_bonuses

		# Eunuchs were historically considered to be both innocuous as well as duplicitous. This semi-paradoxical belief made rulers favor them for various court positions, especially ones close to their family.
		liege_opinion = 20
		ai_honor = -15

		# Simultaneously, eunuchs were seen as unfit to hold leadership positions, as they are impotent.
		vassal_opinion = -10
		ai_greed = -15

		# Eunuchs in this society have various privileges (due to their assumed innocuousness) that make them better at both spying as well as administrative tasks and scholastic pursuits.
		martial = 1
		intrigue = 3
		learning = 2
		monthly_influence_mult = 0.5
		monthly_influence = 0.1
	}

	culture_modifier = {
		parameter = court_machinations_eunuch_trait_bonuses

		# In China Eunuchs have a similar role to the one described above but they also serve as commanders, governors and be accomplished scholars. They still had a clear rivalry with the other scholar officials of the empire.

		liege_opinion = 15 #Emperors loyal subjects and often agents
		same_culture_opinion = -15 #Everyone else distrusts them
		ai_honor = -10

		stewardship = 2
		intrigue = 2
		learning = 2
		monthly_influence_mult = 0.5
		monthly_merit_mult = 0.5
		monthly_merit = 0.1
	}

	ruler_designer_cost = -15

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_beardless_eunuch_desc
			}
			desc = trait_beardless_eunuch_character_desc
		}
	}

	ai_energy = -25
	ai_boldness = -10

	level = 2
}

blind = {
	category = health
	martial = -6
	stewardship = -2
	intrigue = -2
	prowess = -10
	health = -0.25
	
	dread_baseline_add = -10

	attraction_opinion = -10
	
	ruler_designer_cost = -10

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_blind_desc
			}
			desc = trait_blind_character_desc
		}
	}
}

############### Physical ##############
# Beauty (-1) - Homely
beauty_bad_1 = {
	opposites = {
		beauty_good
		beauty_bad_2
		beauty_bad_3
	}
	
	diplomacy = -1
	fertility = -0.1
	
	birth = 0.5
	random_creation = 0.5
	
	attraction_opinion = -10

	group = beauty_bad
	level = 1
	
	genetic = yes
	physical = yes
	portrait_extremity_shift = 0.1
	ugliness_portrait_extremity_shift = 0.4
	
	ruler_designer_cost = -10

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_beauty_bad_1_desc
			}
			desc = trait_beauty_bad_1_character_desc
		}
	}
}

# Beauty (-2) - Ugly
beauty_bad_2 = {
	opposites = {
		beauty_good
		beauty_bad_3
		beauty_bad_1
	}
	
	diplomacy = -2
	fertility = -0.2
	
	birth = 0.25
	random_creation = 0.25
	
	attraction_opinion = -20

	group = beauty_bad
	level = 2
	
	genetic = yes
	physical = yes
	portrait_extremity_shift = 0.18
	ugliness_portrait_extremity_shift = 0.6
	
	ruler_designer_cost = -20

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_beauty_bad_2_desc
			}
			desc = trait_beauty_bad_2_character_desc
		}
	}
}

# Beauty (-3) - Hideous
beauty_bad_3 = {
	opposites = {
		beauty_good
		beauty_bad_2
		beauty_bad_1
	}
	
	birth = 0.15
	random_creation = 0.15
	
	diplomacy = -3
	fertility = -0.3
	
	attraction_opinion = -30
	
	group = beauty_bad
	level = 3
	
	genetic = yes
	physical = yes
	portrait_extremity_shift = 0.27
	ugliness_portrait_extremity_shift = 0.8
	
	ruler_designer_cost = -30

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_beauty_bad_3_desc
			}
			desc = trait_beauty_bad_3_character_desc
		}
	}
}

# Beauty (+1) - Comely
beauty_good_1 = {
	opposites = {
		beauty_bad
		beauty_good_2
		beauty_good_3
	}
	
	diplomacy = 1
	fertility = 0.1
	
	birth = 0.5
	random_creation = 0.5
	
	attraction_opinion = 10

	group = beauty_good
	level = 1
	
	genetic = yes
	physical = yes
	good = yes
	
	genetic_constraint_all = beauty_1
	genetic_constraint_men = male_beauty_1
	genetic_constraint_women = female_beauty_1
	
	ruler_designer_cost = 40

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_beauty_good_1_desc
			}
			desc = trait_beauty_good_1_character_desc
		}
	}
}

# Beauty (+2) - Pretty (f) / Handsome (m)
beauty_good_2 = {
	opposites = {
		beauty_bad
		beauty_good_1
		beauty_good_3
	}
	
	diplomacy = 2
	fertility = 0.2
	
	birth = 0.25
	random_creation = 0.25
	
	attraction_opinion = 20

	# pretty if female
	# handsome if male

	group = beauty_good
	level = 2
	
	ruler_designer_cost = 80

	name = {
		first_valid = {
			triggered_desc = {
				trigger = { NOT = { exists = this } }
				desc = trait_beauty_good_male_2
			}
			triggered_desc = {
				trigger = { is_female = yes }
				desc = trait_beauty_good_female_2
			}
			desc = trait_beauty_good_male_2
		}
	}

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = { NOT = { exists = this } }
				desc = trait_beauty_good_2_desc
			}
			desc = trait_beauty_good_2_character_desc
		}
	}
	
	genetic = yes
	physical = yes
	good = yes
	
	genetic_constraint_all = beauty_2
	genetic_constraint_men = male_beauty_2
	genetic_constraint_women = female_beauty_2
}

# Beauty (+3) - Beautiful
beauty_good_3 = {
	opposites = {
		beauty_bad
		beauty_good_2
		beauty_good_1
	}
	
	birth = 0.15
	random_creation = 0.15
	
	diplomacy = 3
	fertility = 0.3
	
	attraction_opinion = 30

	group = beauty_good
	level = 3
	
	genetic = yes
	physical = yes
	good = yes
	
	genetic_constraint_all = beauty_3
	genetic_constraint_men = male_beauty_3
	genetic_constraint_women = female_beauty_3
	
	ruler_designer_cost = 120

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_beauty_good_3_desc
			}
			desc = trait_beauty_good_3_character_desc
		}
	}
}

# Intellect (-1) - Slow
intellect_bad_1 = {
	opposites = {
		shrewd
		intellect_good
		intellect_bad_2 #To prevent multiple tiers of the same congenital trait
		intellect_bad_3
	}
	
	diplomacy = -2
	martial = -2
	stewardship = -2
	intrigue = -2	
	learning = -2
	
	monthly_lifestyle_xp_gain_mult = -0.1
	
	birth = 0.5
	random_creation = 0.5
	
	group = intellect_bad
	level = 1	

	ai_rationality = high_negative_ai_value
	
	genetic = yes
	physical = yes
	
	ruler_designer_cost = -15

	compatibility = {
		intellect_bad_1 = @pos_compat_medium
		intellect_bad_2 = @pos_compat_medium
		intellect_bad_3 = @pos_compat_medium
		dull = @pos_compat_medium
		intellect_good_1 = @neg_compat_medium
		intellect_good_2 = @neg_compat_medium
		intellect_good_3 = @neg_compat_medium
		shrewd = @neg_compat_medium
	}

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_intellect_bad_1_desc
			}
			desc = trait_intellect_bad_1_character_desc
		}
	}
}

# Intellect (-2) - Stupid
intellect_bad_2 = {
	opposites = {
		shrewd
		intellect_good
		intellect_bad_3 #To prevent multiple tiers of the same congenital trait
		intellect_bad_1
	}
	
	diplomacy = -4
	martial = -4
	stewardship = -4
	intrigue = -4	
	learning = -4
	
	monthly_lifestyle_xp_gain_mult = -0.2
	
	birth = 0.25
	random_creation = 0.25

	group = intellect_bad
	level = 2

	ai_rationality = very_high_negative_ai_value
	
	genetic = yes
	physical = yes
	
	ruler_designer_cost = -30

	compatibility = {
		intellect_bad_1 = @pos_compat_medium
		intellect_bad_2 = @pos_compat_medium
		intellect_bad_3 = @pos_compat_medium
		dull = @pos_compat_medium
		intellect_good_1 = @neg_compat_medium
		intellect_good_2 = @neg_compat_medium
		intellect_good_3 = @neg_compat_medium
		shrewd = @neg_compat_medium
	}

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_intellect_bad_2_desc
			}
			desc = trait_intellect_bad_2_character_desc
		}
	}
}
# Intellect (-3) - Imbecile
intellect_bad_3 = {
	opposites = {
		shrewd
		intellect_good
		intellect_bad_2 #To prevent multiple tiers of the same congenital trait
		intellect_bad_1
	}
	
	birth = 0.05
	random_creation = 0.05
	
	diplomacy = -8
	martial = -8
	stewardship = -8
	intrigue = -8	
	learning = -8
	
	monthly_lifestyle_xp_gain_mult = -0.3

	group = intellect_bad
	level = 3

	ai_rationality = dominant_negative_ai_value
	
	genetic = yes
	physical = yes
	
	ruler_designer_cost = -45

	compatibility = {
		intellect_bad_1 = @pos_compat_medium
		intellect_bad_2 = @pos_compat_medium
		intellect_bad_3 = @pos_compat_medium
		dull = @pos_compat_medium
		intellect_good_1 = @neg_compat_medium
		intellect_good_2 = @neg_compat_medium
		intellect_good_3 = @neg_compat_medium
		shrewd = @neg_compat_medium
	}

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_intellect_bad_3_desc
			}
			desc = trait_intellect_bad_3_character_desc
		}
	}
}

# Intellect (+1) - Quick
intellect_good_1 = {
	opposites = {
		dull
		intellect_bad
		intellect_good_2 #To prevent multiple tiers of the same congenital trait
		intellect_good_3
	}
	
	diplomacy = 1
	martial = 1
	stewardship = 1
	intrigue = 1
	learning = 1
	
	monthly_lifestyle_xp_gain_mult = 0.1
	
	birth = 0.5
	random_creation = 0.5

	group = intellect_good
	level = 1

	ai_rationality = high_positive_ai_value
	
	genetic = yes
	good = yes
	physical = yes
	
	ruler_designer_cost = 80
	
	compatibility = {
		intellect_good_1 = @pos_compat_medium
		intellect_good_2 = @pos_compat_medium
		intellect_good_3 = @pos_compat_medium
		shrewd = @pos_compat_medium
		intellect_bad_1 = @neg_compat_medium
		intellect_bad_2 = @neg_compat_medium
		intellect_bad_3 = @neg_compat_medium
		dull = @neg_compat_medium
	}

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_intellect_good_1_desc
			}
			desc = trait_intellect_good_1_character_desc
		}
	}
}

# Intellect (+2) - Intelligent
intellect_good_2 = {
	opposites = {
		dull
		intellect_bad
		intellect_good_3 #To prevent multiple tiers of the same congenital trait
		intellect_good_1
	}
	
	diplomacy = 3
	martial = 3
	stewardship = 3
	intrigue = 3
	learning = 3
	
	monthly_lifestyle_xp_gain_mult = 0.2
	
	birth = 0.25
	random_creation = 0.25

	group = intellect_good
	level = 2

	ai_rationality = very_high_positive_ai_value
	
	genetic = yes
	good = yes
	physical = yes
	
	ruler_designer_cost = 160
	
	compatibility = {
		intellect_good_1 = @pos_compat_medium
		intellect_good_2 = @pos_compat_medium
		intellect_good_3 = @pos_compat_medium
		shrewd = @pos_compat_medium
		intellect_bad_1 = @neg_compat_medium
		intellect_bad_2 = @neg_compat_medium
		intellect_bad_3 = @neg_compat_medium
		dull = @neg_compat_medium
	}

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_intellect_good_2_desc
			}
			desc = trait_intellect_good_2_character_desc
		}
	}
}

# Intellect (+3) - Genius
intellect_good_3 = {
	opposites = {
		dull
		intellect_bad
		intellect_good_2 #To prevent multiple tiers of the same congenital trait
		intellect_good_1
	}
	
	birth = 0.05
	random_creation = 0.05
	
	diplomacy = 5
	martial = 5
	stewardship = 5
	intrigue = 5
	learning = 5
	
	monthly_lifestyle_xp_gain_mult = 0.3

	group = intellect_good
	level = 3
	
	ai_rationality = dominant_positive_ai_value
	
	genetic = yes
	good = yes
	physical = yes
	
	ruler_designer_cost = 240
	
	compatibility = {
		intellect_good_1 = @pos_compat_medium
		intellect_good_2 = @pos_compat_medium
		intellect_good_3 = @pos_compat_medium
		shrewd = @pos_compat_medium
		intellect_bad_1 = @neg_compat_medium
		intellect_bad_2 = @neg_compat_medium
		intellect_bad_3 = @neg_compat_medium
		dull = @neg_compat_medium
	}

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_intellect_good_3_desc
			}
			desc = trait_intellect_good_3_character_desc
		}
	}
}

# Physique (-1) - Delicate
physique_bad_1 = {
	opposites = {
		strong
		physique_good
		physique_bad_2
		physique_bad_3
	}
	
	prowess = -2
	health = -0.25
	
	birth = 0.5
	random_creation = 0.5

	group = physique_bad
	level = 1
	
	ruler_designer_cost = -15
	
	culture_modifier = {
		parameter = weak_traits_looked_down_upon
		same_culture_opinion = -10
	}
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_physique_bad_1_desc
			}
			desc = trait_physique_bad_1_character_desc
		}
	}

	ai_energy = -10
	
	genetic = yes
	physical = yes
}

# Physique (-2) - Frail
physique_bad_2 = {
	opposites = {
		strong
		physique_good
		physique_bad_3
		physique_bad_1
	}
	
	prowess = -4
	health = -0.5
	
	birth = 0.25
	random_creation = 0.25
	
	attraction_opinion = -5

	group = physique_bad
	level = 2
	
	culture_modifier = {
		parameter = weak_traits_looked_down_upon
		same_culture_opinion = -15
	}
	
	ruler_designer_cost = -30
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_physique_bad_2_desc
			}
			desc = trait_physique_bad_2_character_desc
		}
	}

	ai_energy = -20
	
	genetic = yes
	physical = yes
}

# Physique (-3) - Feeble
physique_bad_3 = {
	opposites = {
		strong
		physique_good
		physique_bad_2
		physique_bad_1
	}
	
	birth = 0.15
	random_creation = 0.15
	
	prowess = -6
	health = -1
	
	attraction_opinion = -10
	
	culture_modifier = {
		parameter = weak_traits_looked_down_upon
		same_culture_opinion = -20
	}

	group = physique_bad
	level = 3
	
	ruler_designer_cost = -45
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_physique_bad_3_desc
			}
			desc = trait_physique_bad_3_character_desc
		}
	}

	ai_energy = -30
	
	genetic = yes
	physical = yes
}

# Physique (+1) - Hale
physique_good_1 = {
	opposites = {
		weak
		spindly
		physique_bad
		physique_good_2
		physique_good_3
	}
	
	prowess = 2
	health = 0.25
	
	birth = 0.5
	random_creation = 0.5
	
	attraction_opinion = 5
	
	culture_modifier = {
		parameter = strong_traits_more_valued
		monthly_prestige = 0.25
	}

	group = physique_good
	level = 1
	
	ruler_designer_cost = 60
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_physique_good_1_desc
			}
			desc = trait_physique_good_1_character_desc
		}
	}

	ai_energy = 10
	
	genetic = yes
	physical = yes
	good = yes
}

# Physique (+2) - Robust
physique_good_2 = {
	opposites = {
		weak
		spindly
		physique_bad
		physique_good_1
		physique_good_3
	}
	
	physical = yes
	
	prowess = 4
	health = 0.5
	
	birth = 0.25
	random_creation = 0.25
	
	attraction_opinion = 10
	
	culture_modifier = {
		parameter = strong_traits_more_valued
		monthly_prestige = 0.5
	}

	group = physique_good
	level = 2
	
	ruler_designer_cost = 120
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_physique_good_2_desc
			}
			desc = trait_physique_good_2_character_desc
		}
	}

	ai_energy = 20
	
	genetic = yes
	good = yes
}

# Physique (+3) - Amazonian (f) / Herculean (m)
physique_good_3 = {
	opposites = {
		weak
		spindly
		physique_bad
		physique_good_1
		physique_good_2
	}
	
	birth = 0.15
	random_creation = 0.15
	
	prowess = 8
	health = 1
	
	attraction_opinion = 15
	
	culture_modifier = {
		parameter = strong_traits_more_valued
		monthly_prestige = 1
	}

	# amazonian if female
	# herculean if male
	
	ruler_designer_cost = 180

	name = {
		first_valid = {
			triggered_desc = {
				trigger = { NOT = { exists = this } }
				desc = trait_physique_good_male_3
			}
			triggered_desc = {
				trigger = { is_female = yes }
				desc = trait_physique_good_female_3
			}
			desc = trait_physique_good_male_3
		}
	}

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_physique_good_3_desc
			}
			desc = trait_physique_good_3_character_desc
		}
	}

	group = physique_good
	level = 3
	
	ai_energy = 20
	
	genetic = yes
	physical = yes
	good = yes
}

################# PHYSICAL (GOOD) ################
pure_blooded = {
	physical = yes
	fertility = 0.1
	health = 0.25
	inbreeding_chance = -0.5
	
	inherit_chance = 15
	both_parent_has_trait_inherit_chance = 75
	good = yes
	
	ruler_designer_cost = 50

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_pure_blooded_desc
			}
			desc = trait_pure_blooded_character_desc
		}
	}
}

fecund = {
	opposites = {
		infertile
	}
	
	fertility = 0.5
	life_expectancy = 5
	years_of_fertility = 5
	
	#inherit_chance = 15
	physical = yes
	genetic = yes
	good = yes
	
	ruler_designer_cost = 50

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_fecund_desc
			}
			desc = trait_fecund_character_desc
		}
	}
}

strong = {
	opposites = {
		weak
		physique_bad
	}
	prowess = 4
	health = 0.5
	physical = yes
	
	culture_modifier = {
		parameter = strong_traits_more_valued
		monthly_prestige = 1
	}
	
	ruler_designer_cost = 50
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_strong_desc
			}
			desc = trait_strong_character_desc
		}
	}

	ai_energy = 20
}

shrewd = {
	opposites = {
		intellect_bad
		dull
	}
	diplomacy = 2
	martial = 2
	stewardship = 2
	intrigue = 2	
	learning = 2

	physical = yes
	
	ruler_designer_cost = 50

	culture_modifier = {
		parameter = pragmatic_traits_county_opinion_modifiers
		county_opinion_add = 10
	}
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_shrewd_desc
			}
			desc = trait_shrewd_character_desc
		}
	}

	ai_rationality = high_positive_ai_value

	compatibility = {
		intellect_good_1 = @pos_compat_medium
		intellect_good_2 = @pos_compat_medium
		intellect_good_3 = @pos_compat_medium
		shrewd = @pos_compat_medium
		intellect_bad_1 = @neg_compat_medium
		intellect_bad_2 = @neg_compat_medium
		intellect_bad_3 = @neg_compat_medium
		dull = @neg_compat_medium
	}
}

################# PHYSICAL (BAD) ################
clubfooted = {
	prowess = -2
	
	#inherit_chance = 15
	genetic = yes
	enables_inbred = yes
	birth = 0.5
	random_creation = 0.5
	
	attraction_opinion = -10
	same_opinion = 10
	physical = yes
	
	ruler_designer_cost = 0

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_clubfooted_desc
			}
			desc = trait_clubfooted_character_desc
		}
	}
}

hunchbacked = {
	prowess = -2

	#inherit_chance = 15
	genetic = yes
	physical = yes
	enables_inbred = yes
	birth = 0.5
	random_creation = 0.5
	
	attraction_opinion = -30
	same_opinion = 10
	vassal_opinion = -10
	
	ruler_designer_cost = -10

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_hunchbacked_desc
			}
			desc = trait_hunchbacked_character_desc
		}
	}
}

lisping = {
	diplomacy = -2
	
	#inherit_chance = 15
	genetic = yes
	physical = yes

	birth = 0.5
	random_creation = 0.5
	
	same_opinion = 10
	
	ruler_designer_cost = -5
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_lisping_desc
			}
			desc = trait_lisping_character_desc
		}
	}

	ai_sociability = low_negative_ai_value
}

stuttering = {
	diplomacy = -2

	#inherit_chance = 15
	genetic = yes
	physical = yes

	birth = 0.5
	random_creation = 0.5
	
	same_opinion = 10
	
	ruler_designer_cost = -5
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_stuttering_desc
			}
			desc = trait_stuttering_character_desc
		}
	}

	ai_sociability = low_negative_ai_value
}

dwarf = {
	prowess = -4
	opposites = {
		giant
	}	

	#inherit_chance = 25
	#both_parent_has_trait_inherit_chance = 100
	genetic = yes
	physical = yes

	enables_inbred = yes
	birth = 0.5
	random_creation = 0.5
	
	attraction_opinion = -20
	same_opinion = 20
	
	ruler_designer_cost = 0

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_dwarf_desc
			}
			desc = trait_dwarf_character_desc
		}
	}
}

giant = {
	opposites = {
		dwarf
	}

	prowess = 6
	health = -0.25

	#inherit_chance = 25
	#both_parent_has_trait_inherit_chance = 50
	genetic = yes
	physical = yes

	enables_inbred = yes
	birth = 0.5
	random_creation = 0.5
	
	attraction_opinion = -5
	tribal_government_opinion = 10
	glory_hound_opinion = 10
	same_opinion = 20
	
	culture_modifier = {
		parameter = strong_traits_more_valued
		monthly_prestige = 0.5
	}
	
	ruler_designer_cost = 20

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_giant_desc
			}
			desc = trait_giant_character_desc
		}
	}
}

inbred = {
	physical = yes
	diplomacy = -5
	martial = -5
	stewardship = -5
	intrigue = -5
	learning = -5
	prowess = -2
	fertility = -0.5
	health = -1.5
	
	inherit_chance = 15
	
	attraction_opinion = -30
	vassal_opinion = -10
	
	ruler_designer_cost = -30
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_inbred_desc
			}
			desc = trait_inbred_character_desc
		}
	}

	flag = initial_legitimacy_nerf

	ai_rationality = -50
	ai_energy = -75
}

weak = {
	opposites = {
		strong
		physique_good
	}
	prowess = -2
	health = -0.5

	physical = yes

	attraction_opinion = -10
	vassal_opinion = -10
	
	culture_modifier = {
		parameter = weak_traits_looked_down_upon
		same_culture_opinion = -15
	}
	
	ruler_designer_cost = -10
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_weak_desc
			}
			desc = trait_weak_character_desc
		}
	}

	ai_energy = -20
}

dull = {
	opposites = {
		intellect_good
		shrewd
	}
	diplomacy = -2
	martial = -2
	stewardship = -2
	intrigue = -2
	learning = -2

	physical = yes
	
	ruler_designer_cost = -20

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_dull_desc
			}
			desc = trait_dull_character_desc
		}
	}

	ai_rationality = high_negative_ai_value

	compatibility = {
		intellect_bad_1 = @pos_compat_medium
		intellect_bad_2 = @pos_compat_medium
		intellect_bad_3 = @pos_compat_medium
		dull = @pos_compat_medium
		intellect_good_1 = @neg_compat_medium
		intellect_good_2 = @neg_compat_medium
		intellect_good_3 = @neg_compat_medium
		shrewd = @neg_compat_medium
	}
}

# Non-genetic impotency
impotent = {
	
	fertility = -0.5
	ai_energy = -10
	physical = yes
	
	shown_in_ruler_designer = no
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_impotent_desc
			}
			desc = trait_impotent_character_desc
		}
	}
}

spindly = { #Marfan's Syndrome
	opposites = {
		physique_good
	}
	prowess = -1
	health = -0.25
	
	#inherit_chance = 100 # dominant
	genetic = yes
	physical = yes
	enables_inbred = yes

	birth = 0.5
	random_creation = 0.5
	
	attraction_opinion = -10
	
	culture_modifier = {
		parameter = weak_traits_looked_down_upon
		same_culture_opinion = -15
	}
	
	ruler_designer_cost = -10
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_spindly_desc
			}
			desc = trait_spindly_character_desc
		}
	}

	ai_energy = -20
}

scaly = {
	fertility = -0.2
	
	#inherit_chance = 100 # dominant
	genetic = yes
	physical = yes
	enables_inbred = yes

	birth = 0.5
	random_creation = 0.5
	
	attraction_opinion = -30
	vassal_opinion = -10
	same_opinion = 10
	
	dread_baseline_add = 10
	
	ruler_designer_cost = 0

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_scaly_desc
			}
			desc = trait_scaly_character_desc
		}
	}
}

albino = {
	
	#inherit_chance = 100 # recessive
	genetic = yes
	physical = yes

	birth = 0.5
	random_creation = 0.5
	
	general_opinion = -10
	same_opinion = 10
	
	dread_baseline_add = 15
	
	ruler_designer_cost = 0

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_albino_desc
			}
			desc = trait_albino_character_desc
		}
	}
}

wheezing = { #asthma
	physical = yes
	health = -0.15
	
	#inherit_chance = 100 # recessive
	genetic = yes
	enables_inbred = yes
	birth = 0.5
	random_creation = 0.5
	
	vassal_opinion = -10
	
	ruler_designer_cost = -10
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_wheezing_desc
			}
			desc = trait_wheezing_character_desc
		}
	}

	ai_energy = -15
}

bleeder = { #Haemophilia
	physical = yes
	health = -1.5
	
	#inherit_chance = 50 # 100 for male, 50 for female, recessive
	genetic = yes
	enables_inbred = yes
	birth = 0.5
	random_creation = 0.5
	
	vassal_opinion = -10
	
	ruler_designer_cost = -20
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_bleeder_desc
			}
			desc = trait_bleeder_character_desc
		}
	}

	ai_energy = -15
}

# Barren (f) / Sterile (m)
infertile = {
	physical = yes
	fertility = -0.5
	opposites = {
		fecund
	}
	
	ruler_designer_cost = 0

	name = {
		first_valid = {
			triggered_desc = {
				trigger = { NOT = { exists = this } }
				desc = trait_infertile_male
			}
			triggered_desc = {
				trigger = { is_female = yes }
				desc = trait_infertile_female
			}
			desc = trait_infertile_male
		}
	}

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = { NOT = { exists = this } }
				desc = trait_infertile_desc
			}
			triggered_desc = {
				trigger = { is_female = yes }
				desc = trait_infertile_female_desc
			}
			desc = trait_infertile_male_desc
		}
	}
	
	#inherit_chance = 50
	genetic = yes
	enables_inbred = yes
	birth = 0.5
	random_creation = 0.5
}

############# RELIGION ############
celibate = {
	category = fame
	opposites = {
		seducer
	}
	can_have_children = no
	monthly_piety = 1
	
	clergy_opinion = 10
	opposite_opinion = -10
	
	shown_in_ruler_designer = no
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_celibate_desc
			}
			desc = trait_celibate_character_desc
		}
	}

	ai_zeal = 30
	ai_sociability = medium_negative_ai_value

	compatibility = {
		chaste = @pos_compat_low
		celibate = @pos_compat_low
		temperate = @pos_compat_low
		calm = @pos_compat_low
		lustful = @neg_compat_low
		deviant = @neg_compat_low
		lovers_pox = @neg_compat_low
		early_great_pox = @neg_compat_low
		great_pox = @neg_compat_low
		seducer = @neg_compat_low
	}
}

pilgrim = {
	category = fame

	character_travel_speed = 5
	character_travel_safety = 5
	
	culture_modifier = {
		parameter = prowess_from_religious_traits
		prowess = 2
	}
	
	faith_modifier = {
		parameter = basic_pilgrimage_rewards
		monthly_piety_gain_mult = 0.05
		zealot_opinion = 5
	}
	
	faith_modifier = {
		parameter = mandatory_pilgrimage
		monthly_piety_gain_mult = 0.35 #offset the -0.25 and add 0.1
		same_faith_opinion = 5
		zealot_opinion = 5
		clergy_opinion = 5
	}
	
	track = {
		50 = {
			culture_modifier = {
				parameter = prowess_from_religious_traits
				prowess = 3
			}
			
			faith_modifier = {
				parameter = basic_pilgrimage_rewards
				monthly_piety_gain_mult = 0.1
				zealot_opinion = 10
				learning = 1
			}
			
			faith_modifier = {
				parameter = mandatory_pilgrimage
				monthly_piety_gain_mult = 0.4 #offset the -0.25 and add 0.15
				zealot_opinion = 20
				clergy_opinion = 10
			}

			ai_zeal = 10
		}
		100 = {
			culture_modifier = {
				parameter = prowess_from_religious_traits
				prowess = 3
			}
			
			faith_modifier = {
				parameter = basic_pilgrimage_rewards
				monthly_piety_gain_mult = 0.1
				zealot_opinion = 20
				different_culture_opinion = 5
				learning = 2
			}
			
			faith_modifier = {
				parameter = mandatory_pilgrimage
				monthly_piety_gain_mult = 0.4 #offset the -0.25 and add 0.15
				zealot_opinion = 40
				clergy_opinion = 10
			}

			ai_zeal = 15
		}
	}

	ruler_designer_cost = 30

	# Loc
	name = {
		first_valid = {
			#Prolific Pilgrim
			triggered_desc = {
				trigger = {
					exists = this
					has_trait_xp = {
						trait = pilgrim
						value >= 100
					}
				}
				desc = trait_pilgrim_3
			}
			#Experienced Pilgrim
			triggered_desc = {
				trigger = { 
					exists = this
					has_trait_xp = {
						trait = pilgrim
						value >= 50
					}
				}
				desc = trait_pilgrim_2
			}
			#Pilgrim
			desc = trait_pilgrim
		}
	}

	# Loc
	desc = {
		first_valid = {
			#The trait can never go higher than the first level if it's not assigned to a character
			triggered_desc = {
				trigger = { 
					NOT = { exists = this } 
				}
				desc = trait_pilgrim_desc
			}
			triggered_desc = {
				trigger = { 
					has_trait_xp = {
						trait = pilgrim
						value >= 100
					}
				}
				desc = trait_pilgrim_3_character_desc
			}
			triggered_desc = {
				trigger = { 
					has_trait_xp = {
						trait = pilgrim
						value >= 50
					}
				}
				desc = trait_pilgrim_2_character_desc
			}
			desc = trait_pilgrim_character_desc
		}
	}

	ai_zeal = 5
}

hajjaj = {
	category = fame
	
	culture_modifier = {
		parameter = prowess_from_religious_traits
		prowess = 2
	}
	
	islam_religion_opinion = 5
	character_travel_speed = 5
	character_travel_safety = 5
	
	faith_modifier = {
		parameter = mandatory_hajj
		monthly_piety_gain_mult = 0.35 #offset the -0.25 and add 0.1
		same_faith_opinion = 5 #offset the -5
		zealot_opinion = 10
	}
	
	ruler_designer_cost = 30

	name = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_hajji
			}
			triggered_desc = {
				trigger = {
					is_male = yes
				}
				desc = trait_hajji
			}
			triggered_desc = {
				trigger = {
					is_female = yes
				}
				desc = trait_hajjah
			}
		}
	}
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_hajjaj_neutral_desc
			}
			desc = trait_hajjaj_desc
		}
	}
	
	ai_zeal = 10
}

excommunicated = {
	category = fame
	monthly_piety_gain_mult = -0.5
	zealot_opinion = -50
	
	shown_in_ruler_designer = no

	triggered_opinion = {
		parameter = excommunication_active
		opinion_modifier = tenet_excommunicated_crime
		same_faith = yes
	}

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_excommunicated_desc
			}
			desc = trait_excommunicated_character_desc
		}
	}
}

# Monk for christian male, Nun for christian female. Devoted for others.
devoted = {
	category = fame
	monthly_piety = 0.3
	
	same_faith_opinion = 5
	
	culture_modifier = {
		parameter = prowess_from_religious_traits
		prowess = 3
	}

	culture_modifier = {
		parameter = devoted_trait_bonuses
		learning = 3
	}
	
	flag = can_not_marry
	inheritance_blocker = all
	
	shown_in_ruler_designer = no

	ai_sociability = very_low_negative_ai_value

	name = {
		first_valid = {
			triggered_desc = {
				trigger = { NOT = { exists = this } }
				desc = trait_devoted_male
			}
			triggered_desc = {
				trigger = {
					is_adult = no
				}
				desc = trait_devoted_child
			}
			triggered_desc = {
				trigger = {
					faith ?= {
						faith:osvicenist.religion ?= religion
					}
					culture ?= { has_cultural_pillar = language_japonic }
					is_female = no
				}
				desc = trait_devoted_buddhism_japanese_male
			}
			triggered_desc = {
				trigger = {
					faith ?= {
						faith:osvicenist.religion ?= religion
					}
					culture ?= { has_cultural_pillar = language_japonic }
					is_female = yes
				}
				desc = trait_devoted_buddhism_japanese_female
			}
			triggered_desc = {
				trigger = {
					exists = faith.religion
					faith.religion = faith:osvicenist.religion
					is_female = no
				}
				desc = trait_devoted_buddhism_male
			}
			triggered_desc = {
				trigger = {
					exists = faith.religion
					faith.religion = faith:osvicenist.religion
					is_female = yes
				}
				desc = trait_devoted_buddhism_female
			}
			triggered_desc = {
				trigger = {
					exists = faith.religion
					faith.religion = faith:vaishnavism.religion
					is_female = no
				}
				desc = trait_devoted_hinduism_male
			}
			triggered_desc = {
				trigger = {
					exists = faith.religion
					faith.religion = faith:vaishnavism.religion
					is_female = yes
				}
				desc = trait_devoted_hinduism_female
			}
			triggered_desc = {
				trigger = {
					exists = faith.religion
					faith.religion = faith:digambara.religion
					is_female = no
				}
				desc = trait_devoted_jainism_male
			}
			triggered_desc = {
				trigger = {
					exists = faith.religion
					faith.religion = faith:digambara.religion
					is_female = yes
				}
				desc = trait_devoted_jainism_female
			}
			triggered_desc = {
				trigger = { is_female = yes }
				desc = trait_devoted_female
			}
			desc = trait_devoted_male
		}
	}

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = { NOT = { exists = this } }
				desc = trait_devoted_desc
			}
			triggered_desc = {
				trigger = { is_adult = no }
				desc = trait_devoted_child_desc
			}
			desc = trait_devoted_character_desc
		}
	}
}

# Muslim version of the Blood of the Prophet-trait. Muslim agnatically descended from Muhammed. Female version is localized 'Sayyida'
sayyid = {
	category = fame
	
	islam_religion_opinion = 5
	flag = initial_legitimacy_boost
	
	ruler_designer_cost = 25
	
	name = {
		first_valid = {
			triggered_desc = {
				trigger = { NOT = { exists = this } }
				desc = trait_sayyid
			}
			triggered_desc = {
				trigger = { is_female = yes }
				desc = trait_sayyida
			}
			desc = trait_sayyid
		}
	}

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = { NOT = { exists = this } }
				desc = trait_sayyid_desc
			}
			desc = trait_sayyid_character_desc
		}
	}

	inherit_chance = 100
	parent_inheritance_sex = male
	inherit_from_real_father = no
}

# Zoroastrian version of the Savior-trait.
saoshyant = {
	category = fame
	opposites = {
		saoshyant_descendant
	}
	diplomacy = 1
	learning = 2
	prowess = 2

	zoroastrianism_religion_opinion = 10
	
	shown_in_ruler_designer = no
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_saoshyant_desc
			}
			desc = trait_saoshyant_character_desc
		}
	}

	ai_zeal = 100
}

# Zoroastrian version of the Divine Blood-trait.
saoshyant_descendant = {
	category = fame
	opposites = {
		saoshyant
	}
	learning = 1

	zoroastrianism_religion_opinion = 5
	
	shown_in_ruler_designer = no
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_saoshyant_descendant_desc
			}
			desc = trait_saoshyant_descendant_character_desc
		}
	}
}

# Generic version of Saoshyant, Mahdi, Messiah, etc.
savior = {
	category = fame
	opposites = {
		divine_blood
	}
	
	same_faith_opinion = 10
	
	shown_in_ruler_designer = no
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_savior_desc
			}
			desc = trait_savior_character_desc
		}
	}

	ai_zeal = 100
}

# Generic version of Descendant of Saoshyant, Mahdi, Messiah, etc. This is automatically granted to all members of a dynasty with "Divine Blood".
divine_blood = {
	category = fame
	opposites = {
		savior
	}
	
	same_faith_opinion = 5
	
	shown_in_ruler_designer = no

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_divine_blood_desc
			}
			desc = trait_divine_blood_character_desc
		}
	}
}

# Generic version of Sayyid. Dynasties can now be marked with "Prophetic Blood", which will automatically grant this trait to all members.
blood_of_prophet = {
	category = fame
	same_faith_opinion = 5
	
	shown_in_ruler_designer = no
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_blood_of_prophet_desc
			}
			desc = trait_blood_of_prophet_character_desc
		}
	}

	# Sayyid has different effects
}

# Generic version of Crusader and Mujahid
faith_warrior = {
	category = fame
	martial = 2
	prowess = 3

	culture_modifier = {
		parameter = faith_warrior_traits_more_valued
		monthly_prestige = 1
	}
	
	clergy_opinion = 15
	same_faith_opinion = 5
	
	ruler_designer_cost = 50

	icon = {
		first_valid = {
			triggered_desc = {
				trigger = { NOT = { exists = this } }
				desc = faith_warrior.dds
			}
			triggered_desc = {
				trigger = { faith = { OR = { religion_tag = eastern_orthodox_religion religion_tag = catholic_religion religion_tag = protestant_religion } } }
				desc = crusader.dds
			}
			triggered_desc = {
				trigger = { faith = { religion_tag = islam_religion } }
				desc = mujahid.dds
			}
			desc = faith_warrior.dds
		}
	}

	name = {
		first_valid = {
			triggered_desc = {
				trigger = { NOT = { exists = this } }
				desc = trait_faith_warrior
			}
			triggered_desc = {
				trigger = { faith = { OR = { religion_tag = eastern_orthodox_religion religion_tag = protestant_religion religion_tag = catholic_religion } } }
				desc = trait_crusader
			}
			triggered_desc = {
				trigger = { faith = { religion_tag = islam_religion } }
				desc = trait_mujahid
			}
#	#		triggered_desc = {
#				trigger = { faith = { religion_tag = bon_religion } }
#				desc = trait_crusader_bon
#	#		}
			triggered_desc = {
				trigger = { faith = { religion_tag = buddhism_religion } }
				desc = trait_crusader_buddhism
			}
#			triggered_desc = {
#				trigger = { faith = { religion_tag = dualism_religion } }
#				desc = trait_crusader_dualism
#			}
			triggered_desc = {
				trigger = { faith = { religion_tag = folkgerman_religion } }
				desc = trait_crusader_germanic
			}
#			triggered_desc = {
#				trigger = { faith = { religion_tag = theomach_religion } }
#				desc = trait_crusader_hellenism
#			}
			triggered_desc = {
				trigger = { faith = { religion_tag = hinduism_religion } }
				desc = trait_crusader_hinduism
			}
			triggered_desc = {
				trigger = { faith = { religion_tag = jainism_religion } }
				desc = trait_crusader_jainism
			}
			triggered_desc = {
				trigger = { faith = { religion_tag = judaism_religion } }
				desc = trait_crusader_judaism
			}
			triggered_desc = {
				trigger = { faith = { religion_tag = hungaric_religion } }
				desc = trait_crusader_magyar
			}
			triggered_desc = {
				trigger = { faith = { religion_tag = baltic_religion } }
				desc = trait_crusader_baltic
			}
			triggered_desc = {
				trigger = { faith = { religion_tag = slavic_religion } }
				desc = trait_crusader_slavic
			}
			triggered_desc = {
				trigger = { faith = { religion_tag = finnic_religion } }
				desc = trait_crusader_finno_ugric
			}
##			triggered_desc = {
##				trigger = { faith = { religion_tag = siberian_religion } }
#				desc = trait_crusader_siberian
#			}
#			triggered_desc = {
#				trigger = { faith = { religion_tag = tengrism_religion } }
#				desc = trait_crusader_tengrism
#			}
#			triggered_desc = {
#				trigger = { faith = { religion_tag = west_african_religion } }
#				desc = trait_crusader_west_african
#			}
#			triggered_desc = {
#				trigger = { faith = { religion_tag = west_african_bori_religion } }
#				desc = trait_crusader_west_african_bori
#			}
#			triggered_desc = {
#				trigger = { faith = { religion_tag = west_african_roog_religion } }
#				desc = trait_crusader_west_african_roog
#			}
			triggered_desc = {
				trigger = { faith = { religion_tag = zoroastrianism_religion } }
				desc = trait_crusader_zoroastrianism
			}
#			triggered_desc = {
#				trigger = { faith = { religion_tag = zunism_religion } }
#				desc = trait_crusader_zunism
#			}

			desc = trait_faith_warrior
		}
	}

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = { NOT = { exists = this } }
				desc = trait_faith_warrior_desc
			}
			triggered_desc = {
				trigger = { faith = { religion_tag = islam_religion } }
				desc = trait_mujahid_character_desc
			}
			triggered_desc = {
				trigger = { faith = { OR = { religion_tag = eastern_orthodox_religion religion_tag = catholic_religion religion_tag = protestant_religion } } }
				desc = trait_crusader_character_desc
			}
			desc = trait_faith_warrior_character_desc
		}
	}
	
	ai_zeal = 10
}

saint = {
	category = fame
	monthly_piety = 2
	legitimacy_gain_mult = 0.25
	
	shown_in_ruler_designer = no
	
	name = {
		first_valid = {
			triggered_desc = {
				trigger = { NOT = { exists = this } }
				desc = trait_venerated_ancestor
			}
			triggered_desc = {
				trigger = { faith = { OR = { religion_tag = eastern_orthodox_religion religion_tag = catholic_religion religion_tag = protestant_religion } } }
				desc = trait_saint
			}
			desc = trait_venerated_ancestor
		}
	}
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_saint_desc
			}
			desc = trait_saint_character_desc
		}
	}

	ai_zeal = 50
}

historical_character = {
	category = fame
	diplomacy = 2
	learning = 2
	enemy_hostile_scheme_success_chance_growth_add = -1
	health = 0.25
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					exists = this
					has_variable = karunakara
				}
				desc = historical_character.karunakara
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = sekkilhar
				}
				desc = historical_character.sekkilhar
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = omar_khayyam
				}
				desc = historical_character.omar_khayyam
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = bhaskaracharya
				}
				desc = historical_character.bhaskaracharya
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = joseph_rabban
				}
				desc = historical_character.joseph_rabban
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = atisha
				}
				desc = historical_character.atisha
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = hemachandra
				}
				desc = historical_character.hemachandra
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = kshemendra
				}
				desc = historical_character.kshemendra
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = akka_mahadevi
				}
				desc = historical_character.akka_mahadevi
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = namdev
				}
				desc = historical_character.namdev
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = madhvacharya
				}
				desc = historical_character.madhvacharya
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = vidyapati
				}
				desc = historical_character.vidyapati
			}


			triggered_desc = {
				trigger = {
					exists = this
					has_variable = abhinavagupta
				}
				desc = historical_character.abhinavagupta
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = basava
				}
				desc = historical_character.basava
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = hildegard
				}
				desc = historical_character.hildegard
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = thomas_aquinas
				}
				desc = historical_character.thomas_aquinas
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = dante_alighieri
				}
				desc = historical_character.dante_alighieri
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = thomas_becket
				}
				desc = historical_character.thomas_becket
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = maimonides
				}
				desc = historical_character.maimonides
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = chretien_de_troyes
				}
				desc = historical_character.chretien_de_troyes
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = egil_skallagrimrsson
				}
				desc = historical_character.egil_skallagrimrsson
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = gunnlaug_ormstunga
				}
				desc = historical_character.gunnlaug_ormstunga
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = torbjorg_the_seeress
				}
				desc = historical_character.torbjorg_the_seeress
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = erik_rode
				}
				desc = historical_character.erik_rode
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = alhazen
				}
				desc = historical_character.alhazen
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = ibn_battuta
				}
				desc = historical_character.ibn_battuta
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = william_of_ockham
				}
				desc = historical_character.william_of_ockham
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = geoffrey_chaucer
				}
				desc = historical_character.geoffrey_chaucer
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = aaron_of_lincoln
				}
				desc = historical_character.aaron_of_lincoln
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = john_wycliffe
				}
				desc = historical_character.john_wycliffe
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = roger_bacon
				}
				desc = historical_character.roger_bacon
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = heloise_dargenteuil
				}
				desc = historical_character.heloise_dargenteuil
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = peter_abelard
				}
				desc = historical_character.peter_abelard
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = petrarch
				}
				desc = historical_character.petrarch
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = christine_pizan
				}
				desc = historical_character.christine_pizan
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = giotto_di_bondone
				}
				desc = historical_character.giotto_di_bondone
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = fibonacci
				}
				desc = historical_character.fibonacci
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = giovanni_boccaccio
				}
				desc = historical_character.giovanni_boccaccio
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = snorri_sturluson
				}
				desc = historical_character.snorri_sturluson
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = hrotsvitha
				}
				desc = historical_character.hrotsvitha
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = ramanuja
				}
				desc = historical_character.ramanuja
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = arnaldus_de_villa_nova
				}
				desc = historical_character.arnaldus_de_villa_nova
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = ibn_khaldun
				}
				desc = historical_character.ibn_khaldun
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = rumi
				}
				desc = historical_character.rumi
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = avicenna
				}
				desc = historical_character.avicenna
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = averroes
				}
				desc = historical_character.averroes
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = al_biruni
				}
				desc = historical_character.al_biruni
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = rashi
				}
				desc = historical_character.rashi
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = yehuda_halevi
				}
				desc = historical_character.yehuda_halevi
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = shaprut
				}
				desc = historical_character.shaprut
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = gersonides
				}
				desc = historical_character.gersonides
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = ezra
				}
				desc = historical_character.ezra
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = gabriol
				}
				desc = historical_character.gabriol
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = nachmanides
				}
				desc = historical_character.nachmanides
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = crescas
				}
				desc = historical_character.crescas
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = saadia
				}
				desc = historical_character.saadia
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = awkal
				}
				desc = historical_character.awkal
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = benjamin_of_tudela
				}
				desc = historical_character.benjamin_of_tudela
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = marco_polo
				}
				desc = historical_character.marco_polo
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = bridget_of_sweden
				}
				desc = historical_character.bridget_of_sweden
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = meister_eckhart
				}
				desc = historical_character.meister_eckhart
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = jangar
				}
				desc = historical_character.jangar
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = zawisza
				}
				desc = historical_character.zawisza
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = theophanes_the_greek
				}
				desc = historical_character.theophanes_the_greek
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = nicetas_choniates
				}
				desc = historical_character.nicetas_choniates
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = michael_psellos
				}
				desc = historical_character.michael_psellos
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = john_tzetzes
				}
				desc = historical_character.john_tzetzes
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = theophylact_of_ohrid
				}
				desc = historical_character.theophylact_of_ohrid
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = eustathius_of_thessalonica
				}
				desc = historical_character.eustathius_of_thessalonica
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = nicephorus_blemmydes
				}
				desc = historical_character.nicephorus_blemmydes
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = georgius_pachymeres
				}
				desc = historical_character.georgius_pachymeres
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = manuel_moschopoulos
				}
				desc = historical_character.manuel_moschopoulos
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = theodore_metochites
				}
				desc = historical_character.theodore_metochites
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = michael_choniates
				}
				desc = historical_character.michael_choniates
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = joseph_tarchaneiotes
				}
				desc = historical_character.joseph_tarchaneiotes
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = gemistus_pletho
				}
				desc = historical_character.gemistus_pletho
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = arethas_of_caesarea
				}
				desc = historical_character.arethas_of_caesarea
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = basil_lekapenos
				}
				desc = historical_character.basil_lekapenos
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = john_the_orphanotrophos
				}
				desc = historical_character.john_the_orphanotrophos
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = samonas
				}
				desc = historical_character.samonas
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = peter_the_eunuch
				}
				desc = historical_character.peter_the_eunuch
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = constantine_the_paphlagonian
				}
				desc = historical_character.constantine_the_paphlagonian
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = peter_the_stratopedarches
				}
				desc = historical_character.peter_the_stratopedarches
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = basilios_bessarion
				}
				desc = historical_character.basilios_bessarion
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = demetrios_kydones
				}
				desc = historical_character.demetrios_kydones
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = manuel_holobolos
				}
				desc = historical_character.manuel_holobolos
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = john_axuch
				}
				desc = historical_character.john_axuch
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = mkhitar_gosh
				}
				desc = historical_character.mkhitar_gosh
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = shota_rustaveli
				}
				desc = historical_character.shota_rustaveli
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = grigor_tatevatsi
				}
				desc = historical_character.grigor_tatevatsi
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = sargis_pitsak
				}
				desc = historical_character.sargis_pitsak
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = medici
				}
				desc = historical_character.medici
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = borgia
				}
				desc = historical_character.borgia
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = william_wallace
				}
				desc = historical_character.william_wallace
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = la_hire
				}
				desc = historical_character.la_hire
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = bar_sauma
				}
				desc = historical_character.bar_sauma
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = hodja
				}
				desc = historical_character.hodja
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = widukind_of_corvey
				}
				desc = historical_character.widukind_of_corvey
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = roger_de_flor
				}
				desc = historical_character.roger_de_flor
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = regino_of_prum
				}
				desc = historical_character.regino_of_prum
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = geoffrey_of_monmouth
				}
				desc = historical_character.geoffrey_of_monmouth
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = raiktor
				}
				desc = historical_character.raiktor
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = nichiren
				}
				desc = historical_character.nichiren
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = dogen
				}
				desc = historical_character.dogen
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = kokan_shiren
				}
				desc = historical_character.kokan_shiren
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = jeong_mong_ju
				}
				desc = historical_character.jeong_mong_ju
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = yi_saek
				}
				desc = historical_character.yi_saek
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = jinul
				}
				desc = historical_character.jinul
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = prapanca
				}
				desc = historical_character.prapanca
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = tantular
				}
				desc = historical_character.tantular
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = kanwa
				}
				desc = historical_character.kanwa
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = sedah
				}
				desc = historical_character.sedah
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = panuluh
				}
				desc = historical_character.panuluh
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = dharmaja
				}
				desc = historical_character.dharmaja
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = monaguna
				}
				desc = historical_character.monaguna
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = kuturan
				}
				desc = historical_character.kuturan
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = dwijendra
				}
				desc = historical_character.dwijendra
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = kavindrarimathana
				}
				desc = historical_character.kavindrarimathana
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = daun_penh
				}
				desc = historical_character.daun_penh
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = yue_fei
				}
				desc = historical_character.yue_fei
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = wen_tianxiang
				}
				desc = historical_character.wen_tianxiang
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = fan_zhongyan
				}
				desc = historical_character.fan_zhongyan
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = li_qingzhao
				}
				desc = historical_character.li_qingzhao
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = qiu_chuji
				}
				desc = historical_character.qiu_chuji
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = chu_van_an
				}
				desc = historical_character.chu_van_an
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = nguyen_thuyen
				}
				desc = historical_character.nguyen_thuyen
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = pham_ngu_lao
				}
				desc = historical_character.pham_ngu_lao
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = sakata_kintoki
				}
				desc = historical_character.sakata_kintoki
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = takezaki_suenaga
				}
				desc = historical_character.takezaki_suenaga
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = eisai
				}
				desc = historical_character.eisai
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = ippen
				}
				desc = historical_character.ippen
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = myoe
				}
				desc = historical_character.myoe
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = honen
				}
				desc = historical_character.honen
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = shinran
				}
				desc = historical_character.shinran
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = mibu_tadamine
				}
				desc = historical_character.mibu_tadamine
			}

			triggered_desc = {
				trigger = {
					exists = this
					has_variable = murasaki
				}
				desc = historical_character.murasaki
			}
			
			desc = generic_importance
		}
	}
	
	shown_in_ruler_designer = no
}

legend = {
	category = fame
	monthly_prestige = 2
	legitimacy_gain_mult = 0.25
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_legend_desc
			}
			desc = trait_legend_character_desc
		}
	}
	
	shown_in_ruler_designer = no

	ai_zeal = 50
}

order_member = {
	category = fame
	flag = can_not_marry
	inheritance_blocker = all

	martial = 1
	prowess = 4

	culture_modifier = {
		parameter = faith_warrior_traits_more_valued
		monthly_prestige = 1
	}

	same_opinion_if_same_faith = 15
	
	shown_in_ruler_designer = no
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_order_member_desc
			}
			desc = trait_order_member_character_desc
		}
	}

	ai_zeal = 10
	ai_honor = 5
	ai_greed = -10
}

########### FAME ##########
berserker = {
	
	category = fame
	diplomacy = -2
	martial = 2
	prowess = 5
	dread_baseline_add = 15
	
	same_opinion = 10
	
	ruler_designer_cost = 40
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_berserker_desc
			}
			desc = trait_berserker_character_desc
		}
	}

	ai_rationality = medium_negative_ai_value
	ai_energy = 20
	ai_boldness = medium_positive_ai_value
}

shieldmaiden = {
	
	category = fame
	martial = 3
	prowess = 3
	
	same_opinion = 10

	ruler_designer_cost = 40
	
	name = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_shieldmaiden_female
			}
			triggered_desc = {
				trigger = { is_male = yes }
				desc = trait_shieldmaiden_male
			}
			desc = trait_shieldmaiden_female
		}
	}
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_shieldmaiden_desc
			}
			triggered_desc = {
				trigger = { is_male = yes }
				desc = trait_shieldmaiden_male_character_desc
			}
			desc = trait_shieldmaiden_female_character_desc
		}
	}

	ai_boldness = high_positive_ai_value
	ai_energy = high_positive_ai_value
}

varangian = {
	category = fame
	diplomacy = 1
	martial = 2
	prowess = 2

	same_opinion = 10
	
	ruler_designer_cost = 40
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_varangian_desc
			}
			desc = trait_varangian_character_desc
		}
	}

	ai_energy = 10
	ai_boldness = 10
}

lifestyle_poet = {
	category = lifestyle
	diplomacy_per_prestige_level = 1
	stress_loss_mult = 0.1
	
	culture_modifier = {
		parameter = poet_trait_gives_bonuses
		monthly_prestige_gain_mult = 0.05
		owned_personal_scheme_success_chance_add = 10
	}
	
	culture_modifier = {
		parameter = poet_trait_romance_bonuses
		attraction_opinion = 15
		courting_scheme_phase_duration_add = minor_scheme_phase_duration_bonus_value
	}

	track = {
		50 = {
			diplomacy = 1
			courtly_opinion = 5
		}
		100 = {
			diplomacy = 2
			courtly_opinion = 5
		}
	}
	
	ruler_designer_cost = 40

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_lifestyle_poet_desc
			}
			desc = trait_lifestyle_poet_character_desc
		}
	}

	ai_boldness = low_positive_ai_value
	ai_sociability = low_positive_ai_value
}

bastard = {
	opposites = {
		legitimized_bastard
		child_of_concubine
		wild_oat
		disputed_heritage
	}
	diplomacy = -1

	same_opinion = 5

	dynasty_opinion = -15

	legitimacy_gain_mult = -0.1

	inheritance_blocker = all
	claim_inheritance_blocker = all

	category = fame
	bastard = illegitimate
	
	ruler_designer_cost = 0
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_bastard_desc
			}
			desc = trait_bastard_character_desc
		}
	}

	ai_honor = -10
	ai_energy = 15
}

legitimized_bastard = {
	opposites = {
		bastard
		child_of_concubine
		wild_oat
		disputed_heritage
	}
	diplomacy = -1
	legitimacy_gain_mult = -0.05
	bastard = legitimate

	dynasty_opinion = -10
	category = fame
	
	ruler_designer_cost = 0
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_legitimized_bastard_desc
			}
			desc = trait_legitimized_bastard_character_desc
		}
	}

	ai_honor = -5
	ai_energy = 15
}

disputed_heritage = {
	category = fame
	opposites = {
		bastard
		wild_oat
		legitimized_bastard
	}

	diplomacy = -1
	legitimacy_loss_mult = 0.1

	dynasty_house_opinion = -10
	
	shown_in_ruler_designer = no
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_disputed_heritage_desc
			}
			desc = trait_disputed_heritage_character_desc
		}
	}

	ai_energy = 10
}

# Separate male and female versions of this traits due to different desc
child_of_concubine_female = {
	category = fame
	group = child_of_concubine
	level = 1
	opposites = {
		bastard
		legitimized_bastard
		wild_oat
	}
	diplomacy = -1
	
	shown_in_ruler_designer = no
	
	name = trait_child_of_concubine
	desc = { # mother was a concubine (at time of birth)
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_child_of_concubine_desc
			}
			desc = trait_child_of_concubine_character_desc
		}
	}
	icon = child_of_concubine.dds

	ai_energy = 15
}

child_of_concubine_male = {
	category = fame
	group = child_of_concubine
	level = 2
	opposites = {
		bastard
		legitimized_bastard
		wild_oat
	}
	diplomacy = -1
	
	shown_in_ruler_designer = no
	
	name = trait_child_of_concubine
	desc = { # father was a concubine (at time of birth)
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_child_of_male_concubine_desc
			}
			desc = trait_child_of_male_concubine_character_desc
		}
	}
	icon = child_of_concubine.dds

	ai_energy = 15
}

#Children born out of wedlock in religions without bastardy
wild_oat = {
	category = fame
	opposites = {
		bastard
		legitimized_bastard
		child_of_concubine
	}
	
	diplomacy = -1
	
	ruler_designer_cost = 0

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_wild_oat_desc
			}
			desc = trait_wild_oat_character_desc
		}
	}
}

bastard_founder = {

	opposites = {
		bastard
		legitimized_bastard
		child_of_concubine
		wild_oat
	}

	inheritance_blocker = all
	claim_inheritance_blocker = all
	category = fame
	diplomacy = -1

	shown_in_ruler_designer = no
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_bastard_founder_desc
			}
			desc = trait_bastard_founder_character_desc
		}
	}

	ai_energy = 15
}

twin = {
	category = fame
	twin_opinion = 15
	
	shown_in_ruler_designer = no

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_twin_desc
			}
			desc = trait_twin_character_desc
		}
	}
}

kinslayer_1 = {

	dynasty_opinion = -5
	category = fame
	group = kinslayer
	level = 1
	
	shown_in_ruler_designer = no
	
	# Criminal for dynasty
	triggered_opinion = {
		parameter = kinslaying_close_kin_crime
		opinion_modifier = kinslayer_crime_dynasty
		same_dynasty = yes
	}

	# Opinion hit for everyone
	triggered_opinion = {
		parameter = kinslaying_close_kin_crime
		opinion_modifier = kinslayer_intolerant
	}
	triggered_opinion = {
		parameter = kinslaying_extended_family_crime
		opinion_modifier = kinslayer_intolerant
	}
	triggered_opinion = {
		parameter = kinslaying_any_dynasty_member_crime
		opinion_modifier = kinslayer_intolerant
	}
	triggered_opinion = {
		parameter = kinslaying_shunned
		opinion_modifier = kinslayer_intolerant
	}

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_kinslayer_1_desc
			}
			desc = trait_kinslayer_1_character_desc
		}
	}
}
kinslayer_2 = {

	dynasty_opinion = -5
	close_relative_opinion = -5
	category = fame
	group = kinslayer
	level = 2
	
	shown_in_ruler_designer = no
	
	# Criminal for extended family
	triggered_opinion = {
		parameter = kinslaying_close_kin_crime
		opinion_modifier = kinslayer_crime_dynasty
		same_dynasty = yes
	}
	triggered_opinion = {
		parameter = kinslaying_extended_family_crime
		opinion_modifier = kinslayer_crime_dynasty
		same_dynasty = yes
	}

	# Opinion hit for everyone
	triggered_opinion = {
		parameter = kinslaying_close_kin_crime
		opinion_modifier = kinslayer_intolerant
	}
	triggered_opinion = {
		parameter = kinslaying_extended_family_crime
		opinion_modifier = kinslayer_intolerant
	}
	triggered_opinion = {
		parameter = kinslaying_any_dynasty_member_crime
		opinion_modifier = kinslayer_intolerant
	}
	triggered_opinion = {
		parameter = kinslaying_shunned
		opinion_modifier = kinslayer_intolerant
	}

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_kinslayer_2_desc
			}
			desc = trait_kinslayer_2_character_desc
		}
	}
}
kinslayer_3 = {

	dynasty_opinion = -5
	close_relative_opinion = -10
	category = fame
	group = kinslayer
	level = 3
	
	shown_in_ruler_designer = no
	
	# Criminal for close family
	triggered_opinion = {
		parameter = kinslaying_close_kin_crime
		opinion_modifier = kinslayer_crime_dynasty
		same_dynasty = yes
	}
	# Criminal for extended family
	triggered_opinion = {
		parameter = kinslaying_extended_family_crime
		opinion_modifier = kinslayer_crime_dynasty
		same_dynasty = yes
	}
	# Criminal for dynasty
	triggered_opinion = {
		parameter = kinslaying_any_dynasty_member_crime
		opinion_modifier = kinslayer_crime_dynasty
		same_dynasty = yes
	}

	# Opinion hit for everyone
	triggered_opinion = {
		parameter = kinslaying_close_kin_crime
		opinion_modifier = kinslayer_intolerant
	}
	triggered_opinion = {
		parameter = kinslaying_extended_family_crime
		opinion_modifier = kinslayer_intolerant
	}
	triggered_opinion = {
		parameter = kinslaying_any_dynasty_member_crime
		opinion_modifier = kinslayer_intolerant
	}
	triggered_opinion = {
		parameter = kinslaying_shunned
		opinion_modifier = kinslayer_intolerant
	}

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_kinslayer_3_desc
			}
			desc = trait_kinslayer_3_character_desc
		}
	}
}

deviant = {
	category = fame
	stress_loss_mult = 0.25
	same_opinion = 35
	
	ruler_designer_cost = -5
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_deviant_desc
			}
			desc = trait_deviant_character_desc
		}
	}

	ai_zeal = -25
	
	triggered_opinion = {
		parameter = deviancy_illegal
		opinion_modifier = deviant_crime
		ignore_opinion_value_if_same_trait = yes
	}
	triggered_opinion = {
		parameter = deviancy_shunned
		opinion_modifier = deviant_intolerant
		ignore_opinion_value_if_same_trait = yes
	}

	compatibility = {
		deviant = @pos_compat_high
		lustful = @pos_compat_medium
		chaste = @neg_compat_medium
		celibate = @neg_compat_medium
	}
}

cannibal = {
	category = fame
	prowess = 2
	
	same_opinion = 35
	
	stress_loss_mult = 0.15
	
	dread_baseline_add = 20
	
	ruler_designer_cost = 40
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_cannibal_desc
			}
			desc = trait_cannibal_character_desc
		}
	}

	ai_rationality = -20
	ai_honor = -10
	ai_compassion = -10
	
	triggered_opinion = {
		parameter = cannibalism_legal
		opinion_modifier = cannibal_crime
		check_missing = yes
		ignore_opinion_value_if_same_trait = yes
	}
}

sodomite = {
	category = fame

	same_opinion = 10
	
	shown_in_ruler_designer = no
	
	triggered_opinion = {
		parameter = homosexuality_illegal
		opinion_modifier = sodomite_crime
		ignore_opinion_value_if_same_trait = yes
	}
	triggered_opinion = {
		parameter = homosexuality_shunned
		opinion_modifier = sodomite_intolerant
		ignore_opinion_value_if_same_trait = yes
	}

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_sodomite_desc
			}
			desc = trait_sodomite_character_desc
		}
	}
}

incestuous = {
	category = fame

	same_opinion = 20
	
	ruler_designer_cost = 0
	
	triggered_opinion = {
		parameter = allows_unrestricted_marriage
		opinion_modifier = incest_intolerant
		check_missing = yes
		ignore_opinion_value_if_same_trait = yes
	}

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_incestuous_desc
			}
			desc = trait_incestuous_character_desc
		}
	}
}

adulterer = {

	same_opinion = 10
	category = fame
	
	ruler_designer_cost = -5
	
	culture_modifier = {
		parameter = adulterer_fornicator_penalties
		same_culture_opinion = -15
	}

	triggered_opinion = {
		parameter = adultery_male_crime
		male_only = yes
		opinion_modifier = adulterer_crime
		ignore_opinion_value_if_same_trait = yes
	}
	triggered_opinion = {
		parameter = adultery_male_shunned
		male_only = yes
		opinion_modifier = adulterer_intolerant
		ignore_opinion_value_if_same_trait = yes
	}
	triggered_opinion = {
		parameter = adultery_female_crime
		female_only = yes
		opinion_modifier = adulterer_crime
		ignore_opinion_value_if_same_trait = yes
	}
	triggered_opinion = {
		parameter = adultery_female_shunned
		female_only = yes
		opinion_modifier = adulterer_intolerant
		ignore_opinion_value_if_same_trait = yes
	}

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_adulterer_desc
			}
			desc = trait_adulterer_character_desc
		}
	}
}

fornicator = {
	category = fame

	same_opinion = 10
	
	ruler_designer_cost = -5
	
	culture_modifier = {
		parameter = adulterer_fornicator_penalties
		same_culture_opinion = -10
	}

	triggered_opinion = {
		parameter = adultery_male_crime
		male_only = yes
		opinion_modifier = fornicator_crime
		ignore_opinion_value_if_same_trait = yes
	}
	triggered_opinion = {
		parameter = adultery_male_shunned
		male_only = yes
		opinion_modifier = fornicator_intolerant
		ignore_opinion_value_if_same_trait = yes
	}
	triggered_opinion = {
		parameter = adultery_female_crime
		female_only = yes
		opinion_modifier = fornicator_crime
		ignore_opinion_value_if_same_trait = yes
	}
	triggered_opinion = {
		parameter = adultery_female_shunned
		female_only = yes
		opinion_modifier = fornicator_intolerant
		ignore_opinion_value_if_same_trait = yes
	}

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_fornicator_desc
			}
			desc = trait_fornicator_character_desc
		}
	}
}

murderer = {

	general_opinion = -15
	category = fame
	
	ruler_designer_cost = -10

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_murderer_desc
			}
			desc = trait_murderer_character_desc
		}
	}
}

born_in_the_purple = {
	monthly_prestige = 0.1
	short_reign_duration_mult = -0.25
	monthly_influence = 0.75

	category = fame
	culture_succession_prio = children_can_be_born_in_the_purple
	flag = initial_legitimacy_boost
	
	ruler_designer_cost = 40
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_born_in_the_purple_desc
			}
			desc = trait_born_in_the_purple_character_desc
		}
	}
}

augustus = {
	
	vassal_opinion = 10
	category = fame
	monthly_prestige = 0.5
	monthly_influence = 1.5
	same_opinion = 25
	
	shown_in_ruler_designer = no

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_augustus_desc
			}
			desc = trait_augustus_character_desc
		}
	}
}

viking = {
	category = fame

	martial = 2
	prowess = 3
	monthly_prestige = 0.3
	
	same_opinion = 5
	
	ruler_designer_cost = 25

	name = {
		first_valid = {
			triggered_desc = {
				trigger = {
					exists = this
					culture = { has_innovation = innovation_longboats }
				}
				desc = trait_viking_has_longships
			}
			desc = trait_viking_fallback
		}
	}
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_viking_desc
			}
			desc = trait_viking_character_desc
		}
	}

	ai_energy = 10
	ai_boldness = 10
}

# Character is seen as a reincarnation of another character.
reincarnation = {
	category = fame

	same_faith_opinion = 5
	monthly_piety = 1
	
	shown_in_ruler_designer = no

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_reincarnation_desc
			}
			desc = trait_reincarnation_desc_ancestor
		}
	}
}

adventurer = {
	category = fame
	
	opposites = {
		adventurer_follower
	}

	general_opinion = -10
	martial_per_prestige_level = 1
	prowess_per_prestige_level = 1
	men_at_arms_maintenance = -0.5
	ignore_negative_culture_opinion = yes
	ignore_negative_opinion_of_culture = yes

	same_opinion = 20
	opposite_opinion = 20
	
	ai_war_chance = 1
	
	ruler_designer_cost = 50
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_adventurer_desc
			}
			desc = trait_adventurer_character_desc
		}
	}

	ai_energy = low_positive_ai_value
	ai_boldness = low_positive_ai_value
	ai_honor = low_negative_ai_value
}

# Just here so you can see who _used_ to be one of your followers.
adventurer_follower = {
	category = fame
	
	opposites = {
		adventurer
	}

	diplomacy = 1
	same_opinion = 20
	opposite_opinion = 20

	ruler_designer_cost = 10
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_adventurer_follower_desc
			}
			triggered_desc = {
				trigger = { has_variable = former_camp_leader }
				desc = trait_adventurer_follower_remembers_leader_desc
			}
			desc = trait_adventurer_follower_character_desc
		}
	}

	ai_energy = low_positive_ai_value
	ai_boldness = low_positive_ai_value
	ai_honor = low_negative_ai_value
}

heresiarch = {
	category = fame
	martial = 2
	learning = 2
	prowess = 2

	same_faith_opinion = 10

	monthly_influence = 0.75
	
	advantage_against_coreligionists = 5
	
	ai_war_chance = 1
	
	ruler_designer_cost = 50
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_heresiarch_desc
			}
			desc = trait_heresiarch_character_desc
		}
	}

	ai_zeal = 20
}

peasant_leader = {
	category = fame

	same_opinion = 25
	general_opinion = -10
	county_opinion_add = 10
	army_maintenance_mult = -0.5
	
	ruler_designer_cost = 100

	culture_modifier = {
		parameter = grants_to_lowborns_bonuses
		development_growth_factor = 0.2
		county_fertility_growth_mult = medium_county_fertility_growth_gain
	}

	track = {
		33 = {
			enemy_terrain_advantage = -0.25
		}
		66 = {
			advantage = 1
			levy_siege = 0.1
		}
		100 = {
			advantage = 2
			county_opinion_add = 20
			ignore_negative_culture_opinion = yes
			ignore_different_faith_opinion = yes
		}
	}
	name = {
		first_valid = {
			triggered_desc = {
				trigger = {
					exists = this
					has_trait_xp = {
						trait = peasant_leader
						value >= 100
					}
				}
				desc = trait_peasant_leader_3
			}
			triggered_desc = {
				trigger = {
					exists = this
					has_trait_xp = {
						trait = peasant_leader
						value >= 66
					}
				}
				desc = trait_peasant_leader_2
			}
			triggered_desc = {
				trigger = {
					exists = this
					has_trait_xp = {
						trait = peasant_leader
						value >= 33
					}
				}
				desc = trait_peasant_leader_1
			}
			desc = trait_peasant_leader
		}
	}
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_peasant_leader_desc
			}
			desc = trait_peasant_leader_character_desc
		}
	}
}

populist_leader = {
	category = fame
	icon = "populist_leader.dds"

	county_opinion_add = 15
	courtly_opinion = -30
	parochial_same_faith_opinion = 10
	parochial_same_culture_opinion = 10
	army_maintenance_mult = -0.5
	
	ruler_designer_cost = 150

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_populist_leader_desc
			}
			desc = trait_populist_leader_character_desc
		}
	}
}

witch = {
	category = fame

	diplomacy = -1
	intrigue = 1
	learning = 1

	same_opinion = 20
	
	ruler_designer_cost = 10
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_witch_desc
			}
			desc = trait_witch_character_desc
		}
	}

	ai_compassion = very_low_negative_ai_value
	ai_boldness = very_low_positive_ai_value
	ai_rationality = very_low_positive_ai_value
	
	triggered_opinion = {
		parameter = witchcraft_illegal
		opinion_modifier = witchcraft_crime
		ignore_opinion_value_if_same_trait = yes
	}
	triggered_opinion = {
		parameter = witchcraft_shunned
		opinion_modifier = witchcraft_intolerant
		ignore_opinion_value_if_same_trait = yes
	}
}

disinherited = {
	category = fame

	inheritance_blocker = dynasty
	
	dynasty_opinion = -5
	
	shown_in_ruler_designer = no
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_disinherited_desc
			}
			desc = trait_disinherited_character_desc
		}
	}
}

denounced = {
	category = fame
	
	diplomacy = -1
	monthly_prestige = -1
	
	shown_in_ruler_designer = no
	
	triggered_opinion = {
		opinion_modifier = denounced_trait_crime
		same_faith = yes
		same_dynasty = yes
	}

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_denounced_desc
			}
			desc = trait_denounced_character_desc
		}
	}
}

decadent = {
	category = fame
	opposites = {
		extolled
	}
	
	dynasty_house_opinion = -15
	same_opinion = 25
	monthly_piety = -1
	stress_gain_mult = 0.25
	owned_hostile_scheme_success_chance_add = 10
	owned_scheme_secrecy_add = 10
	
	shown_in_ruler_designer = no

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_decadent_desc
			}
			desc = trait_decadent_character_desc
		}
	}
}

extolled = {
	category = fame
	opposites = {
		decadent
	}
	
	dynasty_house_opinion = 15
	monthly_piety = 1
	enemy_hostile_scheme_success_chance_add = 25
	
	shown_in_ruler_designer = no

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_extolled_desc
			}
			desc = trait_extolled_character_desc
		}
	}
}

gallivanter = {
	category = fame
	# It's deliberate that this doesn't conflict with disinherit: you can turn it off at any point, which you can't with disinherit, so they're allowed to overlap even if they're redundant when both applied.

	inheritance_blocker = all
	claim_inheritance_blocker = all
	
	stress_gain_mult = -0.1
	stress_loss_mult = 0.1
	
	courtly_opinion = -30
	parochial_opinion = -20
	dynasty_opinion = -10

	flag = cannot_inherit_titles

	shown_in_ruler_designer = no
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_gallivanter_desc
			}
			desc = trait_gallivanter_character_desc
		}
	}
}

loyal = {
	category = fame
	opposites = {
		disloyal
	}
	ruler_designer_cost = 20


	liege_opinion = 15
	diplomacy = 1
	intrigue = -1

	flag = join_factions_less

	same_opinion = 10
	opposite_opinion = -10

	culture_modifier = {
		parameter = loyal_trait_more_valued
		same_culture_opinion = 5
		monthly_prestige = 0.1
	}

	culture_modifier = {
		parameter = palace_politics_trait_bonuses
		monthly_influence = 0.1
	}

	culture_modifier = {
		parameter = scholar_official_trait_bonuses
		monthly_merit_mult = 0.1
		same_culture_opinion = 5
	}

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_loyal_desc
			}
			desc = trait_loyal_character_desc
		}
	}

	compatibility = {

	}
}

disloyal = {
	category = fame
	opposites = {
		loyal
	}
	ruler_designer_cost = -20

	diplomacy = -1
	intrigue = 1
	liege_opinion = -15

	flag = join_factions_more

	ai_honor = -20

	same_opinion = 10
	opposite_opinion = -10

	culture_modifier = {
		parameter = disloyal_trait_less_spurned
		same_culture_opinion = 5
	}

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_disloyal_desc
			}
			desc = trait_disloyal_character_desc
		}
	}

	compatibility = {

	}
}

# A note on usage: gallowsbait is for criminals who fall outside of the ruling class or their associates.
## A courtier murders someone? Not gallowsbait.
## A baron murders someone? Not gallowsbait.
## A pool character mugs someone? That's gallowsbait.
## An adventurer steals the silverware at dinner? That's gallowsbait.
### It's for the low class, the under-class, and the outsider, *not* for anyone without a duchy to their name.
gallowsbait = {
	category = fame
	
	ai_honor = -20
	ai_energy = 20
	legitimacy_gain_mult = -0.25
	legitimacy_loss_mult = 0.25

	same_opinion = 50
	
	culture_modifier = {
		parameter = banditry_gives_bonuses
		same_culture_opinion = 10
		legitimacy_gain_mult = 0.25
		legitimacy_loss_mult = -0.25
	}
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_gallowsbait_desc
			}
			desc = trait_gallowsbait_character_desc
		}
	}

	tracks = {
		# Brigandry, highway robbery, etc.
		bandit = {
			20 = {
				barons_and_minor_landholders_opinion = -5
				general_opinion = -2
				courtier_and_guest_opinion = 2
				martial = 1
				culture_modifier = {
					parameter = banditry_gives_bonuses
					same_culture_opinion = 2
					prowess = 1
					hills_advantage = 1
					mountains_advantage = 1
					monthly_prestige_gain_mult = 0.01
				}
			}
			40 = {
				barons_and_minor_landholders_opinion = -5
				general_opinion = -2
				courtier_and_guest_opinion = 2
				culture_modifier = {
					parameter = banditry_gives_bonuses
					same_culture_opinion = 2
					hills_advantage = 1
					mountains_advantage = 1
					monthly_prestige_gain_mult = 0.01
				}
			}
			60 = {
				barons_and_minor_landholders_opinion = -5
				general_opinion = -2
				courtier_and_guest_opinion = 2
				martial = 1
				culture_modifier = {
					parameter = banditry_gives_bonuses
					same_culture_opinion = 2
					hills_advantage = 1
					mountains_advantage = 1
					monthly_prestige_gain_mult = 0.01
				}
			}
			80 = {
				barons_and_minor_landholders_opinion = -5
				general_opinion = -5
				courtier_and_guest_opinion = 5
				monthly_prestige_gain_per_dread_add = 0.01
				culture_modifier = {
					parameter = banditry_gives_bonuses
					same_culture_opinion = 2
					hills_advantage = 1
					mountains_advantage = 1
					monthly_prestige_gain_mult = 0.01
				}
			}
			100 = {
				barons_and_minor_landholders_opinion = -10
				general_opinion = -10
				courtier_and_guest_opinion = 10
				monthly_prestige_gain_per_dread_add = 0.01
				culture_modifier = {
					parameter = banditry_gives_bonuses
					same_culture_opinion = 2
					prowess = 1
					hills_advantage = 1
					mountains_advantage = 1
					monthly_prestige_gain_mult = 0.01
				}
			}
		}
		# Con artistry, huckstering, etc.
		trickster = {
			20 = {
				courtly_opinion = -5
				general_opinion = -2
				courtier_and_guest_opinion = 2
				diplomacy = 1
			}
			40 = {
				courtly_opinion = -5
				general_opinion = -2
				courtier_and_guest_opinion = 2
			}
			60 = {
				courtly_opinion = -5
				general_opinion = -2
				courtier_and_guest_opinion = 2
				diplomacy = 1
			}
			80 = {
				courtly_opinion = -5
				general_opinion = -5
				courtier_and_guest_opinion = 5
			}
			100 = {
				courtly_opinion = -10
				general_opinion = -10
				courtier_and_guest_opinion = 10
				diplomacy_per_prestige_level = 1
			}
		}
		# Petty theft, heists, etc.
		thief = {
			20 = {
				parochial_opinion = -5
				general_opinion = -2
				courtier_and_guest_opinion = 2
				intrigue = 1
			}
			40 = {
				parochial_opinion = -5
				general_opinion = -2
				courtier_and_guest_opinion = 2
			}
			60 = {
				parochial_opinion = -5
				general_opinion = -2
				courtier_and_guest_opinion = 2
				intrigue = 1
				owned_scheme_secrecy_add = 5
			}
			80 = {
				parochial_opinion = -5
				general_opinion = -5
				courtier_and_guest_opinion = 5
				owned_scheme_secrecy_add = 5
			}
			100 = {
				parochial_opinion = -10
				general_opinion = -10
				courtier_and_guest_opinion = 10
				owned_scheme_secrecy_add = 10
			}
		}
		# Rustling, horse theft, straight-up poaching, etc.
		poacher = {
			20 = {
				glory_hound_opinion = -5
				general_opinion = -2
				courtier_and_guest_opinion = 2
				stewardship = 1
				provisions_gain_mult = 0.05
			}
			40 = {
				glory_hound_opinion = -5
				general_opinion = -2
				courtier_and_guest_opinion = 2
				provisions_gain_mult = 0.05
			}
			60 = {
				glory_hound_opinion = -5
				general_opinion = -2
				courtier_and_guest_opinion = 2
				stewardship = 1
				provisions_gain_mult = 0.05
			}
			80 = {
				glory_hound_opinion = -5
				general_opinion = -5
				courtier_and_guest_opinion = 5
			}
			100 = {
				glory_hound_opinion = -10
				general_opinion = -10
				courtier_and_guest_opinion = 10
			}
		}
		# Kidnapping, murder, etc.
		marauder = {
			20 = {
				general_opinion = -4
				courtier_and_guest_opinion = 4
				prowess = 1
			}
			40 = {
				general_opinion = -4
				courtier_and_guest_opinion = 4
			}
			60 = {
				general_opinion = -4
				courtier_and_guest_opinion = 4
				prowess = 1
			}
			80 = {
				general_opinion = -10
				courtier_and_guest_opinion = 10
			}
			100 = {
				general_opinion = -20
				courtier_and_guest_opinion = 20
				max_murder_schemes_add = 1
			}
		}
	}
}

############### COMBAT ##############
logistician = {
	
	category = commander
	flag = commander_trait_flag
	
	supply_duration = 0.4
	character_travel_safety = 4
	
	culture_modifier = {
		parameter = winter_trait_bonuses
		winter_movement_speed = 0.1
	}
	
	culture_modifier = {
		parameter = forest_trait_bonuses
		forest_attrition_mult = -0.1
		taiga_attrition_mult = -0.1
	}
	
	culture_modifier = {
		parameter = jungle_trait_bonuses
		jungle_attrition_mult = -0.1
	}
	
	culture_modifier = {
		parameter = mountain_trait_bonuses
		mountains_attrition_mult= -0.15
		desert_mountains_attrition_mult = -0.15
	}
	
	culture_modifier = {
		parameter = dry_trait_bonuses
		drylands_attrition_mult = -0.1
		desert_attrition_mult = -0.1
	}

	track = {
		33 = {
			character_travel_safety = 4
			supply_duration = 0.4
			culture_modifier = {
				parameter = winter_trait_bonuses
				winter_movement_speed = 0.1
			}
			culture_modifier = {
				parameter = forest_trait_bonuses
				forest_attrition_mult = -0.1
				taiga_attrition_mult = -0.1
			}
			culture_modifier = {
				parameter = jungle_trait_bonuses
				jungle_attrition_mult = -0.1
			}
			culture_modifier = {
				parameter = mountain_trait_bonuses
				mountains_attrition_mult= -0.15
				desert_mountains_attrition_mult = -0.15
			}
			culture_modifier = {
				parameter = dry_trait_bonuses
				drylands_attrition_mult = -0.1
				desert_attrition_mult = -0.1
			}
		}
		66 = {
			advantage = 1
			character_travel_safety = 4
			supply_duration = 0.4
			culture_modifier = {
				parameter = winter_trait_bonuses
				winter_movement_speed = 0.1
			}
			culture_modifier = {
				parameter = forest_trait_bonuses
				forest_attrition_mult = -0.1
				taiga_attrition_mult = -0.1
			}
			culture_modifier = {
				parameter = jungle_trait_bonuses
				jungle_attrition_mult = -0.1
			}
			culture_modifier = {
				parameter = mountain_trait_bonuses
				mountains_attrition_mult= -0.15
				desert_mountains_attrition_mult = -0.15
			}
			culture_modifier = {
				parameter = dry_trait_bonuses
				drylands_attrition_mult = -0.1
				desert_attrition_mult = -0.1
			}
		}
		100 = {
			advantage = 2
			martial = 1
			character_travel_safety = 4
			supply_duration = 0.4
			culture_modifier = {
				parameter = winter_trait_bonuses
				winter_movement_speed = 0.1
			}
			culture_modifier = {
				parameter = forest_trait_bonuses
				forest_attrition_mult = -0.1
				taiga_attrition_mult = -0.1
			}
			culture_modifier = {
				parameter = jungle_trait_bonuses
				jungle_attrition_mult = -0.1
			}
			culture_modifier = {
				parameter = mountain_trait_bonuses
				mountains_attrition_mult= -0.15
				desert_mountains_attrition_mult = -0.15
			}
			culture_modifier = {
				parameter = dry_trait_bonuses
				drylands_attrition_mult = -0.1
				desert_attrition_mult = -0.1
			}
		}
	}
	
	ruler_designer_cost = 25

	name = {
		first_valid = {
			triggered_desc = {
				trigger = {
					exists = this
					has_trait_xp = {
						trait = logistician
						value >= 100
					}
				}
				desc = trait_logistician_3
			}
			triggered_desc = {
				trigger = {
					exists = this
					has_trait_xp = {
						trait = logistician
						value >= 66
					}
				}
				desc = trait_logistician_2
			}
			triggered_desc = {
				trigger = {
					exists = this
					has_trait_xp = {
						trait = logistician
						value >= 33
					}
				}
				desc = trait_logistician_1
			}
			desc = trait_logistician
		}
	}

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_logistician_desc
			}
			desc = trait_logistician_character_desc
		}
	}
}

military_engineer = {
	
	category = commander
	flag = commander_trait_flag
	
	siege_phase_time = -0.1
	
	ruler_designer_cost = 25
	
	culture_modifier = {
		parameter = mountain_trait_bonuses
		mountains_attrition_mult= -0.1
		desert_mountains_attrition_mult = -0.1
	}
	
	culture_modifier = {
		parameter = hill_trait_bonuses
		hills_attrition_mult = -0.1
	}

	track = {
		33 = {
			siege_phase_time = -0.1
			culture_modifier = {
				parameter = mountain_trait_bonuses
				mountains_attrition_mult= -0.1
				desert_mountains_attrition_mult = -0.1
			}
			culture_modifier = {
				parameter = hill_trait_bonuses
				hills_attrition_mult = -0.1
			}
		}
		66 = {
			advantage = 1
			siege_phase_time = -0.1
			culture_modifier = {
				parameter = mountain_trait_bonuses
				mountains_attrition_mult= -0.1
				desert_mountains_attrition_mult = -0.1
			}
			culture_modifier = {
				parameter = hill_trait_bonuses
				hills_attrition_mult = -0.1
			}
		}
		100 = {
			advantage = 2
			martial = 1
			siege_phase_time = -0.1
			culture_modifier = {
				parameter = mountain_trait_bonuses
				mountains_attrition_mult= -0.1
				desert_mountains_attrition_mult = -0.1
			}
			culture_modifier = {
				parameter = hill_trait_bonuses
				hills_attrition_mult = -0.1
			}
		}
	}

	name = {
		first_valid = {
			triggered_desc = {
				trigger = {
					exists = this
					has_trait_xp = {
						trait = military_engineer
						value >= 100
					}
				}
				desc = trait_military_engineer_3
			}
			triggered_desc = {
				trigger = {
					exists = this
					has_trait_xp = {
						trait = military_engineer
						value >= 66
					}
				}
				desc = trait_military_engineer_2
			}
			triggered_desc = {
				trigger = {
					exists = this
					has_trait_xp = {
						trait = military_engineer
						value >= 33
					}
				}
				desc = trait_military_engineer_1
			}
			desc = trait_military_engineer
		}
	}

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_military_engineer_desc
			}
			desc = trait_military_engineer_character_desc
		}
	}
}

aggressive_attacker = {
	
	category = commander
	flag = commander_trait_flag
	
	#attacker_advantage = 10
	enemy_hard_casualty_modifier = 0.1
	
	culture_modifier = {
		parameter = winter_trait_bonuses
		winter_advantage = 1
	}
	
	culture_modifier = {
		parameter = forest_trait_bonuses
		forest_max_combat_roll = 1
		taiga_max_combat_roll = 1
	}
	
	culture_modifier = {
		parameter = jungle_trait_bonuses
		jungle_max_combat_roll = 1
	}
	
	culture_modifier = {
		parameter = dry_trait_bonuses
		drylands_max_combat_roll = 1
		desert_max_combat_roll = 1
	}
	
	culture_modifier = {
		parameter = hill_trait_bonuses
		hills_max_combat_roll = 1
	}
	
	ruler_designer_cost = 25

	track = {
		33 = {
			enemy_hard_casualty_modifier = 0.1
			culture_modifier = {
				parameter = winter_trait_bonuses
				winter_advantage = 1
			}
			culture_modifier = {
				parameter = forest_trait_bonuses
				forest_max_combat_roll = 1
				taiga_max_combat_roll = 1
			}
			culture_modifier = {
				parameter = jungle_trait_bonuses
				jungle_max_combat_roll = 1
			}
			culture_modifier = {
				parameter = dry_trait_bonuses
				drylands_max_combat_roll = 1
				desert_max_combat_roll = 1
			}
			culture_modifier = {
				parameter = hill_trait_bonuses
				hills_max_combat_roll = 1
			}
		}
		66 = {
			advantage = 1
			enemy_hard_casualty_modifier = 0.1
			culture_modifier = {
				parameter = winter_trait_bonuses
				winter_advantage = 1
			}
			culture_modifier = {
				parameter = forest_trait_bonuses
				forest_max_combat_roll = 1
				taiga_max_combat_roll = 1
			}
			culture_modifier = {
				parameter = jungle_trait_bonuses
				jungle_max_combat_roll = 1
			}
			culture_modifier = {
				parameter = dry_trait_bonuses
				drylands_max_combat_roll = 1
				desert_max_combat_roll = 1
			}
			culture_modifier = {
				parameter = hill_trait_bonuses
				hills_max_combat_roll = 1
			}
		}
		100 = {
			advantage = 2
			martial = 1
			enemy_hard_casualty_modifier = 0.1
			culture_modifier = {
				parameter = winter_trait_bonuses
				winter_advantage = 1
			}
			culture_modifier = {
				parameter = forest_trait_bonuses
				forest_max_combat_roll = 1
				taiga_max_combat_roll = 1
			}
			culture_modifier = {
				parameter = jungle_trait_bonuses
				jungle_max_combat_roll = 1
			}
			culture_modifier = {
				parameter = dry_trait_bonuses
				drylands_max_combat_roll = 1
				desert_max_combat_roll = 1
			}
			culture_modifier = {
				parameter = hill_trait_bonuses
				hills_max_combat_roll = 1
			}
		}
	}

	name = {
		first_valid = {
			triggered_desc = {
				trigger = {
					exists = this
					has_trait_xp = {
						trait = aggressive_attacker
						value >= 100
					}
				}
				desc = trait_aggressive_attacker_3
			}
			triggered_desc = {
				trigger = {
					exists = this
					has_trait_xp = {
						trait = aggressive_attacker
						value >= 66
					}
				}
				desc = trait_aggressive_attacker_2
			}
			triggered_desc = {
				trigger = {
					exists = this
					has_trait_xp = {
						trait = aggressive_attacker
						value >= 33
					}
				}
				desc = trait_aggressive_attacker_1
			}
			desc = trait_aggressive_attacker
		}
	}

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_aggressive_attacker_desc
			}
			desc = trait_aggressive_attacker_character_desc
		}
	}
}

unyielding_defender = {
	
	category = commander
	flag = commander_trait_flag
	
	#defender_advantage = 10
	hard_casualty_modifier = -0.1
	
	culture_modifier = {
		parameter = winter_trait_bonuses
		winter_advantage = 1
	}
	
	culture_modifier = {
		parameter = forest_trait_bonuses
		forest_min_combat_roll = 1
		taiga_min_combat_roll = 1
	}
	
	culture_modifier = {
		parameter = jungle_trait_bonuses
		jungle_min_combat_roll = 1
	}
	
	culture_modifier = {
		parameter = mountain_trait_bonuses
		mountains_advantage = 1
		desert_mountains_advantage = 1
	}
	
	culture_modifier = {
		parameter = dry_trait_bonuses
		drylands_min_combat_roll = 1
		desert_min_combat_roll = 1
	}
	
	culture_modifier = {
		parameter = hill_trait_bonuses
		hills_min_combat_roll = 1
	}
	
	ruler_designer_cost = 25

	track = {
		33 = {
			hard_casualty_modifier = -0.1
			culture_modifier = {
				parameter = winter_trait_bonuses
				winter_advantage = 1
			}
			culture_modifier = {
				parameter = forest_trait_bonuses
				forest_min_combat_roll = 1
				taiga_min_combat_roll = 1
			}
			culture_modifier = {
				parameter = jungle_trait_bonuses
				jungle_min_combat_roll = 1
			}
			culture_modifier = {
				parameter = mountain_trait_bonuses
				mountains_advantage = 1
				desert_mountains_advantage = 1
			}
			culture_modifier = {
				parameter = dry_trait_bonuses
				drylands_min_combat_roll = 1
				desert_min_combat_roll = 1
			}
			culture_modifier = {
				parameter = hill_trait_bonuses
				hills_min_combat_roll = 1
			}
		}
		66 = {
			advantage = 1
			hard_casualty_modifier = -0.1
			culture_modifier = {
				parameter = winter_trait_bonuses
				winter_advantage = 1
			}
			culture_modifier = {
				parameter = forest_trait_bonuses
				forest_min_combat_roll = 1
				taiga_min_combat_roll = 1
			}
			culture_modifier = {
				parameter = jungle_trait_bonuses
				jungle_min_combat_roll = 1
			}
			culture_modifier = {
				parameter = mountain_trait_bonuses
				mountains_advantage = 1
				desert_mountains_advantage = 1
			}
			culture_modifier = {
				parameter = dry_trait_bonuses
				drylands_min_combat_roll = 1
				desert_min_combat_roll = 1
			}
			culture_modifier = {
				parameter = hill_trait_bonuses
				hills_min_combat_roll = 1
			}
		}
		100 = {
			advantage = 2
			martial = 1
			hard_casualty_modifier = -0.1
			culture_modifier = {
				parameter = winter_trait_bonuses
				winter_advantage = 1
			}
			culture_modifier = {
				parameter = forest_trait_bonuses
				forest_min_combat_roll = 1
				taiga_min_combat_roll = 1
			}
			culture_modifier = {
				parameter = jungle_trait_bonuses
				jungle_min_combat_roll = 1
			}
			culture_modifier = {
				parameter = mountain_trait_bonuses
				mountains_advantage = 1
				desert_mountains_advantage = 1
			}
			culture_modifier = {
				parameter = dry_trait_bonuses
				drylands_min_combat_roll = 1
				desert_min_combat_roll = 1
			}
			culture_modifier = {
				parameter = hill_trait_bonuses
				hills_min_combat_roll = 1
			}
		}
	}

	name = {
		first_valid = {
			triggered_desc = {
				trigger = {
					exists = this
					has_trait_xp = {
						trait = unyielding_defender
						value >= 100
					}
				}
				desc = trait_unyielding_defender_3
			}
			triggered_desc = {
				trigger = {
					exists = this
					has_trait_xp = {
						trait = unyielding_defender
						value >= 66
					}
				}
				desc = trait_unyielding_defender_2
			}
			triggered_desc = {
				trigger = {
					exists = this
					has_trait_xp = {
						trait = unyielding_defender
						value >= 33
					}
				}
				desc = trait_unyielding_defender_1
			}
			desc = trait_unyielding_defender
		}
	}

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_unyielding_defender_desc
			}
			desc = trait_unyielding_defender_character_desc
		}
	}
}

forder = {
	
	category = commander
	flag = commander_trait_flag
	
	no_water_crossing_penalty = yes
	
	character_travel_speed = 5
	
	ruler_designer_cost = 25

	track = {
		33 = {
			character_travel_speed = 5
			coastal_advantage = 1
		}
		66 = {
			advantage = 1
			character_travel_speed = 5
			coastal_advantage = 1
		}
		100 = {
			advantage = 2
			martial = 1
			character_travel_speed = 5
			coastal_advantage = 1
		}
	}

	name = {
		first_valid = {
			triggered_desc = {
				trigger = {
					exists = this
					has_trait_xp = {
						trait = forder
						value >= 100
					}
				}
				desc = trait_forder_3
			}
			triggered_desc = {
				trigger = {
					exists = this
					has_trait_xp = {
						trait = forder
						value >= 66
					}
				}
				desc = trait_forder_2
			}
			triggered_desc = {
				trigger = {
					exists = this
					has_trait_xp = {
						trait = forder
						value >= 33
					}
				}
				desc = trait_forder_1
			}
			desc = trait_forder
		}
	}

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_forder_desc
			}
			desc = trait_forder_character_desc
		}
	}
}

flexible_leader = {
	
	category = commander
	flag = commander_trait_flag
	
	enemy_terrain_advantage = -0.2
	
	culture_modifier = {
		parameter = mountain_trait_bonuses
		mountains_min_combat_roll = 1
		desert_mountains_min_combat_roll = 1
	}
	
	culture_modifier = {
		parameter = hill_trait_bonuses
		hills_max_combat_roll = 1
	}
	
	ruler_designer_cost = 25

	track = {
		33 = {
			enemy_terrain_advantage = -0.2
			culture_modifier = {
				parameter = mountain_trait_bonuses
				mountains_min_combat_roll = 1
				desert_mountains_min_combat_roll = 1
			}
			culture_modifier = {
				parameter = hill_trait_bonuses
				hills_max_combat_roll = 1
			}
		}
		66 = {
			advantage = 1
			enemy_terrain_advantage = -0.2
			culture_modifier = {
				parameter = mountain_trait_bonuses
				mountains_min_combat_roll = 1
				desert_mountains_min_combat_roll = 1
			}
			culture_modifier = {
				parameter = hill_trait_bonuses
				hills_max_combat_roll = 1
			}
		}
		100 = {
			advantage = 2
			martial = 1
			enemy_terrain_advantage = -0.2
			culture_modifier = {
				parameter = mountain_trait_bonuses
				mountains_min_combat_roll = 1
				desert_mountains_min_combat_roll = 1
			}
			culture_modifier = {
				parameter = hill_trait_bonuses
				hills_max_combat_roll = 1
			}
		}
	}

	name = {
		first_valid = {
			triggered_desc = {
				trigger = {
					exists = this
					has_trait_xp = {
						trait = flexible_leader
						value >= 100
					}
				}
				desc = trait_flexible_leader_3
			}
			triggered_desc = {
				trigger = {
					exists = this
					has_trait_xp = {
						trait = flexible_leader
						value >= 66
					}
				}
				desc = trait_flexible_leader_2
			}
			triggered_desc = {
				trigger = {
					exists = this
					has_trait_xp = {
						trait = flexible_leader
						value >= 33
					}
				}
				desc = trait_flexible_leader_1
			}
			desc = trait_flexible_leader
		}
	}

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_flexible_leader_desc
			}
			desc = trait_flexible_leader_character_desc
		}
	}
}

desert_warrior = {
	
	category = commander
	flag = commander_trait_flag
	
	drylands_advantage = 2
	desert_advantage = 2
	desert_mountains_advantage = 2
	oasis_advantage = 2
	
	desert_cancel_negative_supply = yes
	#desert_mountains_cancel_negative_supply = yes
	#oasis_cancel_negative_supply = yes
	
	#desert_attrition_mult = -0.5
	#desert_mountains_attrition_mult = -0.5
	#oasis_attrition_mult = -0.5
	
	#desert_min_combat_roll = 1
	#desert_max_combat_roll = 5
	
	culture_modifier = {
		parameter = desert_warrior_trait_is_better
		camel_cavalry_damage_mult = 0.1
		camel_cavalry_screen_mult = 0.05
	}
	
	ruler_designer_cost = 25

	track = {
		33 = {
			drylands_advantage = 2
			desert_advantage = 2
			desert_mountains_advantage = 2
			oasis_advantage = 2
			culture_modifier = {
				parameter = desert_warrior_trait_is_better
				camel_cavalry_damage_mult = 0.1
				camel_cavalry_screen_mult = 0.05
			}
		}
		66 = {
			advantage = 1
			drylands_advantage = 2
			desert_advantage = 2
			desert_mountains_advantage = 2
			oasis_advantage = 2
			culture_modifier = {
				parameter = desert_warrior_trait_is_better
				camel_cavalry_damage_mult = 0.1
				camel_cavalry_screen_mult = 0.05
			}
		}
		100 = {
			advantage = 2
			martial = 1
			drylands_advantage = 2
			desert_advantage = 2
			desert_mountains_advantage = 2
			oasis_advantage = 2
			culture_modifier = {
				parameter = desert_warrior_trait_is_better
				camel_cavalry_damage_mult = 0.1
				camel_cavalry_screen_mult = 0.05
			}
		}
	}

	trait_exclusive_if_realm_contains = {
		drylands
		desert
		desert_mountains
		oasis
	}

	name = {
		first_valid = {
			triggered_desc = {
				trigger = {
					exists = this
					has_trait_xp = {
						trait = desert_warrior
						value >= 100
					}
				}
				desc = trait_desert_warrior_3
			}
			triggered_desc = {
				trigger = {
					exists = this
					has_trait_xp = {
						trait = desert_warrior
						value >= 66
					}
				}
				desc = trait_desert_warrior_2
			}
			triggered_desc = {
				trigger = {
					exists = this
					has_trait_xp = {
						trait = desert_warrior
						value >= 33
					}
				}
				desc = trait_desert_warrior_1
			}
			desc = trait_desert_warrior
		}
	}

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_desert_warrior_desc
			}
			desc = trait_desert_warrior_character_desc
		}
	}
}

jungle_stalker = {
	
	category = commander
	flag = commander_trait_flag
	
	jungle_cancel_negative_supply = yes
	jungle_advantage = 2
	jungle_attrition_mult = -0.2
	
	culture_modifier = {
		parameter = jungle_trait_bonuses
		jungle_min_combat_roll = 1
	}
	
	ruler_designer_cost = 25

	track = {
		33 = {
			jungle_advantage = 2
			jungle_attrition_mult = -0.2
			culture_modifier = {
				parameter = jungle_trait_bonuses
				jungle_min_combat_roll = 1
			}
		}
		66 = {
			advantage = 1
			jungle_advantage = 2
			jungle_attrition_mult = -0.2
			culture_modifier = {
				parameter = jungle_trait_bonuses
				jungle_min_combat_roll = 1
			}
		}
		100 = {
			advantage = 2
			martial = 1
			jungle_advantage = 2
			jungle_attrition_mult = -0.2
			culture_modifier = {
				parameter = jungle_trait_bonuses
				jungle_min_combat_roll = 1
			}
		}
	}

	trait_exclusive_if_realm_contains = {
		jungle
	}

	name = {
		first_valid = {
			triggered_desc = {
				trigger = {
					exists = this
					has_trait_xp = {
						trait = jungle_stalker
						value >= 100
					}
				}
				desc = trait_jungle_stalker_3
			}
			triggered_desc = {
				trigger = {
					exists = this
					has_trait_xp = {
						trait = jungle_stalker
						value >= 66
					}
				}
				desc = trait_jungle_stalker_2
			}
			triggered_desc = {
				trigger = {
					exists = this
					has_trait_xp = {
						trait = jungle_stalker
						value >= 33
					}
				}
				desc = trait_jungle_stalker_1
			}
			desc = trait_jungle_stalker
		}
	}

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_jungle_stalker_desc
			}
			desc = trait_jungle_stalker_character_desc
		}
	}
}

reaver = {
	
	category = commander
	flag = commander_trait_flag
	
	raid_speed = 0.4
	hostile_county_attrition = -0.3
	
	culture_modifier = {
		parameter = winter_trait_bonuses
		winter_advantage = 2
	}
	
	culture_modifier = {
		parameter = dry_trait_bonuses
		drylands_max_combat_roll = 1
		desert_max_combat_roll = 1
	}
	
	ruler_designer_cost = 25

	track = {
		33 = {
			raid_speed = 0.4
			hostile_county_attrition = -0.3
			culture_modifier = {
				parameter = winter_trait_bonuses
				winter_advantage = 2
			}
			culture_modifier = {
				parameter = dry_trait_bonuses
				drylands_max_combat_roll = 1
				desert_max_combat_roll = 1
			}
		}
		66 = {
			advantage = 1
			raid_speed = 0.4
			hostile_county_attrition = -0.3
			culture_modifier = {
				parameter = winter_trait_bonuses
				winter_advantage = 2
			}
			culture_modifier = {
				parameter = dry_trait_bonuses
				drylands_max_combat_roll = 1
				desert_max_combat_roll = 1
			}
		}
		100 = {
			advantage = 2
			martial = 1
			raid_speed = 0.4
			hostile_county_attrition = -0.3
			culture_modifier = {
				parameter = winter_trait_bonuses
				winter_advantage = 2
			}
			culture_modifier = {
				parameter = dry_trait_bonuses
				drylands_max_combat_roll = 1
				desert_max_combat_roll = 1
			}
		}
	}

	name = {
		first_valid = {
			triggered_desc = {
				trigger = {
					exists = this
					has_trait_xp = {
						trait = reaver
						value >= 100
					}
				}
				desc = trait_reaver_3
			}
			triggered_desc = {
				trigger = {
					exists = this
					has_trait_xp = {
						trait = reaver
						value >= 66
					}
				}
				desc = trait_reaver_2
			}
			triggered_desc = {
				trigger = {
					exists = this
					has_trait_xp = {
						trait = reaver
						value >= 33
					}
				}
				desc = trait_reaver_1
			}
			desc = trait_reaver
		}
	}

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_reaver_desc
			}
			desc = trait_reaver_character_desc
		}
	}
}

reckless = {
	
	category = commander
	flag = commander_trait_flag

	opposites = {
		cautious_leader
	}
	
	min_combat_roll = -2
	max_combat_roll = 3
	
	culture_modifier = {
		parameter = forest_trait_bonuses
		forest_max_combat_roll = 1
		taiga_max_combat_roll = 1
	}
	
	culture_modifier = {
		parameter = jungle_trait_bonuses
		jungle_max_combat_roll = 1
	}
	
	culture_modifier = {
		parameter = dry_trait_bonuses
		drylands_max_combat_roll = 1
		desert_max_combat_roll = 1
	}
	
	ruler_designer_cost = 25

	track = {
		33 = {
			min_combat_roll = -2
			max_combat_roll = 3
			culture_modifier = {
				parameter = forest_trait_bonuses
				forest_max_combat_roll = 1
				taiga_max_combat_roll = 1
			}
			culture_modifier = {
				parameter = jungle_trait_bonuses
				jungle_max_combat_roll = 1
			}
			culture_modifier = {
				parameter = dry_trait_bonuses
				drylands_max_combat_roll = 1
				desert_max_combat_roll = 1
			}
		}
		66 = {
			advantage = 1
			max_combat_roll = 3
			culture_modifier = {
				parameter = forest_trait_bonuses
				forest_max_combat_roll = 1
				taiga_max_combat_roll = 1
			}
			culture_modifier = {
				parameter = jungle_trait_bonuses
				jungle_max_combat_roll = 1
			}
			culture_modifier = {
				parameter = dry_trait_bonuses
				drylands_max_combat_roll = 1
				desert_max_combat_roll = 1
			}
		}
		100 = {
			advantage = 2
			martial = 1
			max_combat_roll = 3
			culture_modifier = {
				parameter = forest_trait_bonuses
				forest_max_combat_roll = 1
				taiga_max_combat_roll = 1
			}
			culture_modifier = {
				parameter = jungle_trait_bonuses
				jungle_max_combat_roll = 1
			}
			culture_modifier = {
				parameter = dry_trait_bonuses
				drylands_max_combat_roll = 1
				desert_max_combat_roll = 1
			}
		}
	}
	
	name = {
		first_valid = {
			triggered_desc = {
				trigger = {
					exists = this
					has_trait_xp = {
						trait = reckless
						value >= 100
					}
				}
				desc = trait_reckless_3
			}
			triggered_desc = {
				trigger = {
					exists = this
					has_trait_xp = {
						trait = reckless
						value >= 66
					}
				}
				desc = trait_reckless_2
			}
			triggered_desc = {
				trigger = {
					exists = this
					has_trait_xp = {
						trait = reckless
						value >= 33
					}
				}
				desc = trait_reckless_1
			}
			desc = trait_reckless
		}
	}


	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_reckless_desc
			}
			desc = trait_reckless_character_desc
		}
	}
}

holy_warrior = {
	
	category = commander
	flag = commander_trait_flag
	
	tolerance_advantage_mod = 4
	
	ruler_designer_cost = 25

	track = {
		33 = {
			tolerance_advantage_mod = 4
		}
		66 = {
			advantage = 1
			tolerance_advantage_mod = 4
		}
		100 = {
			advantage = 2
			martial = 1
			tolerance_advantage_mod = 4
		}
	}

	name = {
		first_valid = {
			triggered_desc = {
				trigger = {
					exists = this
					has_trait_xp = {
						trait = holy_warrior
						value >= 100
					}
				}
				desc = trait_holy_warrior_3
			}
			triggered_desc = {
				trigger = {
					exists = this
					has_trait_xp = {
						trait = holy_warrior
						value >= 66
					}
				}
				desc = trait_holy_warrior_2
			}
			triggered_desc = {
				trigger = {
					exists = this
					has_trait_xp = {
						trait = holy_warrior
						value >= 33
					}
				}
				desc = trait_holy_warrior_1
			}
			desc = trait_holy_warrior
		}
	}

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_holy_warrior_desc
			}
			desc = trait_holy_warrior_character_desc
		}
	}
}

open_terrain_expert = {
	
	category = commander
	flag = commander_trait_flag

	farmlands_advantage = 2
	plains_advantage = 2
	steppe_advantage = 2
	
	culture_modifier = {
		parameter = winter_trait_bonuses
		winter_movement_speed = 0.1
	}
	
	culture_modifier = {
		parameter = dry_trait_bonuses
		drylands_advantage = 1
		desert_advantage = 1
	}
	
	ruler_designer_cost = 25

	track = {
		33 = {
			farmlands_advantage = 2
			plains_advantage = 2
			steppe_advantage = 2
			culture_modifier = {
				parameter = winter_trait_bonuses
				winter_movement_speed = 0.1
			}
			culture_modifier = {
				parameter = dry_trait_bonuses
				drylands_advantage = 1
				desert_advantage = 1
			}
		}
		66 = {
			advantage = 1
			farmlands_advantage = 2
			plains_advantage = 2
			steppe_advantage = 2
			culture_modifier = {
				parameter = winter_trait_bonuses
				winter_movement_speed = 0.1
			}
			culture_modifier = {
				parameter = dry_trait_bonuses
				drylands_advantage = 1
				desert_advantage = 1
			}
		}
		100 = {
			advantage = 2
			martial = 1
			farmlands_advantage = 2
			plains_advantage = 2
			steppe_advantage = 2
			culture_modifier = {
				parameter = winter_trait_bonuses
				winter_movement_speed = 0.1
			}
			culture_modifier = {
				parameter = dry_trait_bonuses
				drylands_advantage = 1
				desert_advantage = 1
			}
		}
	}

	trait_exclusive_if_realm_contains = {
		farmlands
		plains
		steppe
	}

	name = {
		first_valid = {
			triggered_desc = {
				trigger = {
					exists = this
					has_trait_xp = {
						trait = open_terrain_expert
						value >= 100
					}
				}
				desc = trait_open_terrain_expert_3
			}
			triggered_desc = {
				trigger = {
					exists = this
					has_trait_xp = {
						trait = open_terrain_expert
						value >= 66
					}
				}
				desc = trait_open_terrain_expert_2
			}
			triggered_desc = {
				trigger = {
					exists = this
					has_trait_xp = {
						trait = open_terrain_expert
						value >= 33
					}
				}
				desc = trait_open_terrain_expert_1
			}
			desc = trait_open_terrain_expert
		}
	}

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_open_terrain_expert_desc
			}
			desc = trait_open_terrain_expert_character_desc
		}
	}
}

rough_terrain_expert = {
	
	category = commander
	flag = commander_trait_flag
	
	hills_advantage = 2
	mountains_advantage = 2
	wetlands_advantage = 2
	
	culture_modifier = {
		parameter = winter_trait_bonuses
		winter_advantage = 2
	}
	
	culture_modifier = {
		parameter = forest_trait_bonuses
		forest_advantage = 1
		taiga_advantage = 1
	}
	
	culture_modifier = {
		parameter = jungle_trait_bonuses
		jungle_advantage = 1
	}
	
	culture_modifier = {
		parameter = mountain_trait_bonuses
		mountains_max_combat_roll = 1
		desert_mountains_max_combat_roll = 1
		desert_mountains_advantage = 2
	}
	
	culture_modifier = {
		parameter = hill_trait_bonuses
		hills_min_combat_roll = 1
	}
	
	ruler_designer_cost = 25

	track = {
		33 = {
			hills_advantage = 2
			mountains_advantage = 2
			wetlands_advantage = 2
			culture_modifier = {
				parameter = winter_trait_bonuses
				winter_advantage = 2
			}
			culture_modifier = {
				parameter = forest_trait_bonuses
				forest_advantage = 1
				taiga_advantage = 1
			}
			culture_modifier = {
				parameter = jungle_trait_bonuses
				jungle_advantage = 1
			}
			culture_modifier = {
				parameter = mountain_trait_bonuses
				mountains_max_combat_roll = 1
				desert_mountains_max_combat_roll = 1
				desert_mountains_advantage = 2
			}
			culture_modifier = {
				parameter = hill_trait_bonuses
				hills_min_combat_roll = 1
			}
		}
		66 = {
			advantage = 1
			hills_advantage = 2
			mountains_advantage = 2
			wetlands_advantage = 2
			culture_modifier = {
				parameter = winter_trait_bonuses
				winter_advantage = 2
			}
			culture_modifier = {
				parameter = forest_trait_bonuses
				forest_advantage = 1
				taiga_advantage = 1
			}
			culture_modifier = {
				parameter = jungle_trait_bonuses
				jungle_advantage = 1
			}
			culture_modifier = {
				parameter = mountain_trait_bonuses
				mountains_max_combat_roll = 1
				desert_mountains_max_combat_roll = 1
				desert_mountains_advantage = 2
			}
			culture_modifier = {
				parameter = hill_trait_bonuses
				hills_min_combat_roll = 1
			}
		}
		100 = {
			advantage = 2
			martial = 1
			hills_advantage = 2
			mountains_advantage = 2
			wetlands_advantage = 2
			culture_modifier = {
				parameter = winter_trait_bonuses
				winter_advantage = 2
			}
			culture_modifier = {
				parameter = forest_trait_bonuses
				forest_advantage = 1
				taiga_advantage = 1
			}
			culture_modifier = {
				parameter = jungle_trait_bonuses
				jungle_advantage = 1
			}
			culture_modifier = {
				parameter = mountain_trait_bonuses
				mountains_max_combat_roll = 1
				desert_mountains_max_combat_roll = 1
				desert_mountains_advantage = 2
			}
			culture_modifier = {
				parameter = hill_trait_bonuses
				hills_min_combat_roll = 1
			}
		}
	}

	trait_exclusive_if_realm_contains = {
		hills
		mountains
		wetlands
	}

	name = {
		first_valid = {
			triggered_desc = {
				trigger = {
					exists = this
					has_trait_xp = {
						trait = rough_terrain_expert
						value >= 100
					}
				}
				desc = trait_rough_terrain_expert_3
			}
			triggered_desc = {
				trigger = {
					exists = this
					has_trait_xp = {
						trait = rough_terrain_expert
						value >= 66
					}
				}
				desc = trait_rough_terrain_expert_2
			}
			triggered_desc = {
				trigger = {
					exists = this
					has_trait_xp = {
						trait = rough_terrain_expert
						value >= 33
					}
				}
				desc = trait_rough_terrain_expert_1
			}
			desc = trait_rough_terrain_expert
		}
	}

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_rough_terrain_expert_desc
			}
			desc = trait_rough_terrain_expert_character_desc
		}
	}
}

forest_fighter = {
	
	category = commander
	flag = commander_trait_flag
	
	forest_advantage = 2
	taiga_advantage = 2
	
	ruler_designer_cost = 25

	track = {
		33 = {
			forest_advantage = 2
			taiga_advantage = 2
		}
		66 = {
			advantage = 1
			forest_advantage = 2
			taiga_advantage = 2
		}
		100 = {
			advantage = 2
			martial = 1
			forest_advantage = 2
			taiga_advantage = 2
		}
	}

	trait_exclusive_if_realm_contains = {
		forest
		taiga
	}

	name = {
		first_valid = {
			triggered_desc = {
				trigger = {
					exists = this
					has_trait_xp = {
						trait = forest_fighter
						value >= 100
					}
				}
				desc = trait_forest_fighter_3
			}
			triggered_desc = {
				trigger = {
					exists = this
					has_trait_xp = {
						trait = forest_fighter
						value >= 66
					}
				}
				desc = trait_forest_fighter_2
			}
			triggered_desc = {
				trigger = {
					exists = this
					has_trait_xp = {
						trait = forest_fighter
						value >= 33
					}
				}
				desc = trait_forest_fighter_1
			}
			desc = trait_forest_fighter
		}
	}

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_forest_fighter_desc
			}
			desc = trait_forest_fighter_character_desc
		}
	}
}

cautious_leader = {
	
	category = commander
	flag = commander_trait_flag

	opposites = {
		reckless
	}
	
	min_combat_roll = 2
	max_combat_roll = -1
	
	culture_modifier = {
		parameter = forest_trait_bonuses
		forest_min_combat_roll = 1
		taiga_min_combat_roll = 1
	}
	
	culture_modifier = {
		parameter = jungle_trait_bonuses
		jungle_min_combat_roll = 1
	}
	
	ruler_designer_cost = 25

	track = {
		33 = {
			min_combat_roll = 2
			max_combat_roll = -1
			culture_modifier = {
				parameter = forest_trait_bonuses
				forest_min_combat_roll = 1
				taiga_min_combat_roll = 1
			}
			culture_modifier = {
				parameter = jungle_trait_bonuses
				jungle_min_combat_roll = 1
			}
		}
		66 = {
			advantage = 1
			min_combat_roll = 2
			culture_modifier = {
				parameter = forest_trait_bonuses
				forest_min_combat_roll = 1
				taiga_min_combat_roll = 1
			}
			culture_modifier = {
				parameter = jungle_trait_bonuses
				jungle_min_combat_roll = 1
			}
		}
		100 = {
			advantage = 2
			martial = 1
			min_combat_roll = 2
			culture_modifier = {
				parameter = forest_trait_bonuses
				forest_min_combat_roll = 1
				taiga_min_combat_roll = 1
			}
			culture_modifier = {
				parameter = jungle_trait_bonuses
				jungle_min_combat_roll = 1
			}
		}
	}

	name = {
		first_valid = {
			triggered_desc = {
				trigger = {
					exists = this
					has_trait_xp = {
						trait = cautious_leader
						value >= 100
					}
				}
				desc = trait_cautious_leader_3
			}
			triggered_desc = {
				trigger = {
					exists = this
					has_trait_xp = {
						trait = cautious_leader
						value >= 66
					}
				}
				desc = trait_cautious_leader_2
			}
			triggered_desc = {
				trigger = {
					exists = this
					has_trait_xp = {
						trait = cautious_leader
						value >= 33
					}
				}
				desc = trait_cautious_leader_1
			}
			desc = trait_cautious_leader
		}
	}

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_cautious_leader_desc
			}
			desc = trait_cautious_leader_character_desc
		}
	}
}

organizer = {
	
	category = commander
	flag = commander_trait_flag
	
	movement_speed = 0.1
	retreat_losses = -0.1
	
	culture_modifier = {
		parameter = winter_trait_bonuses
		winter_movement_speed = 0.05
	}
	
	culture_modifier = {
		parameter = mountain_trait_bonuses
		mountains_attrition_mult = -0.5
		desert_mountains_attrition_mult = -0.5
	}
	
	culture_modifier = {
		parameter = dry_trait_bonuses
		drylands_advantage = 1
		desert_advantage = 1
	}
	
	ruler_designer_cost = 25

	track = {
		33 = {
			movement_speed = 0.1
			retreat_losses = -0.1
			culture_modifier = {
				parameter = winter_trait_bonuses
				winter_movement_speed = 0.05
			}
			culture_modifier = {
				parameter = mountain_trait_bonuses
				mountains_attrition_mult = -0.5
				desert_mountains_attrition_mult = -0.5
			}
			culture_modifier = {
				parameter = dry_trait_bonuses
				drylands_advantage = 1
				desert_advantage = 1
			}
		}
		66 = {
			advantage = 1
			movement_speed = 0.1
			retreat_losses = -0.1
			culture_modifier = {
				parameter = winter_trait_bonuses
				winter_movement_speed = 0.05
			}
			culture_modifier = {
				parameter = mountain_trait_bonuses
				mountains_attrition_mult = -0.5
				desert_mountains_attrition_mult = -0.5
			}
			culture_modifier = {
				parameter = dry_trait_bonuses
				drylands_advantage = 1
				desert_advantage = 1
			}
		}
		100 = {
			advantage = 2
			martial = 1
			movement_speed = 0.1
			retreat_losses = -0.1
			culture_modifier = {
				parameter = winter_trait_bonuses
				winter_movement_speed = 0.05
			}
			culture_modifier = {
				parameter = mountain_trait_bonuses
				mountains_attrition_mult = -0.5
				desert_mountains_attrition_mult = -0.5
			}
			culture_modifier = {
				parameter = dry_trait_bonuses
				drylands_advantage = 1
				desert_advantage = 1
			}
		}
	}

	name = {
		first_valid = {
			triggered_desc = {
				trigger = {
					exists = this
					has_trait_xp = {
						trait = organizer
						value >= 100
					}
				}
				desc = trait_organizer_3
			}
			triggered_desc = {
				trigger = {
					exists = this
					has_trait_xp = {
						trait = organizer
						value >= 66
					}
				}
				desc = trait_organizer_2
			}
			triggered_desc = {
				trigger = {
					exists = this
					has_trait_xp = {
						trait = organizer
						value >= 33
					}
				}
				desc = trait_organizer_1
			}
			desc = trait_organizer
		}
	}

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_organizer_desc
			}
			desc = trait_organizer_character_desc
		}
	}
}

winter_soldier = {

	category = winter_commander
	flag = commander_trait_flag

	winter_movement_speed = 0.1

	ruler_designer_cost = 25

	winter_advantage = 3

	track = {
		33 = {
			winter_advantage = 3
			winter_movement_speed = 0.1
		}
		66 = {
			advantage = 1
			winter_advantage = 3
			winter_movement_speed = 0.1
		}
		100 = {
			advantage = 2
			martial = 1
			winter_advantage = 3
			winter_movement_speed = 0.1
		}
	}

	name = {
		first_valid = {
			triggered_desc = {
				trigger = {
					exists = this
					has_trait_xp = {
						trait = winter_soldier
						value >= 100
					}
				}
				desc = trait_winter_soldier_3
			}
			triggered_desc = {
				trigger = {
					exists = this
					has_trait_xp = {
						trait = winter_soldier
						value >= 66
					}
				}
				desc = trait_winter_soldier_2
			}
			triggered_desc = {
				trigger = {
					exists = this
					has_trait_xp = {
						trait = winter_soldier
						value >= 33
					}
				}
				desc = trait_winter_soldier_1
			}
			desc = trait_winter_soldier
		}
	}

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_winter_soldier_desc
			}
			desc = trait_winter_soldier_character_desc
		}
	}
}

#Based on cultural Traditions

crusader_king = {
	category = fame

	martial = 3
	prowess = 2
	
	same_opinion_if_same_faith = 10
	same_faith_opinion = 15
	ignore_negative_culture_opinion = yes
	monthly_county_control_growth_add = 0.5
	
	tolerance_advantage_mod = 5
	hard_casualty_modifier = -0.15
	retreat_losses = -0.2
	
	county_opinion_add = 35
	
	ruler_designer_cost = 120

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = { NOT = { exists = this } }
				desc = trait_crusader_king_fallback_desc
			}
#			triggered_desc = {
#				trigger = {
#					faith = faith:nestorian
#				}
#				desc = beth_nahrain_crusader_desc
#			}
			triggered_desc = {
				trigger = { is_female = yes }
				desc = trait_crusader_king_female_desc
			}
			desc = trait_crusader_king_male_desc
		}
	}

	name = {
		first_valid = {
			triggered_desc = {
				trigger = { NOT = { exists = this } }
				desc = trait_crusader_king_fallback_dead
			}
#			triggered_desc = {
#				trigger = {
#					faith = faith:nestorian
#				}
#				desc = nick_beth_nahrain
#			}
			triggered_desc = {
				trigger = {
					faith = { OR = { religion_tag = eastern_orthodox_religion religion_tag = catholic_religion religion_tag = protestant_religion } }
					is_female = yes
				}
				desc = trait_crusader_king_female
			}
			triggered_desc = {
				trigger = { faith = { OR = { religion_tag = eastern_orthodox_religion religion_tag = catholic_religion religion_tag = protestant_religion } } }
				desc = trait_crusader_king
			}
			triggered_desc = {
				trigger = { faith = { religion_tag = islam_religion } }
				desc = trait_crusader_king_islam
			}
#			triggered_desc = {
#				trigger = {
#					faith = { religion_tag = bon_religion }
#					is_female = yes
#				}
#				desc = trait_crusader_king_bon_female
#			}
#			triggered_desc = {
#				trigger = { faith = { religion_tag = bon_religion } }
#				desc = trait_crusader_king_bon_male
#			}
			triggered_desc = {
				trigger = { faith = { religion_tag = buddhism_religion } }
				desc = trait_crusader_king_buddhism
			}
#			triggered_desc = {
#				trigger = { faith = { religion_tag = dualism_religion } }
#				desc = trait_crusader_king_dualism
#			}
			triggered_desc = {
				trigger = { faith = { religion_tag = folkgerman_religion } }
				desc = trait_crusader_king_germanic
			}
#			triggered_desc = {
#				trigger = {
#					faith = { religion_tag = theomach_religion }
#					is_female = yes
#				}
#				desc = trait_crusader_king_hellenism_female
#			}
#			triggered_desc = {
#				trigger = { faith = { religion_tag = theomach_religion } }
#				desc = trait_crusader_king_hellenism_male
#			}
#			triggered_desc = {
#				trigger = { faith = { religion_tag = hinduism_religion } }
#				desc = trait_crusader_king_hinduism
#			}
#			triggered_desc = {
#				trigger = { faith = { religion_tag = jainism_religion } }
#				desc = trait_crusader_king_jainism
#			}
			triggered_desc = {
				trigger = { faith = { religion_tag = judaism_religion } }
				desc = trait_crusader_king_judaism
			}
#			triggered_desc = {
#				trigger = { faith = { religion_tag = hungaric_religion } }
#				desc = trait_crusader_king_magyar
#			}
#			triggered_desc = {
#				trigger = { faith = { religion_tag = baltic_religion } }
#				desc = trait_crusader_king_baltic
#			}
#			triggered_desc = {
#				trigger = { faith = { religion_tag = slavic_religion } }
#				desc = trait_crusader_king_slavic
#			}
#			triggered_desc = {
#				trigger = {
#					faith = { religion_tag = finnic_religion }
#					is_female = yes
#				}
#				desc = trait_crusader_king_finno_ugric_female
#			}
#			triggered_desc = {
#				trigger = { faith = { religion_tag = finnic_religion } }
#				desc = trait_crusader_king_finno_ugric_male
#			}
#			triggered_desc = {
#				trigger = { faith = { religion_tag = siberian_religion } }
#				desc = trait_crusader_king_siberian
#			}
#			triggered_desc = {
#				trigger = {
#					faith = { religion_tag = tengrism_religion }
#					is_female = yes
#				}
#				desc = trait_crusader_king_tengrism_female
#			}
#			triggered_desc = {
#				trigger = { faith = { religion_tag = tengrism_religion } }
#				desc = trait_crusader_king_tengrism_male
#			}
#			triggered_desc = {
#				trigger = { faith = { religion_tag = west_african_religion } }
#				desc = trait_crusader_king_west_african
#			}
#			triggered_desc = {
#				trigger = { faith = { religion_tag = west_african_bori_religion } }
#				desc = trait_crusader_king_west_african_bori
#			}
#			triggered_desc = {
#				trigger = { faith = { religion_tag = west_african_roog_religion } }
#				desc = trait_crusader_king_west_african_roog
#			}
#			triggered_desc = {
#				trigger = { faith = { religion_tag = zoroastrianism_religion } }
#				desc = trait_crusader_king_zoroastrianism
#			}
#			triggered_desc = {
#				trigger = {
#					faith = { religion_tag = zunism_religion }
#					is_female = yes
#				}
#				desc = trait_crusader_king_zunism_female
#			}
#			triggered_desc = {
#				trigger = { faith = { religion_tag = zunism_religion } }
#				desc = trait_crusader_king_zunism_male
#			}

			triggered_desc = {
				trigger = { is_female = yes }
				desc = trait_crusader_king_fallback_female
			}
			desc = trait_crusader_king_fallback_male
		}
	}

	ai_zeal = 25
}

chakravarti = {
	category = fame

	diplomacy = 2
	learning = 2
	martial = 1

	jainism_religion_opinion = 20
	hinduism_religion_opinion = 20
	buddhism_religion_opinion = 20
	
	shown_in_ruler_designer = no
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_chakravarti_desc
			}
			desc = trait_chakravarti_character_desc
		}
	}

	ai_honor = 40
	ai_zeal = 50
	ai_energy = 20
	ai_boldness = 20
}

greatest_of_khans = {
	category = fame

	diplomacy = 2
	martial = 2
	stewardship = 1
	prowess = 2

	#Seems counterintuitive, but is needed to get GoK to use the mass declare
	ai_war_chance = -100
	ai_war_cooldown = -100
	same_culture_opinion = 25
	dread_baseline_add = 50
	dread_decay_mult = -0.5
	enemy_hostile_scheme_phase_duration_add = monumental_scheme_phase_duration_malus_value
	enemy_hostile_scheme_success_chance_add = -100
	vassal_limit = 75
	minority_opinion = 40
	army_maintenance_mult = -0.5
	archer_cavalry_siege_value_add = 0.5
	light_cavalry_siege_value_add = 0.5
	monthly_legitimacy_add = 10
	
	archer_cavalry_toughness_mult = 1
	light_cavalry_toughness_mult = 1
	heavy_cavalry_toughness_mult = 1
	
	archer_cavalry_damage_mult = 1
	light_cavalry_damage_mult = 1
	heavy_cavalry_damage_mult = 1
	
	herd_gain_mult = 1
	herd_capacity_mult = 3

	flag = gok_obedience_flag
	
	shown_in_ruler_designer = no
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_greatest_of_khans_desc
			}
			desc = trait_greatest_of_khans_character_desc
		}
	}

	ai_honor = 20
	ai_energy = 40
	ai_boldness = 20
}

conqueror = {
	category = fame
	flag = conqueror_bonuses_modifier

	ai_war_chance = -100
	ai_war_cooldown = -100
	ai_amenity_spending = -0.25
	ai_amenity_target_baseline = -0.4
	title_creation_cost_mult = -0.75
	title_creation_piety_cost_mult = -0.75
	monthly_legitimacy_add = 5
	men_at_arms_maintenance = -0.75
	monthly_income = 5
	enemy_hostile_scheme_phase_duration_add = 25
	enemy_hostile_scheme_success_chance_max_add = -40
	enemy_hostile_scheme_success_chance_growth_add = -3
	herd_capacity_mult = 0.5
	
	shown_in_ruler_designer = no
	
	#ai_greed = 1000
	#ai_boldness = 1000
	#ai_honor = -1000
}

paragon = {
	category = fame

	zealot_opinion = 20
	
	shown_in_ruler_designer = no
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_paragon_desc
			}
			desc = trait_paragon_character_desc
		}
	}

	ai_zeal = 20
}

consecrated_blood = {
	category = fame

	zealot_opinion = 10
	
	shown_in_ruler_designer = no
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_consecrated_blood_desc
			}
			desc = trait_consecrated_blood_character_desc
		}
	}

	ai_zeal = 10
}

education_martial_prowess_1 = {
	#category = education
	minimum_age = 16
	prowess = 1
	
	culture_modifier = {
		parameter = prowess_traits_more_valued
		same_culture_opinion = 1
		monthly_prestige = 0.1
	}

	group = education_martial_prowess
	level = 1
	
	shown_in_ruler_designer = no

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_education_martial_prowess_1_desc
			}
			desc = trait_education_martial_prowess_1_character_desc
		}
	}
}

education_martial_prowess_2 = {
	#category = education
	minimum_age = 16
	prowess = 2
	
	culture_modifier = {
		parameter = prowess_traits_more_valued
		same_culture_opinion = 2
		monthly_prestige = 0.2
	}

	group = education_martial_prowess
	level = 2
	
	shown_in_ruler_designer = no

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_education_martial_prowess_2_desc
			}
			desc = trait_education_martial_prowess_2_character_desc
		}
	}
}

education_martial_prowess_3 = {
	#category = education
	minimum_age = 16
	prowess = 3
	
	culture_modifier = {
		parameter = prowess_traits_more_valued
		same_culture_opinion = 3
		monthly_prestige = 0.3
	}

	group = education_martial_prowess
	level = 3
	
	shown_in_ruler_designer = no

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_education_martial_prowess_3_desc
			}
			desc = trait_education_martial_prowess_3_character_desc
		}
	}
}

education_martial_prowess_4 = {
	#category = education
	minimum_age = 16
	prowess = 4
	
	culture_modifier = {
		parameter = prowess_traits_more_valued
		same_culture_opinion = 4
		monthly_prestige = 0.4
	}

	group = education_martial_prowess
	level = 4
	
	shown_in_ruler_designer = no
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_education_martial_prowess_4_desc
			}
			desc = trait_education_martial_prowess_4_character_desc
		}
	}
}


############### COURT TYPES ##############

diplomatic_court_1 = {
	diplomacy = 1
	
	category = court_type
	group = diplomatic_court
	level = 1
	
	shown_in_ruler_designer = no

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_diplomatic_court_1_desc
			}
			desc = trait_diplomatic_court_1_character_desc
		}
	}

	compatibility = {
		diplomatic_court_2 = @pos_compat_medium
		intrigue_court_1 = @neg_compat_low
		intrigue_court_2 = @neg_compat_low
	}
}

diplomatic_court_2 = {
	diplomacy = 2
	monthly_prestige = 0.3
	monthly_diplomacy_lifestyle_xp_gain_mult = 0.15
	
	category = court_type
	group = diplomatic_court
	level = 2

	shown_in_ruler_designer = no

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_diplomatic_court_2_desc
			}
			desc = trait_diplomatic_court_2_character_desc
		}
	}

	compatibility = {
		diplomatic_court_1 = @pos_compat_medium
		intrigue_court_1 = @neg_compat_low
		intrigue_court_2 = @neg_compat_low
	}
}

warlike_court_1 = {
	martial = 1
	prowess = 1
	
	category = court_type
	group = warlike_court
	level = 1
	
	shown_in_ruler_designer = no

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_warlike_court_1_desc
			}
			desc = trait_warlike_court_1_character_desc
		}
	}

	compatibility = {
		warlike_court_2 = @pos_compat_medium
		scholarly_court_1 = @neg_compat_low
		scholarly_court_2 = @neg_compat_low
	}
}

warlike_court_2 = {
	martial = 2
	monthly_martial_lifestyle_xp_gain_mult = 0.15
	prowess = 2
	men_at_arms_maintenance = -0.05
	
	category = court_type
	group = warlike_court
	level = 2

	shown_in_ruler_designer = no

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_warlike_court_2_desc
			}
			desc = trait_warlike_court_2_character_desc
		}
	}

	compatibility = {
		warlike_court_1 = @pos_compat_medium
		scholarly_court_1 = @neg_compat_low
		scholarly_court_2 = @neg_compat_low
	}
}

administrative_court_1 = {
	stewardship = 1
	
	category = court_type
	group = administrative_court
	level = 1
	
	shown_in_ruler_designer = no

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_administrative_court_1_desc
			}
			desc = trait_administrative_court_1_character_desc
		}
	}

	compatibility = {
		administrative_court_2 = @pos_compat_medium
	}
}

administrative_court_2 = {
	stewardship = 2
	monthly_stewardship_lifestyle_xp_gain_mult = 0.15
	monthly_county_control_growth_add = 0.2
	
	category = court_type
	group = administrative_court
	level = 2

	shown_in_ruler_designer = no

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_administrative_court_2_desc
			}
			desc = trait_administrative_court_2_character_desc
		}
	}

	compatibility = {
		administrative_court_1 = @pos_compat_medium
	}
}

intrigue_court_1 = {
	intrigue = 1
	
	category = court_type
	group = intrigue_court
	level = 1
	
	shown_in_ruler_designer = no

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_intrigue_court_1_desc
			}
			desc = trait_intrigue_court_1_character_desc
		}
	}

	compatibility = {
		intrigue_court_2 = @pos_compat_medium
		diplomatic_court_1 = @neg_compat_low
		diplomatic_court_2 = @neg_compat_low
	}
}

intrigue_court_2 = {
	intrigue = 2
	enemy_hostile_scheme_success_chance_add = -10
	monthly_intrigue_lifestyle_xp_gain_mult = 0.15
	dread_baseline_add = 10
	
	category = court_type
	group = intrigue_court
	level = 2

	shown_in_ruler_designer = no

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_intrigue_court_2_desc
			}
			desc = trait_intrigue_court_2_character_desc
		}
	}

	compatibility = {
		intrigue_court_1 = @pos_compat_medium
		diplomatic_court_1 = @neg_compat_low
		diplomatic_court_2 = @neg_compat_low
	}
}

scholarly_court_1 = {
	learning = 1
	
	category = court_type
	group = scholarly_court
	level = 1
	
	shown_in_ruler_designer = no

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_scholarly_court_1_desc
			}
			desc = trait_scholarly_court_1_character_desc
		}
	}

	compatibility = {
		scholarly_court_2 = @pos_compat_medium
		warlike_court_1 = @neg_compat_low
		warlike_court_2 = @neg_compat_low
	}
}

scholarly_court_2 = {
	learning = 2
	development_growth_factor = 0.20
	county_fertility_growth_mult = medium_county_fertility_growth_gain
	monthly_learning_lifestyle_xp_gain_mult = 0.15
	
	category = court_type
	group = scholarly_court
	level = 2

	shown_in_ruler_designer = no

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_scholarly_court_2_desc
			}
			desc = trait_scholarly_court_2_character_desc
		}
	}

	compatibility = {
		scholarly_court_1 = @pos_compat_medium
		warlike_court_1 = @neg_compat_low
		warlike_court_2 = @neg_compat_low
	}
}

# URBANISM DYNASTY PERK SPECIALS
education_republican_knowledge_1 = {
	minimum_age = 16
	learning = 1
	stewardship = 1
	#category = education

	shown_in_ruler_designer = no

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_education_republican_knowledge_1_desc
			}
			desc = trait_education_republican_knowledge_1_character_desc
		}
	}

	group = education_republican_knowledge
	level = 1
}

education_republican_knowledge_2 = {
	minimum_age = 16
	learning = 2
	stewardship = 2
	#category = education

	shown_in_ruler_designer = no

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_education_republican_knowledge_2_desc
			}
			desc = trait_education_republican_knowledge_2_character_desc
		}
	}

	group = education_republican_knowledge
	level = 2
}

education_republican_knowledge_3 = {
	minimum_age = 16
	learning = 3
	stewardship = 3
	#category = education

	shown_in_ruler_designer = no

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_education_republican_knowledge_3_desc
			}
			desc = trait_education_republican_knowledge_3_character_desc
		}
	}

	group = education_republican_knowledge
	level = 3
}

education_republican_knowledge_4 = {
	minimum_age = 16
	learning = 4
	stewardship = 4
	#category = education

	shown_in_ruler_designer = no

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_education_republican_knowledge_4_desc
			}
			desc = trait_education_republican_knowledge_4_character_desc
		}
	}

	group = education_republican_knowledge
	level = 4
}


############### EP2 TRAITS ##############

tourney_participant = {

	same_opinion = 10
	belligerent_opinion = 10

	ruler_designer_cost = 5

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_tourney_participant_desc
			}
			desc = trait_tourney_participant_character_desc
		}
	}

	icon = {
		first_valid = {
			triggered_desc = { # If no character exists
				trigger = { NOT = { exists = this } }
				desc = tournament.dds
			}
			triggered_desc = {
				trigger = {
					AND = {
						has_trait_xp = {
							trait = tourney_participant
							track = foot
							value >= 30
						}
						has_trait_xp = {
							trait = tourney_participant
							track = bow
							value >= 30
						}
						has_trait_xp = {
							trait = tourney_participant
							track = horse
							value >= 30
						}
						has_trait_xp = {
							trait = tourney_participant
							track = wit
							value >= 30
						}
					}
				}
				desc = tournament_foot_archery_horse_mind.dds
			}
			triggered_desc = {
				trigger = {
					AND = {
						has_trait_xp = {
							trait = tourney_participant
							track = foot
							value >= 30
						}
						has_trait_xp = {
							trait = tourney_participant
							track = bow
							value >= 30
						}
						has_trait_xp = {
							trait = tourney_participant
							track = horse
							value >= 30
						}
					}
				}
				desc = tournament_foot_archery_horse.dds
			}
			triggered_desc = {
				trigger = {
					AND = {
						has_trait_xp = {
							trait = tourney_participant
							track = foot
							value >= 30
						}
						has_trait_xp = {
							trait = tourney_participant
							track = bow
							value >= 30
						}
						has_trait_xp = {
							trait = tourney_participant
							track = wit
							value >= 30
						}
					}
				}
				desc = tournament_foot_archery_mind.dds
			}
			triggered_desc = {
				trigger = {
					AND = {
						has_trait_xp = {
							trait = tourney_participant
							track = foot
							value >= 30
						}
						has_trait_xp = {
							trait = tourney_participant
							track = horse
							value >= 30
						}
						has_trait_xp = {
							trait = tourney_participant
							track = wit
							value >= 30
						}
					}
				}
				desc = tournament_foot_horse_mind.dds
			}
			triggered_desc = {
				trigger = {
					AND = {
						has_trait_xp = {
							trait = tourney_participant
							track = horse
							value >= 30
						}
						has_trait_xp = {
							trait = tourney_participant
							track = bow
							value >= 30
						}
						has_trait_xp = {
							trait = tourney_participant
							track = wit
							value >= 30
						}
					}
				}
				desc = tournament_horse_mind_archery.dds
			}
			triggered_desc = {
				trigger = {
					AND = {
						has_trait_xp = {
							trait = tourney_participant
							track = foot
							value >= 30
						}
						has_trait_xp = {
							trait = tourney_participant
							track = bow
							value >= 30
						}
					}
				}
				desc = tournament_foot_archery.dds
			}
			triggered_desc = {
				trigger = {
					AND = {
						has_trait_xp = {
							trait = tourney_participant
							track = foot
							value >= 30
						}
						has_trait_xp = {
							trait = tourney_participant
							track = horse
							value >= 30
						}
					}
				}
				desc = tournament_foot_horse.dds
			}
			triggered_desc = {
				trigger = {
					AND = {
						has_trait_xp = {
							trait = tourney_participant
							track = foot
							value >= 20
						}
						has_trait_xp = {
							trait = tourney_participant
							track = wit
							value >= 30
						}
					}
				}
				desc = tournament_foot_mind.dds
			}
			triggered_desc = {
				trigger = {
					AND = {
						has_trait_xp = {
							trait = tourney_participant
							track = bow
							value >= 30
						}
						has_trait_xp = {
							trait = tourney_participant
							track = horse
							value >= 30
						}
					}
				}
				desc = tournament_archery_horse.dds
			}
			triggered_desc = {
				trigger = {
					AND = {
						has_trait_xp = {
							trait = tourney_participant
							track = bow
							value >= 30
						}
						has_trait_xp = {
							trait = tourney_participant
							track = wit
							value >= 30
						}
					}
				}
				desc = tournament_archery_mind.dds
			}
			triggered_desc = {
				trigger = {
					AND = {
						has_trait_xp = {
							trait = tourney_participant
							track = horse
							value >= 30
						}
						has_trait_xp = {
							trait = tourney_participant
							track = wit
							value >= 30
						}
					}
				}
				desc = tournament_horse_mind.dds
			}
			triggered_desc = {
				trigger = {
					has_trait_xp = {
						trait = tourney_participant
						track = foot
						value >= 30
					}
				}
				desc = tournament_foot.dds
			}
			triggered_desc = {
				trigger = {
					has_trait_xp = {
						trait = tourney_participant
						track = bow
						value >= 30
					}
				}
				desc = tournament_archery.dds
			}
			triggered_desc = {
				trigger = {
					has_trait_xp = {
						trait = tourney_participant
						track = horse
						value >= 30
					}
				}
				desc = tournament_horse.dds
			}
			triggered_desc = {
				trigger = {
					has_trait_xp = {
						trait = tourney_participant
						track = wit
						value >= 30
					}
				}
				desc = tournament_mind.dds
			}
			desc = tournament.dds
		}
	}

	tracks = {
		foot = {
			30 = {
				prowess_no_portrait = 1
			}

			65 = {
				prowess_no_portrait = 1
				martial = 1
			}

			100 = {
				prowess_per_stress_level = 4
				men_at_arms_limit = 2
				knight_limit = 2
			}		
		}
		bow = {
			30 = {
				health = 0.05
			}

			65 = {
				health = 0.10
				vassal_levy_contribution_add = 0.15
			}

			100 = {
				health = 0.25
				army_maintenance_mult = -0.25
			}
		}
		horse = {
			30 = {
				monthly_prestige_gain_mult = 0.05
			}

			65 = {
				monthly_prestige_gain_mult = 0.1
				glory_hound_opinion = 20
			}

			100 = {
				monthly_dynasty_prestige_mult = 0.05
				prowess_per_prestige_level = 1
			}
		}
		wit = {
			30 = {
				diplomacy = 1
			}

			65 = {
				diplomacy = 1
				monthly_lifestyle_xp_gain_mult = 0.05
				zealot_opinion = 10
			}

			100 = {
				diplomacy = 1
				movement_speed = 0.2
				monthly_lifestyle_xp_gain_mult = 0.10
			}
		}
	}	

	compatibility = {
		brave = @pos_compat_low
		craven = @neg_compat_low
	}
}

lifestyle_traveler = {
	category = lifestyle
	icon = "traveler.dds"

	monthly_wanderer_lifestyle_xp_gain_mult = 0.1
	same_opinion = 5
	diplomacy = 1

	ruler_designer_cost = 20

	name = {
		first_valid = {
			triggered_desc = {
				trigger = {
					trigger_if = {
						limit = {
							NOT = { exists = this }
						}
					}
					trigger_else_if = {
						limit = { has_trait = lifestyle_traveler }
						has_trait_xp = {
							trait = lifestyle_traveler
							track = travel
							value < 50
						}
						has_trait_xp = {
							trait = lifestyle_traveler
							track = danger
							value < 50
						}
					}
					trigger_else = {
						NOT = { has_trait = lifestyle_traveler }
					}
				}
				desc = trait_traveler_1
			}
			triggered_desc = {
				trigger = {
					has_trait = lifestyle_traveler
					OR = {
						has_trait_xp = {
							trait = lifestyle_traveler
							track = travel
							value = 100
						}
						has_trait_xp = {
							trait = lifestyle_traveler
							track = danger
							value = 100
						}
					}
				}
				desc = trait_traveler_3
			}
			desc = trait_traveler_2
		}
	}

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_traveler_1_desc
			}
			triggered_desc = {
				trigger = {
					trigger_if = {
						limit = { has_trait = lifestyle_traveler }
						has_trait_xp = {
							trait = lifestyle_traveler
							track = travel
							value < 50
						}
						has_trait_xp = {
							trait = lifestyle_traveler
							track = danger
							value < 50
						}
					}
				}
				desc = trait_traveler_1_character_desc
			}
			triggered_desc = {
				trigger = {
					has_trait = lifestyle_traveler
					OR = {
						has_trait_xp = {
							trait = lifestyle_traveler
							track = travel
							value = 100
						}
						has_trait_xp = {
							trait = lifestyle_traveler
							track = danger
							value = 100
						}
					}
				}
				desc = trait_traveler_3_character_desc
			}
			desc = trait_traveler_2_character_desc
		}
	}

	tracks = {
		travel = {
			trait_second_level = {
				character_travel_speed_mult = 0.05
				learning = 1
				diplomacy = 1
				health = 0.05
				monthly_wanderer_lifestyle_xp_gain_mult = 0.2
			}
			trait_third_level = {
				character_travel_speed_mult = 0.1
				learning = 1
				diplomacy = 1
				health = 0.05
				monthly_wanderer_lifestyle_xp_gain_mult = 0.2
			}		
		}
		danger = {
			trait_second_level = {
				character_travel_safety_mult = 0.05
				prowess = 1
				stewardship = 1
				travel_companion_opinion = 5
			}
			trait_third_level = {
				character_travel_safety_mult = 0.1
				prowess = 1
				stewardship = 1
				travel_companion_opinion = 5
			}
		}
	}	
}

############### FP3 TRAITS ##############

fp3_struggle_detractor = {
	icon = "fp3_struggle_detractor.dds"
	opposites = {
		fp3_struggle_supporter
	}

	shown_in_ruler_designer = no

	same_opinion = 10
	opposite_opinion = -30
	
	ai_war_cooldown = -0.5
	ai_war_chance = 5

	flag = can_foment_revolt_interaction
	flag = can_request_incursion_interaction
	flag = can_change_to_iranian_faith_decision

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_fp3_struggle_detractor_desc
			}
			triggered_desc = {
				trigger = { faith.religious_head_title ?= title:d_sunni }
				desc = trait_fp3_struggle_detractor_character_desc
			}
			desc = trait_fp3_struggle_detractor_non_orthodox_sunni_character_desc
		}
	}
}

fp3_struggle_supporter = {
	icon = "fp3_struggle_supporter.dds"
	opposites = {
		fp3_struggle_detractor
	}

	shown_in_ruler_designer = no

	flag = can_use_install_loyalist_cb
	
	same_opinion = 10
	opposite_opinion = -30

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_fp3_struggle_supporter_desc
			}
			triggered_desc = {
				trigger = { has_title = title:d_sunni }
				desc = trait_fp3_struggle_supporter_character_is_caliph_desc
			}
			desc = trait_fp3_struggle_supporter_character_desc
		}
	}
}

############### EP3 TRAITS ##############

# TRAITS TO TRACK HIPPODROME FACTION MEMBERS
charioteer_blue = {
	category = fame
	icon = "charioteer_blue.dds"
	opposites = {
		charioteer_green
		charioteer_white
		charioteer_red
	}
	
	shown_in_ruler_designer = no
	opposite_opinion = -10

	# AI Values
	ai_energy = 10
	
	name = trait_charioteer_blue

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_charioteer_blue_desc
			}
			triggered_desc = {
				trigger = {
					trigger_if = {
						limit = { has_trait = charioteer_blue }
						has_trait_xp = {
							trait = charioteer_blue
							value < 40
						}
					}
				}
				desc = trait_charioteer_blue_1_character_desc
			}
			triggered_desc = {
				trigger = {
					has_trait_xp = {
						trait = charioteer_blue
						value >= 90
					}
				}
				desc = trait_charioteer_blue_3_character_desc
			}
			desc = trait_charioteer_blue_2_character_desc
		}
	}

	track = {
		50 = {
			character_travel_speed_mult = 0.05
			prowess = 1
			health = 0.05
		}
		100 = {
			character_travel_speed_mult = 0.1
			prowess = 1
			health = 0.05
		}		
	}
}

charioteer_green = {
	category = fame
	icon = "charioteer_green.dds"
	opposites = {
		charioteer_blue
		charioteer_white
		charioteer_red
	}
	
	shown_in_ruler_designer = no
	opposite_opinion = -10

	# AI Values
	ai_energy = 10
	
	name = trait_charioteer_green

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_charioteer_green_desc
			}
			triggered_desc = {
				trigger = {
					trigger_if = {
						limit = { has_trait = charioteer_green }
						has_trait_xp = {
							trait = charioteer_green
							value < 40
						}
					}
				}
				desc = trait_charioteer_green_1_character_desc
			}
			triggered_desc = {
				trigger = {
					has_trait_xp = {
						trait = charioteer_green
						value >= 90
					}
				}
				desc = trait_charioteer_green_3_character_desc
			}
			desc = trait_charioteer_green_2_character_desc
		}
	}

	track = {
		50 = {
			character_travel_speed_mult = 0.05
			prowess = 1
			health = 0.05
		}
		100 = {
			character_travel_speed_mult = 0.1
			prowess = 1
			health = 0.05
		}		
	}
}

charioteer_white = {
	category = fame
	icon = "charioteer_white.dds"
	opposites = {
		charioteer_blue
		charioteer_green
		charioteer_red
	}
	
	shown_in_ruler_designer = no
	opposite_opinion = -10

	# AI Values
	ai_energy = 10
	
	name = trait_charioteer_white

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_charioteer_white_desc
			}
			triggered_desc = {
				trigger = {
					trigger_if = {
						limit = { has_trait = charioteer_white }
						has_trait_xp = {
							trait = charioteer_white
							value < 40
						}
					}
				}
				desc = trait_charioteer_white_1_character_desc
			}
			triggered_desc = {
				trigger = {
					has_trait_xp = {
						trait = charioteer_white
						value >= 90
					}
				}
				desc = trait_charioteer_white_3_character_desc
			}
			desc = trait_charioteer_white_2_character_desc
		}
	}

	track = {
		50 = {
			character_travel_speed_mult = 0.05
			prowess = 1
			health = 0.05
		}
		100 = {
			character_travel_speed_mult = 0.1
			prowess = 1
			health = 0.05
		}		
	}
}

charioteer_red = {
	category = fame
	icon = "charioteer_red.dds"
	opposites = {
		charioteer_blue
		charioteer_white
		charioteer_green
	}
	
	shown_in_ruler_designer = no
	opposite_opinion = -10

	# AI Values
	ai_energy = 10

	name = trait_charioteer_red

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_charioteer_red_desc
			}
			triggered_desc = {
				trigger = {
					trigger_if = {
						limit = { has_trait = charioteer_red }
						has_trait_xp = {
							trait = charioteer_red
							value < 40
						}
					}
				}
				desc = trait_charioteer_red_1_character_desc
			}
			triggered_desc = {
				trigger = {
					has_trait_xp = {
						trait = charioteer_red
						value >= 90
					}
				}
				desc = trait_charioteer_red_3_character_desc
			}
			desc = trait_charioteer_red_2_character_desc
		}
	}

	track = {
		50 = {
			character_travel_speed_mult = 0.05
			prowess = 1
			health = 0.05
		}
		100 = {
			character_travel_speed_mult = 0.1
			prowess = 1
			health = 0.05
		}		
	}
}

# GOVERNOR TRAIT
governor = {
	category = fame
	icon = governor.dds

	# Modifiers
	track = {
		25 = {
			monthly_influence = 1
			stewardship = 1
			
			culture_modifier = {
				parameter = governor_trait_gives_counter_resistance
				counter_resistance = governor_trait_counter_bonus_value
			}
		}
		50 = {
			monthly_influence = 1
			diplomacy = 1
			
			culture_modifier = {
				parameter = governor_trait_gives_counter_resistance
				counter_resistance = governor_trait_counter_bonus_value
			}
		}
		75 = {
			monthly_influence = 1
			martial = 1
			intrigue = 1
			
			culture_modifier = {
				parameter = governor_trait_gives_counter_resistance
				counter_resistance = governor_trait_counter_bonus_value
			}
		}
		100 = {
			monthly_influence = 2
			diplomacy = 1
			martial = 1
			stewardship = 1
			intrigue = 1
			
			culture_modifier = {
				parameter = governor_trait_gives_counter_resistance
				counter_resistance = governor_trait_counter_bonus_value
			}
		}
	}
	
	#monthly_track_xp_degradation = { change = 0.4 }
	
	ruler_designer_cost = 40
	
	# AI Values
	ai_rationality = 10

	# Loc
	name = {
		first_valid = {
			#Kokushi - Japan flavor
			triggered_desc = {
				trigger = {
					exists = this
					top_liege.culture ?= { has_cultural_pillar = heritage_japonic }
					is_male = yes
				}
				desc = count_administrative_male_japanese
			}
			triggered_desc = {
				trigger = {
					exists = this
					top_liege.culture ?= { has_cultural_pillar = heritage_japonic }
					is_female = yes
				}
				desc = count_administrative_female_japanese
			}
			#Strategos - Byz flavor
			triggered_desc = {
				trigger = {
					exists = this
					top_liege ?= { culture = { has_cultural_pillar = heritage_byzantine } }
					is_male = yes
				}
				desc = duke_administrative_male_byzantine_group
			}
			triggered_desc = {
				trigger = {
					exists = this
					top_liege ?= { culture = { has_cultural_pillar = heritage_byzantine } }
					is_female = yes
				}
				desc = duke_administrative_female_byzantine_group
			}
			#Governor - Default
			triggered_desc = {
				trigger = {
					exists = this
					is_female = yes
				}
				desc = duke_administrative_female
			}
			desc = duke_administrative_male
		}
	}

	desc = {
		first_valid = {
			#The trait can never go higher than the first level if it's not assigned to a character
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_governor_desc
			}
			triggered_desc = {
				trigger = {
					has_trait_xp = {
						trait = governor
						value >= 75
					}
				}
				desc = trait_governor_3_character_desc
			}
			triggered_desc = {
				trigger = {
					has_trait_xp = {
						trait = governor
						value >= 25
					}
				}
				desc = trait_governor_2_character_desc
			}
			desc = trait_governor_1_character_desc
		}
	}
}

#FRANKOKRATIA TRAIT
despoiler_of_byzantium = {
	category = fame
	shown_in_ruler_designer = no
	
	martial = 1
	prowess = 2

	dread_baseline_add = 10
	siege_phase_time = -0.25
	men_at_arms_maintenance_per_dread_mult = -0.0025
	knight_effectiveness_per_dread = 0.002
	county_opinion_add = -10
	clergy_opinion = -15

	culture_modifier = {
		parameter = faith_warrior_traits_more_valued
		monthly_prestige = 1
	}
	
	icon = despoiler_of_byzantium.dds

	name =  trait_despoiler_of_byzantium

	desc = trait_despoiler_of_byzantium_desc
	
	ai_compassion = -10
	ai_greed = 10
	ai_honor = -10
}

#EL CID TRAIT
campeador = {
	category = fame
	shown_in_ruler_designer = no

	martial = 2
	prowess = 4

	monthly_prestige = 0.2

	culture_modifier = {
		parameter = prowess_traits_more_valued
		same_culture_opinion = 4
		monthly_prestige = 0.2
	}

	icon = campeador.dds

	name =  trait_campeador

	desc = trait_campeador_desc
	
	ai_honor = 20
}

# Wallada's unique trait: Violet Poet
violet_poet = {
	category = fame
	icon = violet_poet.dds
	shown_in_ruler_designer = no 

	attraction_opinion = 10
	seduce_scheme_phase_duration_add = minor_scheme_phase_duration_bonus_value

	culture_modifier = {
		parameter = poet_trait_gives_bonuses
		monthly_prestige_gain_mult = 0.05
		owned_personal_scheme_success_chance_add = 10
	}

	culture_modifier = {
		parameter = poet_trait_romance_bonuses
		attraction_opinion = 15
		courting_scheme_phase_duration_add = minor_scheme_phase_duration_bonus_value
	}
	
	track = {
		33 = { #Celebrated
			attraction_opinion = 10
			diplomacy_per_prestige_level = 1
			seduce_scheme_phase_duration_add = minor_scheme_phase_duration_bonus_value
			courting_scheme_phase_duration_add = minor_scheme_phase_duration_bonus_value
		}
		66 = { #Distinguished
			attraction_opinion = 10
			intrigue_per_prestige_level = 1
			seduce_scheme_phase_duration_add = minor_scheme_phase_duration_bonus_value
			courting_scheme_phase_duration_add = minor_scheme_phase_duration_bonus_value
		}
		100 = { #Laureate
			attraction_opinion = 20
			learning_per_prestige_level = 1
			seduce_scheme_phase_duration_add = minor_scheme_phase_duration_bonus_value
			courting_scheme_phase_duration_add = minor_scheme_phase_duration_bonus_value
		}
	}

	# AI Values
	ai_energy = 10
	ai_sociability = 10

	# Loc
	name = trait_violet_poet
	desc = trait_violet_poet_desc
}

# The Knight of the Swan
knight_errant = {
	category = fame
	icon = {
		first_valid = {
			triggered_desc = { # If no character exists
				trigger = {
					NOT = { exists = this }
				}
				desc = knight_of_the_swan.dds
			}
			triggered_desc = {
				trigger = {
					location = {
						geographical_region = world_europe
					}
				}
				desc = knight_of_the_swan.dds
			}
			triggered_desc = {
				trigger = {
					location = {
						OR = {
							geographical_region = world_india
							geographical_region = world_burma
							geographical_region = ghw_region_caucasus
							geographical_region = world_asia_china
							geographical_region = world_asia_japan
							geographical_region = world_asia_korea
							geographical_region = world_asia_southeast
						}
					}
				}
				desc = knight_of_the_tiger.dds
			}
			triggered_desc = {
				trigger = {
					location = {
						geographical_region = world_africa
					}
				}
				desc = knight_of_the_lion.dds
			}
			desc = knight_of_the_swan.dds
		}
	}
	shown_in_ruler_designer = yes

	ruler_designer_cost = 75

	knight_limit = 2
	knight_effectiveness_per_prowess = 0.01
	glory_hound_opinion = 15

	culture_modifier = {
		parameter = knight_errant_trait_bonuses
		monthly_prestige_gain_mult = 0.02
	}
	
	track = {
		50 = { # Defender
			prowess_per_prestige_level = 1
			knight_limit = 1
			men_at_arms_limit = 1
			culture_modifier = {
				parameter = knight_errant_trait_bonuses
				tourney_participant_xp_gain_mult = 0.15
			}
		}
		100 = { # Rightdoer
			prowess_per_prestige_level = 2
			knight_limit = 2
			men_at_arms_limit = 2
			culture_modifier = {
				parameter = knight_errant_trait_bonuses
				tourney_participant_xp_gain_mult = 0.25
			}
		}
	}

	# AI Values
	ai_energy = 10
	ai_sociability = 10

	# Loc
	name = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_knight_errant
			}
			desc = trait_knight_errant_character
		}
	}
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_knight_errant_desc
			}
			desc = trait_knight_errant_character_desc
		}
	}
}
#
#the_wake = {
#	category = lifestyle
#	icon = "the_wake.dds"
#
#	shown_in_ruler_designer = no
#
#	opinion_of_different_culture = -10
#	wetlands_travel_danger = -100
#	character_travel_speed = 15
#
#	# AI Values
#	ai_vengefulness = 100
#
#	name = {
#		first_valid = {
#			triggered_desc = {
#				trigger = {
#					exists = this
#					has_trait_xp = {
#						trait = the_wake
#						value = 100
#					}
#				}
#				desc = the_wake_5
#			}
#			triggered_desc = {
#				trigger = {
#					exists = this
#					has_trait_xp = {
#						trait = the_wake
#						value >= 75
#					}
#				}
#				desc = the_wake_4
#			}
#			triggered_desc = {
#				trigger = {
#					exists = this
#					has_trait_xp = {
#						trait = the_wake
#						value >= 50
#					}
#				}
#				desc = the_wake_3
#			}
#			triggered_desc = {
#				trigger = {
#					exists = this
#					has_trait_xp = {
#						trait = the_wake
#						value >= 25
#					}
#				}
#				desc = the_wake_2
#			}
#			desc = the_wake_1
#		}
#	}
#
#	desc = {
#		first_valid = {
#			triggered_desc = {
#				trigger = {
#					exists = this
#					has_trait_xp = {
#						trait = the_wake
#						value = 100
#					}
#				}
#				desc = the_wake_5_desc
#			}
#			triggered_desc = {
#				trigger = {
#					exists = this
#					has_trait_xp = {
#						trait = the_wake
#						value >= 75
#					}
#				}
#				desc = the_wake_4_desc
#			}
#			triggered_desc = {
#				trigger = {
#					exists = this
#					has_trait_xp = {
#						trait = the_wake
#						value >= 50
#					}
#				}
#				desc = the_wake_3_desc
#			}
#			triggered_desc = {
#				trigger = {
#					exists = this
#					has_trait_xp = {
#						trait = the_wake
#						value >= 25
#					}
#				}
#				desc = the_wake_2_desc
#			}
#			desc = the_wake_1_desc
#		}
#	}
#
#	track = {
#		25 = {
#			martial = 1
#			wetlands_attrition_mult = -0.1
#			wetlands_advantage = 2
#			wetlands_supply_limit_mult = 0.1
#			norman_opinion = -5
#		}
#		50 = {
#			martial = 1
#			wetlands_attrition_mult = -0.2
#			wetlands_advantage = 3
#			wetlands_supply_limit_mult = 0.2
#			norman_opinion = -5
#		}
#		75 = {
#			martial = 1
#			prowess = 1
#			wetlands_attrition_mult = -0.2
#			wetlands_advantage = 1
#			max_combat_roll = 2
#			wetlands_supply_limit_mult = 0.2
#			norman_opinion = -10
#			dread_baseline_add = 5
#		}	
#		100 = {
#			martial = 2
#			prowess = 2
#			wetlands_supply_limit_mult = 0.1
#			norman_opinion = -15
#			uncontrolled_province_advantage = 5
#			raid_speed = 0.5
#			dread_baseline_add = 15
#		}
#	}
#}

immortal = {
	icon = "immortal.dds"
	# This is definitely a very clever allusion to the 10k immortals and not just landing arbitrarily on a certain number of zeros.
	ruler_designer_cost = 10000

	opposites = { incapable }
	
	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_immortal_desc
			}
			desc = trait_immortal_character_desc
		}
	}

	immortal = yes
	# Dummy flags — just here for loc really.
	flag = is_immortal
	flag = immortal_visuals
	flag = immortal_fertility
	flag = immortal_incapability
	long_reign_bonus_mult = -1000
	no_prowess_loss_from_age = yes
}

lifestyle_wayfarer = {
	category = lifestyle

	diplomacy = 2
	prowess_per_prestige_level = 1
	stress_loss_per_prestige_level = 0.05

	ruler_designer_cost = 50
}

lifestyle_voyager = {
	category = lifestyle

	stewardship = 2
	character_travel_speed = 10
	monthly_prestige = 0.25
	diplomatic_range_mult = 0.15

	ruler_designer_cost = 50
}

lifestyle_surveyor = {
	category = lifestyle

	stewardship = 2
	development_growth_factor = 0.1
	county_fertility_growth_mult = small_county_fertility_growth_gain
	long_reign_bonus_mult = 0.25
	character_travel_safety = 10

	ruler_designer_cost = 50

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					exists = this
					has_government = landless_adventurer_government
				}
				desc = trait_lifestyle_surveyor_adventurer_desc
			}
			desc = trait_lifestyle_surveyor_desc
		}
	}
}

#MPO
nomadic_philosophy = {
	category = lifestyle
	flag = nomadic_philosophy_maa_trait
	flag = nomadic_philosophy_introduce_heir
	flag = can_recruit_open_specialist_trait
	flag = unlock_voluntary_laampdom_trait
	flag = no_demand_conversion_actor_trait
	flag = nomadic_philosophy_inheritance_trait
	flag = nomadic_philosophy_maa
	flag = nomadic_philosophy_cheaper_culture_convert
	flag = nomadic_philosophy_cheaper_to_hybridize
	flag = nomadic_philosophy_easier_to_hybridize

	shown_in_ruler_designer = no

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_nomadic_philosophy_desc
			}
			desc = trait_nomadic_philosophy_character_desc
		}
	}

	different_culture_opinion = 10
	different_faith_opinion = 10
	different_faith_county_opinion_mult = -0.25
}

lifestyle_seasoned_pastor = {
	category = lifestyle

	shown_in_ruler_designer = no

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_lifestyle_seasoned_pastor_desc
			}
			desc = trait_lifestyle_seasoned_pastor_character_desc
		}
	}

	county_fertility_growth_mult = 0.2
}

# Generic version of Descendant of Saoshyant, Mahdi, Messiah, etc. This is automatically granted to all members of a dynasty with "Divine Blood".
golden_lineage = {
	category = fame
	
	vassal_limit = 200
	herd_capacity_mult = 0.2
	cowed_vassal_herd_contribution_mult = 0.2
	cowed_vassal_levy_contribution_mult = 0.2
	cowed_vassal_tax_contribution_mult = 0.2
	dread_gain_mult = 0.1
	flag = initial_legitimacy_boost
	
	shown_in_ruler_designer = no

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_golden_lineage_desc
			}
			desc = trait_golden_lineage_character_desc
		}
	}

	inherit_chance = 100
	parent_inheritance_sex = male
	inherit_from_real_father = no
}

############### TGP TRAITS ##############

#Confucian trait - are you learned in the ways?
confucian_education = {
	minimum_age = 16
	category = fame

	learning = 1

	same_opinion = 10
	
	ruler_designer_cost = 15

	#Also gives discount to converting to Confucianism

	culture_modifier = {
		parameter = scholar_official_trait_bonuses
		monthly_merit_mult = 0.1
		same_culture_opinion = 5
	}
	
	track = {
		20 = {
			learning = 1
			monthly_lifestyle_xp_gain_mult = 0.04
			confucianism_religion_opinion = 5
			ai_sociability = 5
			ai_compassion = 5
		}
		40 = {
			stewardship = 1
			monthly_lifestyle_xp_gain_mult = 0.04
			ai_sociability = 5
			ai_compassion = 5
		}
		60 = {
			learning = 1
			monthly_lifestyle_xp_gain_mult = 0.04
			confucianism_religion_opinion = 5
			ai_sociability = 5
			ai_compassion = 5
		}
		80 = {
			stewardship = 1
			monthly_lifestyle_xp_gain_mult = 0.04
			ai_sociability = 5
			ai_compassion = 5
		}
		100 = {
			learning = 1
			confucianism_religion_opinion = 5
			monthly_lifestyle_xp_gain_mult = 0.04
			ai_sociability = 5
			ai_compassion = 5
		}
	}


	# Loc
	name = {
		first_valid = {
			#Immaculate Sage
			triggered_desc = {
				trigger = {
					exists = this
					has_trait_xp = {
						trait = confucian_education
						value = 100
					}
				}
				desc = trait_confucian_education_5
			}
			#Moral Paragon
			triggered_desc = {
				trigger = {
					exists = this
					has_trait_xp = {
						trait = confucian_education
						value >= 80
					}
				}
				desc = trait_confucian_education_4
			}
			#Virtuous Ethicist
			triggered_desc = {
				trigger = {
					exists = this
					has_trait_xp = {
						trait = confucian_education
						value >= 60
					}
				}
				desc = trait_confucian_education_3
			}
			#Studious Classicist
			triggered_desc = {
				trigger = { 
					exists = this
					has_trait_xp = {
						trait = confucian_education
						value >= 40
					}
				}
				desc = trait_confucian_education_2
			}
			#Confused Confucian
			triggered_desc = {
				trigger = {
					exists = this
					has_trait_xp = {
						trait = confucian_education
						value = 20
					}
				}
				desc = trait_confucian_education_1
			}
			#Confucian Education
			desc = trait_confucian_education
		}
	}

	# Loc
	desc = {
		first_valid = {
			#The trait can never go higher than the first level if it's not assigned to a character
			triggered_desc = {
				trigger = { 
					NOT = { exists = this } 
				}
			}
			#Immaculate Sage
			triggered_desc = {
				trigger = {
					exists = this
					has_trait_xp = {
						trait = confucian_education
						value = 80
					}
				}
			}
			#Moral Paragon
			triggered_desc = {
				trigger = {
					exists = this
					has_trait_xp = {
						trait = confucian_education
						value >= 60
					}
				}
				desc = trait_confucian_education_4_desc
			}
			#Virtuous Ethicist
			triggered_desc = {
				trigger = {
					exists = this
					has_trait_xp = {
						trait = confucian_education
						value >= 40
					}
				}
				desc = trait_confucian_education_3_desc
			}
			#Studious Classicit
			triggered_desc = {
				trigger = { 
					exists = this
					has_trait_xp = {
						trait = confucian_education
						value >= 20
					}
				}
				desc = trait_confucian_education_2_desc
			}
			#Genuine Confucian
			triggered_desc = {
				trigger = { 
					exists = this
					has_trait_xp = {
						trait = confucian_education
						value >= 20
					}
				}
				desc = trait_confucian_education_1_desc
			}
			#Confused Confucian
			desc = trait_confucian_education_desc
		}
	}

	ai_zeal = 10
}

### TGP

former_emperor = {
	name = {
		first_valid = {
			triggered_desc = {
				trigger = { NOT = { exists = this } }
				desc = trait_former_emperor_male
			}
			triggered_desc = {
				trigger = {
					is_male = yes
					culture = { has_cultural_pillar = heritage_japonic } 
				}
				desc = trait_former_tenno_male
			}
			triggered_desc = {
				trigger = { is_male = yes }
				desc = trait_former_emperor_male
			}
			triggered_desc = {
				trigger = { culture = { has_cultural_pillar = heritage_japonic } }
				desc = trait_former_tenno_female
			}
			desc = trait_former_emperor_female
		}
	}

	category = fame
	
	ai_boldness = 25
	ai_energy = -25
	monthly_prestige = 0.25
	monthly_influence = 0.25
	
	shown_in_ruler_designer = no
	
	desc = trait_former_emperor_desc
}

## TGP Stress Trait

burdened = {
	category = fame
	monthly_merit_mult = -0.3
	governor_xp_gain_mult = -0.3
	learning = -2
	stress_loss_mult = 0.2
	flag = can_offer_strong_hook_to_agents

	ruler_designer_cost = -10

	desc = {
		first_valid = {
			triggered_desc = {
				trigger = {
					NOT = { exists = this }
				}
				desc = trait_burdened_desc
			}
			desc = trait_burdened_character_desc
		}
	}

	ai_energy = low_negative_ai_value
	ai_rationality = low_negative_ai_value
	ai_vengefulness = low_negative_ai_value
	ai_compassion = low_positive_ai_value
	ai_sociability = medium_positive_ai_value

	compatibility = {
		compassionate = @neg_compat_low
		gregarious = @neg_compat_low
		calm = @neg_compat_low
	}
}
