﻿#BASE_HERD_CONVERSION_RATE = 0.05 	# base herd conversion rate

NCharacter = {
	# values for randomly generated characters they'll be set to BASE + random within SPAN
	MALE_RANDOM_AGE_BASE = 16
	MALE_RANDOM_AGE_SPAN = 20
	FEMALE_RANDOM_AGE_BASE = 16
	FEMALE_RANDOM_AGE_SPAN = 16

	RANDOM_PERSONALITY_TRAITS_BASE = 3
	RANDOM_PERSONALITY_TRAITS_SPAN = 0
	RANDOM_CHARACTER_DIPLOMACY_MIN = 0
	RANDOM_CHARACTER_DIPLOMACY_MAX = 10
	RANDOM_CHARACTER_MARTIAL_MIN = 0
	RANDOM_CHARACTER_MARTIAL_MAX = 10
	RANDOM_CHARACTER_STEWARDSHIP_MIN = 0
	RANDOM_CHARACTER_STEWARDSHIP_MAX = 10
	RANDOM_CHARACTER_INTRIGUE_MIN = 0
	RANDOM_CHARACTER_INTRIGUE_MAX = 10
	RANDOM_CHARACTER_LEARNING_MIN = 0
	RANDOM_CHARACTER_LEARNING_MAX = 10
	RANDOM_CHARACTER_PROWESS_MIN = 0
	RANDOM_CHARACTER_PROWESS_MAX = 10
	RANDOM_CHARACTER_MIN_FERTILITY = 0.5
	RANDOM_CHARACTER_MAX_FERTILITY = 0.6

	RANDOM_CHARACTER_MIN_HEALTH = 4.0
	RANDOM_CHARACTER_MAX_HEALTH = 5.0
	RANDOM_CHARACTER_AGE_MIN_HEALTH = 2.5 # This is the minimum starting base health characters get after adjustments for age

	MAX_STRESS_LEVEL = 3			# The maximum stress level
	STRESS_PER_LEVEL = 100			# Stress per level

	MAX_DREAD = 100
	BASE_DREAD = 0
	DREAD_MONTHLY_CHANGE = 0.5		# dread is drifiting changing by this value towards character's base dread value each month
	BOLD_LEVEL_COWED = 45			# A boldness level above this value will be considered as cowed.
	BOLD_LEVEL_INTIMIDATED = 20		# A boldness level above this value will be considered as intimidated.

	MAX_TYRANNY = 1000				# maximum tyranny value a character can have
	TYRANNY_MONTHLY_CHANGE = -0.25	# tyranny is changing by this value each month

	MAX_PROVISIONS = 2500			# maximum provisions value a character can have
	PROVISIONS_LOW_WARNING = 500		# when travel planner should warn about provisions running low

	BASE_HERD_CONVERSION_RATE = 0.05 	# base herd conversion rate
	BASE_HERD_CAPACITY = { 				# base herd capacity for different title tiers
		0 		# Unlanded
		500 	# Barony
		3000 	# County
		5000 	# Duchy
		15000 	# Kingdom
		20000 	# Empire
		20000 	# Hegemony
	}
	GOLD_FROM_HERD_FACTOR = 0.0005 		# The amount of herd that provides monthly gold income

	BASE_HERDER_GAIN_PER_COUNTY = 1.0 		# Base monthly herd gain for herders | ( NCountyData::MAX_COUNTY_FERTILITY / CountyFertility) * BASE_HERDER_GAIN_PER_COUNTY

	MAX_STRIFE_OPINION = 100				# maximum strife opinion value a character can have
	STRIFE_OPINION_MONTHLY_CHANGE = -0.2	# strife opinion is changing by this value each month

	BASE_FERTILITY = 0.5
	BASE_HEALTH = 5.0

	# experience needed for piety/prestige/influence levels - first/negative level requires 1000, then 350 etc.
	# evety character by default starts at respective ZERO_LEVEL with enough experience for it
	LEVELS_PIETY = { 1000 1500 2500 4500 8500 13000 17000 22500 }
	LEVELS_PRESTIGE = { 1000 2000 5000 10000 25000 }
	LEVELS_INFLUENCE = { 1000 2000 4000 8000 16000 }
	LEVELS_MERIT = { 100 1000 2000 3500 5500 8500 12000 17000 23000 }
	
	# default max level index (0-based) for governments. Can be overridden with field currency_levels_cap in the government type
	DEFAULT_PIETY_LEVEL_CAP = 5
	DEFAULT_PRESTIGE_LEVEL_CAP = 5
	DEFAULT_INFLUENCE_LEVEL_CAP = 5
	DEFAULT_MERIT_LEVEL_CAP = 1
	# when characters drop a level in piety/prestige/influence, they retain progress toward new level, capped by these values
	LEVEL_DROP_MAX_RETAINED_PROGRESS_PIETY = 0.5
	LEVEL_DROP_MAX_RETAINED_PROGRESS_PRESTIGE = 0.5
	LEVEL_DROP_MAX_RETAINED_PROGRESS_INFLUENCE = 0.5
	LEVEL_DROP_MAX_RETAINED_PROGRESS_MERIT = 0.5
	# how many steps for the graphical level changes
	LEVELS_PIETY_GRAPHICAL_STEP = 1
	LEVELS_PRESTIGE_GRAPHICAL_STEP = 1
	LEVELS_INFLUENCE_GRAPHICAL_STEP = 1
	LEVELS_MERIT_GRAPHICAL_STEP = 1
	# what level is considered to be the "zero" level
	PIETY_ZERO_LEVEL = 1
	PRESTIGE_ZERO_LEVEL = 1
	INFLUENCE_ZERO_LEVEL = 1
	MERIT_ZERO_LEVEL = 0

	TODDLER_AGE = 3
	CHILDHOOD_AGE = 6
	ADOLESCENCE_AGE = 12
	MALE_ADULT_AGE = 16
	FEMALE_ADULT_AGE = 16
	MALE_ELDERLY_AGE = 50
	FEMALE_ELDERLY_AGE = 50
	BETROTHAL_TIMEOUT_AGE = 17
	MALE_ATTRACTION_CUTOFF_AGE = 65		# After this age, the attraction of traits no longer have any effect
	FEMALE_ATTRACTION_CUTOFF_AGE = 50	# After this age, the attraction of traits no longer have any effect

	#Health levels and descriptions for every level
	HEALTH_STATE_LEVELS_VALUES = {
		0.0
		1.0
		3.0
		5.0
		7.0
	}
	HEALTH_STATE_LEVELS_TEXTS = {
		"HEALTH_DYING"
		"HEALTH_NEAR_DEATH"
		"HEALTH_POOR"
		"HEALTH_FINE"
		"HEALTH_GOOD"
		"HEALTH_EXCELLENT"
	}

	#Skill levels and descriptions for every level
	#Skill levels in loc are defined in 00_basic_values.txt, due to current script limitations. DO NOT UPDATE THESE WITHOUT CHANGING THOSE, and vice versa.
	SKILL_LEVELS_VALUES = {
		4 #poor
		8 #avg
		12 #good
		16 #exc
		68 #nice
		69 #exc
	}
	SKILL_LEVELS_TEXTS = {
		"SKILL_TERRIBLE"
		"SKILL_POOR"
		"SKILL_AVERAGE"
		"SKILL_GOOD"
		"SKILL_EXCELLENT"
		"SKILL_NICE"
		"SKILL_EXCELLENT"
	}

	SKILL_MODIFIER_OFFSET = -8	# skill modifiers with offset add this from skill value (see common/modifiers/00_basic_modifiers.txt)

	# Standard RelationTo number of relations to show
	MAX_RELATIONS_TO_SHOW = 3
	# Standard RelationToShort number of relations to show
	MAX_RELATIONS_TO_SHOW_SHORT = 2

	MARRIAGE_TIER_DIFF_PRESTIGE_MULT = 100

	# Multiplied with distance
	FOCUS_CHILD_MIN_AGE = 6
	FOCUS_CHILD_MAX_CHANGES = 1
	FOCUS_ADULT_COOLDOWN_MONTHS = 60

	SKILL_SCALE_AGE = 16
	MAX_HEIR_TO_SHOWN = 4								# How many "Heir To" titles should we show?
	MAX_PARENT_STEPS_FOR_HEIR = 6						# If we can't find enough descendants, how many steps upwards can we try to search?
	MIN_HEIR_TO_FIND = 20								# How many heirs should we find before we stop finding more? Note that a higher number here can worsen performance
	MAX_HEIRS_IN_LINE_OF_SUCCESSION_TOOLTIP = 5			# How many heirs should we show in [LandedTitle.GetLineOfSuccessionDesc]
	MAX_APPOINTMENT_BY_LEVEL = 5						# Desired number of heirs in leveled appointment (meritocratic). Above that number it will discard people of lower level

	MAX_POTENTIAL_SPOUSES = 100000 #Number of entries shown in the marry off-interaction
	MONTHS_OF_INCOME_AT_START = 36 # Rulers will start with this many months worth of income

	# Note that when mixing prestige and gold MaA, it'll stop buying more once one reaches the goal
	# By spending, we mean that it'll try to match the maintenance when unraised and fully reinforced to this portion of their monthly balance
	# Newly landed rulers (except those that should inherit MaA if they're landed by inheritance) also get MaA based on this
	MAA_STARTING_EXPENSE_MIN = 0.2 # Rulers at game start will start out spending this much (or a bit more, as it'll overshoot) on men at arms
	MAA_STARTING_EXPENSE_MAX = 0.35 # Rulers will never start out spending more than this on men at arms. For poor rulers this can mean they end up under MAA_STARTING_EXPENSE_MIN if one more MaA would put them above the max
	MAA_STARTING_PRESTIGE_EXPENSE_MIN = 0.4 # Rulers at game start will start out spending this much prestige (or a bit more, as it'll overshoot) on men at arms
	MAA_STARTING_PRESTIGE_EXPENSE_MAX = 0.55 # Rulers will never start out spending more than this much prestige on men at arms. For prestige-poor rulers this can mean they end up under MAA_STARTING_PRESTIGE_EXPENSE_MIN if one more MaA would put them above the max
	MAA_STARTING_TREASURY_EXPENSE_MIN = 0.2 # Rulers at game start will start out spending this much treasury (or a bit more, as it'll overshoot) on men at arms
	MAA_STARTING_TREASURY_EXPENSE_MAX = 0.35 # Rulers will never start out spending more than this treasury on men at arms. For treasury-poor rulers this can mean they end up under MAA_STARTING_TREASURY_EXPENSE_MIN if one more MaA would put them above the max
	MAA_STARTING_BARTER_GOODS_EXPENSE_MIN = 0.1 # Rulers at game start will start out spending this much barter goods (or a bit more, as it'll overshoot) on men at arms
	MAA_STARTING_BARTER_GOODS_EXPENSE_MAX = 0.2 # Rulers will never start out spending more than this much barter goods on men at arms. For barter goods-poor rulers this can mean they end up under MAA_STARTING_BARTER_GOODS_EXPENSE_MIN if one more MaA would put them above the max
	MAA_STARTING_HERD_EXPENSE_MIN = 0.7 # Rulers at game start will start out spending this much herd (or a bit more, as it'll overshoot) on men at arms
	MAA_STARTING_HERD_EXPENSE_MAX = 0.9 # Rulers will never start out spending more than this much herd on men at arms. For herd-poor rulers this can mean they end up under MAA_STARTING_HERD_EXPENSE_MIN if one more MaA would put them above the max

	MAXIMUM_DIPLOMATIC_RANGE = 1000
	MAXIMUM_DIPLOMATIC_RANGE_RESTRICTED = 750	# Used if a game rule with the restricted_diplomatic_range flag is used
	HOOK_COOLDOWN_DURATION_YEARS = 5	# How many years do strong hooks go on cooldown when used?
	MAX_COUNTIES_IN_REALM_AS_DUKE = 30						# As a duke or below, the player (but not the AI) will suffer penalties when they go beyond this # of counties in their realm. They can form a kingdom to get the penalties to go away
	INCOME_PENALTY_PER_COUNTY_ABOVE_LIMIT = 0.05			# For each county above MAX_COUNTIES_IN_REALM_AS_DUKE, you get 10% less income

	FORCED_SUCCESSION_ELECTION_YEARS = 100	# For how long someone is forced to vote with another elector when using the force_vote_in_succession_election interaction

	MINIMUM_VALUE_FOR_PERSONALITY_DESCRIPTION = 25 # AI personality values ( ai_greed, etc) less than this are ignored when trying to build personality descriptions
	STRONG_VALUE_FOR_PERSONALITY_DESCRIPTION = 75	# AI personality values with higher values than this are getting the strong version in the personality descriptions
	MINIMUM_TIER_FOR_REGNAL_NUMBERING = 2	# What tier does someone have to be in order to use regnal numbering? 1 is baron, 5 is emperor

	PERCENTAGE_HOMOSEXUAL = 5.0				# chance (0-100%) of a randomly created character being homosexual
	PERCENTAGE_BISEXUAL = 5.0				# chance (0-100%) of a randomly created character being bisexual
	PERCENTAGE_ASEXUAL = 1.0				# chance (0-100%) of a randomly created character being asexual

	DESIGNATE_HEIR_DISPLAY_COST = 1000	# Prestige cost for designating heir. Actual cost is handled by the scripter interaction 'designate_heir'

	PRETENDERS_TO_TITLE = 5				# Max number of character stored to be the pretenders of a title (includes heir)

	PARTITION_SCORE_PER_OWN_COUNTY = 2		# How much score does a county you own contribute in Partition when selecting a title? The higher this is, the more we encourage getting a title you've already got land in
	PARTITION_SCORE_PER_OTHER_COUNTY = 1	# How much score does a county another heir owns take away in Partition when selecting a title? The higher this is, the more we encourage getting a title that other heirs don't have land in

	# How many concubines does a ruler of a given tier desire if their faith allows concubines
	DESIRED_CONCUBINES_PER_TIER = { 0 0 0 1 2 3 3 }
	PRESTIGE_LOSS_PER_MISSING_CONCUBINE = 0.1 # Monthly prestige loss per missing (fertile) concubine

	DEBT_MODIFIER_THRESHOLDS = { # When do the debt modifiers kick in, by months of income of debt
		# Match to the modifier debt_level_i and combat_debt_level_i. Starts with 0
		0 12 24 36 48 60 120 300 600 1200
	}
	TREASURY_DEBT_MODIFIER_THRESHOLDS = { # When do the debt modifiers kick in, by months of income of treasury debt
		# Match to the modifier treasury_debt_level_i and treasury_combat_debt_level_i. Starts with 0
		0 12 24 36 48 60 120 300 600 1200
	}

	COURT_GRANDEUR_MONTHLY_CHANGE = 0.2

	# chance (0-1) that a character created or picked from pool being of preferred gender for the
	# relevant gender preference law
	GENDER_PREFERENCE_PROBABILITY = 1.0

	OBESE_WEIGHT_VALUE = 50 # Greater than or equal to this and a character is considered obese
	MALNOURISHED_WEIGHT_VALUE = -50 # Less than or equal to this and a character is considered malnourished

	# On succession how much of the old ruler's legitimacy should be applied to their heir
	# Only applied if the title they inherit is a greater tier than their old title, a king inheriting
	# a duchy has their own legitimacy they already care about
	LEGITIMACY_INHERITED = 0.25

	MONTHLY_INFLUENCE_GAIN_ALLIED_TO_TOP_LIEGE = 1.5 # Monthly influence gained for admin rulers in admin realm if you are allied to your top liege
	MONTHLY_INFLUENCE_GAIN_ALLIED_TO_HOUSE_HEAD = 1 # Monthly influence gained for admin rulers when are allied to admin ruler house head
	MONTHLY_INFLUENCE_GAIN_BEING_GOVERNOR = 1 # Monthly influence gained in admin realm from being a governor
}
