﻿nht_eloquent_authority_perk = {
	lifestyle = nht_leadership_lifestyle
	tree = nht_founder
	position = { 1 0 }
	icon = node_nht_leadership

	auto_selection_weight = {
		value = 11
		if = {
			limit = {
				more_lifestyles_education_submod_is_loaded = yes
				has_education_nht_leadership_trigger = yes
			}
			add = 1989
		}
		if = {
			limit = {
				more_lifestyles_education_submod_is_loaded = no
				has_education_stewardship_trigger = yes
			}
			add = 1989
		}
		if = {
			limit = {
				has_focus = nht_dynasty_focus
			}
			multiply = 5
		}
		if = {
			limit = {
				has_trait = diligent
			}
			multiply = 2
		}
		if = {
			limit = {
				NOR = { 
					has_game_rule = nht_secondary_lifestyle 
					has_game_rule = nht_secondary_lifestyle_no_xp
				}
				nht_can_start_new_lifestyle_tree_leadership_trigger = no
			}
			multiply = 0
		}		
	}

	character_modifier = {
		title_creation_cost_mult = -0.2
	}
}

nht_commerce_maestro_perk = {
	lifestyle = nht_leadership_lifestyle
	tree = nht_founder
	position = { 0 1 }
	icon = node_nht_leadership

	parent = nht_eloquent_authority_perk
	name = {
		first_valid = {
			triggered_desc = {
				trigger = { is_landless_adventurer = yes }
				desc = nht_commerce_maestro_perk_adventurer_name
			}
			desc = nht_commerce_maestro_perk_name
		}
	}

	government_character_modifier = {
		flag = government_is_landless_adventurer
		domicile_monthly_gold_add = 0.8
	}
	government_character_modifier = {
		flag = government_is_nomadic
		domicile_monthly_herd_add = 5
	}
	
	effect = {
		if = {
			limit = { 
				has_game_rule = nht_trade_agreement_interaction_enabled 
				NOR = { 
					culture = { has_cultural_parameter = nht_can_trade_freely_without_perk } 
					government_has_flag = government_is_landless_adventurer
				}
			}
			custom_description_no_bullet = { text = unlocks_nht_negotiate_trade_agreement_interaction_desc }
		}
		else = { add_character_modifier = nht_commerce_maestro_perk_modifier }
		if = {
			limit = { 
				culture = { has_cultural_parameter = nht_can_trade_freely_without_perk }
			}
			custom_description_no_bullet = { text = unlocks_nht_more_trade_agreement_interaction_desc }
		}
	}
}

nht_family_ties_perk = {
	lifestyle = nht_leadership_lifestyle
	tree = nht_founder
	position = { 0 2 }
	icon = node_nht_leadership

	parent = nht_commerce_maestro_perk
	
	character_modifier = {
		diplomacy = 1
		spouse_opinion = 15
		child_opinion = 10
	}
}


nht_mesmerizing_aura_perk = {
	lifestyle = nht_leadership_lifestyle
	tree = nht_founder
	position = { 0 3 }
	icon = node_nht_leadership

	parent = nht_family_ties_perk

	government_character_modifier = {
		flag = government_is_landless_adventurer
		invert_check = yes
		legitimacy_gain_mult = 0.05
		attraction_opinion = 10
		powerful_vassal_opinion = 5
	}
	government_character_modifier = {
		flag = government_is_landless_adventurer
		feudal_government_opinion = 10
		clan_government_opinion = 15
		administrative_government_opinion = 15
	}
}

nht_fortunate_predisposition_perk = {
	lifestyle = nht_leadership_lifestyle
	tree = nht_founder
	position = { 2 1 }
	icon = node_nht_leadership

	parent = nht_eloquent_authority_perk

	character_modifier = {
		genetic_trait_strengthen_chance = 0.05
		fertility = 0.1		
	}
}

nht_destiny_balance_perk = {
	lifestyle = nht_leadership_lifestyle
	tree = nht_founder
	position = { 2 2 }
	icon = node_nht_leadership

	parent = nht_fortunate_predisposition_perk

	character_modifier = {
		positive_inactive_inheritance_chance = 0.1
		negative_inactive_inheritance_chance = -0.10

	}
}

nht_inheritance_instinct_perk = {
	lifestyle = nht_leadership_lifestyle
	tree = nht_founder
	position = { 2 3 }
	icon = node_nht_leadership

	parent = nht_destiny_balance_perk
	name = {
		first_valid = {
			triggered_desc = {
				trigger = { is_landless_adventurer = yes }
				desc = nht_inheritance_instinct_perk_adventurer_name
			}
			desc = nht_inheritance_instinct_perk_name
		}
	}

	government_character_modifier = {
		flag = government_is_landless_adventurer
		attraction_opinion = 20
	}	
	effect = {
		if = {
			limit = {
				NOT = { government_has_flag = government_is_landless_adventurer }
				has_game_rule = nht_declare_as_heir_interaction_enabled 
			}
			custom_description_no_bullet = { text = unlocks_nht_declare_as_heir_interaction_desc }
		}
		else = { add_character_modifier = nht_inheritance_instinct_perk_modifier }
	}
}

nht_serendipity_touch_perk = {
	lifestyle = nht_leadership_lifestyle
	tree = nht_founder
	position = { 1 4 }
	icon = node_nht_leadership

	parent = nht_mesmerizing_aura_perk
	parent = nht_inheritance_instinct_perk

	character_modifier = {
		life_expectancy = 3
		health = 0.1
	}
}

nht_founder_perk = {
	lifestyle = nht_leadership_lifestyle
	tree = nht_founder
	position = { 1 5 }
	icon = nht_founder_perk

	parent = nht_serendipity_touch_perk
	trait = nht_founder
	effect = {
		add_trait_force_tooltip = nht_founder
	}
}