﻿

#Legacy of the Junzi
tgp_chinese_legacy_1 = {
	legacy = tgp_china_legacy_track

	can_be_picked = {
		has_tgp_dlc_trigger = yes
		government_has_flag = government_has_merit
	} 

	character_modifier = {
		confucian_education_xp_gain_mult = 0.15
	}

	effect = { #Base Exam Advantages
		custom_description_no_bullet = { text = tgp_merit_legacy_advantage }
	}

	ai_chance = {
		value = 12
		if = {
			limit = {
				government_has_flag = government_has_merit
			}
			multiply = 10
		}
		if = {
			limit = {
				can_start_new_legacy_track_trigger = no
			}
			multiply = 0
		}
		# Start New Bloc
		if = {
			limit = {
				OR = {
					root.house = { has_house_modifier = trad_knowledge }
					root.house = { has_house_modifier = trad_duty }
					root.house = { has_house_modifier = trad_devotion }
				}
			}
			multiply = 20
		}
		if = {
			limit = {
				OR = {
					root.house = { has_house_modifier = trad_authority }
					root.house = { has_house_modifier = trad_influence }
					root.house = { has_house_modifier = trad_fortune }
				}
			}
			multiply = 10
		}
		# End New Bloc
	}
}

tgp_chinese_legacy_2 = {
	legacy = tgp_china_legacy_track

	can_be_picked = {
		has_tgp_dlc_trigger = yes
		government_has_flag = government_has_merit
	}

	effect = {
		if = {
			limit = {
				government_has_flag = government_is_celestial
			}
			custom_description_no_bullet = { text = tgp_dynasty_legacy_extra_disciple_limit }
		}
		custom_description_no_bullet = { text = tgp_dynasty_legacy_pick_career }
	}

	character_modifier = {
		monthly_merit_mult = 0.1
	}
}

tgp_chinese_legacy_3 = {
	legacy = tgp_china_legacy_track

	can_be_picked = {
		has_tgp_dlc_trigger = yes
		government_has_flag = government_has_merit
	}

	effect = {
		custom_description_no_bullet = { text = tgp_dynasty_legacy_governor_efficiency_bonus }
		custom_description_no_bullet = { text = tgp_dynasty_legacy_unlock_east_asian_estate_archive }
	}

	character_modifier = {
		
	}
}

tgp_chinese_legacy_4 = {
	legacy = tgp_china_legacy_track

	can_be_picked = {
		has_tgp_dlc_trigger = yes
		government_has_flag = government_has_merit
	}

	effect = {
		if = {
			limit = {
				government_has_flag = government_is_celestial
			}
			custom_description_no_bullet = { text = tgp_legacy_celestial_candidate_score_bonus }
		}
		else = {
			custom_description_no_bullet = { text = tgp_legacy_meritocratic_candidate_score_bonus }
		}
		custom_description_no_bullet = { text = tgp_legacy_powerfuL_family }
		if = {
			limit = {
				government_has_flag = government_is_celestial
			}
			custom_description_no_bullet = { text = tgp_dynasty_legacy_movement_power_bonus }
		}
		if = { #Invite to Movement
			limit = {
				government_has_flag = government_is_celestial
			}
			custom_description_no_bullet = { text = tgp_dynasty_legacy_invite_to_movement_bonus }
		}
	}

	character_modifier = {
		
	}
}


tgp_chinese_legacy_5 = {
	legacy = tgp_china_legacy_track

	can_be_picked = {
		has_tgp_dlc_trigger = yes
		government_has_flag = government_has_merit
	}

	effect = {
		if = {
			limit = {
				government_has_flag = government_is_celestial
			}
			custom_description_no_bullet = { text = tgp_dynasty_legacy_celestial_minister_aidee_bonus }
			custom_description_no_bullet = { text = tgp_dynasty_legacy_celestial_minister_aidee_discount }
			custom_description_no_bullet = { text = tgp_dynasty_legacy_influence_career_bonus }
		}
		custom_description_no_bullet = { text = tgp_dynasty_legacy_unlock_east_asian_estate_gate }
	}
	character_modifier = {
		monthly_influence_mult = 0.1
		max_political_schemes_add = 1
	}
}

#Japan - Elegance / Miyabi
tgp_japan_legacy_1 = {
	legacy = tgp_japan_legacy_track

	can_be_picked = {
		has_tgp_dlc_trigger = yes
		government_is_japanese_trigger = yes
	}

	character_modifier = {
		dynasty_opinion = 5
	}

	effect = {
		custom_description_no_bullet = { text = tgp_dynasty_legacy_same_dynasty_likelier_to_join_bloc } #Dynasty Members more Likely to Join Bloc
		custom_description_no_bullet = { text = tgp_dynasty_legacy_same_dynasty_increased_bloc_cohesion } #Bloc Cohesion
	}

	ai_chance = {
		value = 12
		if = {
			limit = {
				government_is_japanese_trigger = yes
			}
			multiply = 10
		}
		if = {
			limit = {
				can_start_new_legacy_track_trigger = no
			}
			multiply = 0
		}
		# Start New Bloc
		if = {
			limit = {
				OR = {
					root.house = { has_house_modifier = trad_pride }
					root.house = { has_house_modifier = trad_influence }
				}
			}
			add = 1000
		}
		# End New Bloc
	}
}

tgp_japan_legacy_2 = {
	legacy = tgp_japan_legacy_track

	can_be_picked = {
		has_tgp_dlc_trigger = yes
		government_is_japanese_trigger = yes
	}

	effect = {
		custom_description_no_bullet = { text = tgp_dynasty_legacy_can_hire_court_poet } #Unlocks Court Poet for Counts
		custom_description_no_bullet = { text = tgp_dynasty_legacy_court_poet_bonuses } #Court Poet Poems can increase Bloc Cohesion
		custom_description_no_bullet = { text = tgp_dynasty_legacy_unlock_poetry_collection }
	}

	character_modifier = {
		attraction_opinion = 5
		domicile_monthly_prestige_mult = 0.1
	}
}

tgp_japan_legacy_3 = {
	legacy = tgp_japan_legacy_track

	can_be_picked = {
		has_tgp_dlc_trigger = yes
		government_is_japanese_trigger = yes
	}

	effect = {
		custom_description_no_bullet = { text = tgp_dynasty_legacy_cheaper_to_host_festivals }

		custom_description_no_bullet = { text = tgp_dynasty_legacy_unlock_improve_house_relation_inside_bloc_interaction }
	}

	character_modifier = {
		prestige_level_impact_mult = 0.5
	}
}

tgp_japan_legacy_4 = {
	legacy = tgp_japan_legacy_track

	can_be_picked = {
		has_tgp_dlc_trigger = yes
		government_is_japanese_trigger = yes
	}

	effect = {
		custom_description_no_bullet = { text = tgp_dynasty_legacy_unlock_domicile_retainer_accomodations }
	}

	character_modifier = {
		domicile_monthly_influence_mult = 0.1
		domicile_monthly_gold_mult = 0.1
		domicile_build_speed = -0.1
	}
}

tgp_japan_legacy_5 = { #gunki monogatari
	legacy = tgp_japan_legacy_track

	can_be_picked = {
		has_tgp_dlc_trigger = yes
		government_is_japanese_trigger = yes
	}

	effect = {
		#Domicile Building
	}
	character_modifier = { #Samurai
		knight_limit = 5 #Considerable Boost for Soryo and lifts the penalty from Ritsuryo
		monthly_prestige_gain_per_knight_mult = 0.01
		knight_effectiveness_mult = 0.1
	}
}



#Southeast Asia
tgp_sea_legacy_1 = {
	legacy = tgp_southeast_asia_legacy_track

	#Travel Safety
	#Legitimacy from Pilgrimages and Visiting Capital Temples

	can_be_picked = {
		has_tgp_dlc_trigger = yes
		OR = { #Can be accessed by both Mandala and Wanua, useful mostly for those Wanuas that want to become Mandalas
			government_has_flag = government_is_mandala
			government_has_flag = government_is_wanua
		}
	}

	character_modifier = {
		character_travel_safety = 10
	}

	effect = {
		custom_description_no_bullet = { text = tgp_legitimacy_visit_capital_temples }
		custom_description_no_bullet = { text = tgp_legitimacy_pilgrimages }
	}

	ai_chance = {
		value = 12
		if = {
			limit = {
				OR = {
					government_has_flag = government_is_mandala
					government_has_flag = government_is_wanua
				}
			}
			multiply = 10
		}
		if = {
			limit = {
				can_start_new_legacy_track_trigger = no
			}
			multiply = 0
		}
		# Start New Bloc
		if = {
			limit = {
				OR = {
					root.house = { has_house_modifier = trad_devotion }
					root.house = { has_house_modifier = trad_peace }
				}
			}
			add = 1000
		}
		# End New Bloc
	}
}

tgp_sea_legacy_2 = {
	legacy = tgp_southeast_asia_legacy_track

	#Tribute Acceptance

	can_be_picked = {
		has_tgp_dlc_trigger = yes
		OR = {
			government_has_flag = government_is_mandala
			government_has_flag = government_is_wanua
		}
	}

	effect = {
		custom_description_no_bullet = { text = tgp_sea_legacy_tributary_acceptance }
	}

	character_modifier = {
		tributary_tax_mult = 0.1
		tributary_piety_contribution_mult = 0.1
		tributary_opinion = 10 #Easier to Hold on to Tributaries
	}
}

tgp_sea_legacy_3 = {
	legacy = tgp_southeast_asia_legacy_track

	#Project Investment

	can_be_picked = {
		has_tgp_dlc_trigger = yes
		OR = {
			government_has_flag = government_is_mandala
			government_has_flag = government_is_wanua
		}
	}

	effect = {
		if = {
			limit = {
				government_has_flag = government_is_wanua
			}
			custom_description_no_bullet = { text = tgp_sea_legacy_easier_to_become_mandala }
		}
		custom_description_no_bullet = { text = tgp_sea_legacy_more_likely_to_contribute_to_gp }
		custom_description_no_bullet = { text = tgp_sea_legacy_new_great_project_contributions }
	}

	character_modifier = {
		monthly_piety_from_buildings_mult = 0.10
	}
}

tgp_sea_legacy_4 = {
	legacy = tgp_southeast_asia_legacy_track

	#Devotion for Heirs

	can_be_picked = {
		has_tgp_dlc_trigger = yes
		OR = {
			government_has_flag = government_is_mandala
			government_has_flag = government_is_wanua
		}
	}

	effect = {
		custom_description_no_bullet = { text = tgp_sea_legacy_heir_succession_modifier }
	}

	character_modifier = {
		life_expectancy = 5
	}
}

tgp_sea_legacy_5 = {
	legacy = tgp_southeast_asia_legacy_track

	#Free Challenge Pass

	can_be_picked = {
		has_tgp_dlc_trigger = yes
		OR = {
			government_has_flag = government_is_mandala
			government_has_flag = government_is_wanua
		}
	}

	effect = {
		custom_description_no_bullet = { text = tgp_sea_legacy_pass_one_succession_challenge }
	}
	character_modifier = {
		legitimacy_gain_mult = 0.15
	}
}
