﻿
gpt_initial_xp_dip = {
	value = 0
	add = root.diplomacy
	if = {
		limit = {
			root.age >= 45
		}
		multiply = 6
		min = 20
	}
	else_if = {
		limit = {
			root.age >= 35
		}
		multiply = 5
		min = 15
	}
	else_if = {
		limit = {
			root.age >= 25
		}
		multiply = 4
		min = 10
	}
	else = { multiply = 3 }
	if = {
		limit = {
			calc_true_if = {
            	amount = 1
				has_trait = logistician
				has_trait = military_engineer
				has_trait = aggressive_attacker
				has_trait = unyielding_defender
				has_trait = flexible_leader
				has_trait = desert_warrior
				has_trait = jungle_stalker
				has_trait = reaver
				has_trait = reckless
				has_trait = holy_warrior
				has_trait = open_terrain_expert
				has_trait = rough_terrain_expert
				has_trait = forest_fighter
				has_trait = cautious_leader
				has_trait = organizer
				has_trait = winter_soldier
			}
		}
		multiply = 0.75
	}
	if = {
		limit = {
			NOR = {
				has_trait = logistician
				has_trait = military_engineer
				has_trait = aggressive_attacker
				has_trait = unyielding_defender
				has_trait = flexible_leader
				has_trait = desert_warrior
				has_trait = jungle_stalker
				has_trait = reaver
				has_trait = reckless
				has_trait = holy_warrior
				has_trait = open_terrain_expert
				has_trait = rough_terrain_expert
				has_trait = forest_fighter
				has_trait = cautious_leader
				has_trait = organizer
				has_trait = winter_soldier
			}
		}
		multiply = 0.5
	}
	multiply = 0.7
}
gpt_initial_xp_stw = {
	value = 0
	add = root.stewardship
	if = {
		limit = {
			root.age >= 45
		}
		multiply = 6
		min = 20
	}
	else_if = {
		limit = {
			root.age >= 35
		}
		multiply = 5
		min = 15
	}
	else_if = {
		limit = {
			root.age >= 25
		}
		multiply = 4
		min = 10
	}
	else = { multiply = 3 }
	if = {
		limit = {
			calc_true_if = {
            	amount = 1
				has_trait = logistician
				has_trait = military_engineer
				has_trait = aggressive_attacker
				has_trait = unyielding_defender
				has_trait = flexible_leader
				has_trait = desert_warrior
				has_trait = jungle_stalker
				has_trait = reaver
				has_trait = reckless
				has_trait = holy_warrior
				has_trait = open_terrain_expert
				has_trait = rough_terrain_expert
				has_trait = forest_fighter
				has_trait = cautious_leader
				has_trait = organizer
				has_trait = winter_soldier
			}
		}
		multiply = 0.75
	}
	if = {
		limit = {
			NOR = {
				has_trait = logistician
				has_trait = military_engineer
				has_trait = aggressive_attacker
				has_trait = unyielding_defender
				has_trait = flexible_leader
				has_trait = desert_warrior
				has_trait = jungle_stalker
				has_trait = reaver
				has_trait = reckless
				has_trait = holy_warrior
				has_trait = open_terrain_expert
				has_trait = rough_terrain_expert
				has_trait = forest_fighter
				has_trait = cautious_leader
				has_trait = organizer
				has_trait = winter_soldier
			}
		}
		multiply = 0.5
	}
	multiply = 0.7
}
gpt_initial_xp_mar = {
	value = 0
	add = root.martial
	if = {
		limit = {
			root.age >= 45
		}
		multiply = 6
		min = 20
	}
	else_if = {
		limit = {
			root.age >= 35
		}
		multiply = 5
		min = 15
	}
	else_if = {
		limit = {
			root.age >= 25
		}
		multiply = 4
		min = 10
	}
	else = { multiply = 3 }
	if = {
		limit = {
			calc_true_if = {
            	amount = 1
				has_trait = logistician
				has_trait = military_engineer
				has_trait = aggressive_attacker
				has_trait = unyielding_defender
				has_trait = flexible_leader
				has_trait = desert_warrior
				has_trait = jungle_stalker
				has_trait = reaver
				has_trait = reckless
				has_trait = holy_warrior
				has_trait = open_terrain_expert
				has_trait = rough_terrain_expert
				has_trait = forest_fighter
				has_trait = cautious_leader
				has_trait = organizer
				has_trait = winter_soldier
			}
		}
		multiply = 0.75
	}
	if = {
		limit = {
			NOR = {
				has_trait = logistician
				has_trait = military_engineer
				has_trait = aggressive_attacker
				has_trait = unyielding_defender
				has_trait = flexible_leader
				has_trait = desert_warrior
				has_trait = jungle_stalker
				has_trait = reaver
				has_trait = reckless
				has_trait = holy_warrior
				has_trait = open_terrain_expert
				has_trait = rough_terrain_expert
				has_trait = forest_fighter
				has_trait = cautious_leader
				has_trait = organizer
				has_trait = winter_soldier
			}
		}
		multiply = 0.5
	}
	multiply = 0.7
}
gpt_initial_xp_int = {
	value = 0
	add = root.intrigue
	if = {
		limit = {
			root.age >= 45
		}
		multiply = 6
		min = 20
	}
	else_if = {
		limit = {
			root.age >= 35
		}
		multiply = 5
		min = 15
	}
	else_if = {
		limit = {
			root.age >= 25
		}
		multiply = 4
		min = 10
	}
	else = { multiply = 3 }
	if = {
		limit = {
			calc_true_if = {
            	amount = 1
				has_trait = logistician
				has_trait = military_engineer
				has_trait = aggressive_attacker
				has_trait = unyielding_defender
				has_trait = flexible_leader
				has_trait = desert_warrior
				has_trait = jungle_stalker
				has_trait = reaver
				has_trait = reckless
				has_trait = holy_warrior
				has_trait = open_terrain_expert
				has_trait = rough_terrain_expert
				has_trait = forest_fighter
				has_trait = cautious_leader
				has_trait = organizer
				has_trait = winter_soldier
			}
		}
		multiply = 0.75
	}
	if = {
		limit = {
			NOR = {
				has_trait = logistician
				has_trait = military_engineer
				has_trait = aggressive_attacker
				has_trait = unyielding_defender
				has_trait = flexible_leader
				has_trait = desert_warrior
				has_trait = jungle_stalker
				has_trait = reaver
				has_trait = reckless
				has_trait = holy_warrior
				has_trait = open_terrain_expert
				has_trait = rough_terrain_expert
				has_trait = forest_fighter
				has_trait = cautious_leader
				has_trait = organizer
				has_trait = winter_soldier
			}
		}
		multiply = 0.5
	}
	multiply = 0.7
}
gpt_initial_xp_ler = {
	value = 0
	add = root.learning
	if = {
		limit = {
			root.age >= 45
		}
		multiply = 6
		min = 20
	}
	else_if = {
		limit = {
			root.age >= 35
		}
		multiply = 5
		min = 15
	}
	else_if = {
		limit = {
			root.age >= 25
		}
		multiply = 4
		min = 10
	}
	else = { multiply = 3 }
	if = {
		limit = {
			calc_true_if = {
            	amount = 1
				has_trait = logistician
				has_trait = military_engineer
				has_trait = aggressive_attacker
				has_trait = unyielding_defender
				has_trait = flexible_leader
				has_trait = desert_warrior
				has_trait = jungle_stalker
				has_trait = reaver
				has_trait = reckless
				has_trait = holy_warrior
				has_trait = open_terrain_expert
				has_trait = rough_terrain_expert
				has_trait = forest_fighter
				has_trait = cautious_leader
				has_trait = organizer
				has_trait = winter_soldier
			}
		}
		multiply = 0.75
	}
	if = {
		limit = {
			NOR = {
				has_trait = logistician
				has_trait = military_engineer
				has_trait = aggressive_attacker
				has_trait = unyielding_defender
				has_trait = flexible_leader
				has_trait = desert_warrior
				has_trait = jungle_stalker
				has_trait = reaver
				has_trait = reckless
				has_trait = holy_warrior
				has_trait = open_terrain_expert
				has_trait = rough_terrain_expert
				has_trait = forest_fighter
				has_trait = cautious_leader
				has_trait = organizer
				has_trait = winter_soldier
			}
		}
		multiply = 0.5
	}
	multiply = 0.7
}
gpt_initial_xp_dread = {
	value = 0
	if = { limit = { has_trait = paranoid } add = 4 }
	if = { limit = { has_trait = deceitful } add = 4 }
	if = { limit = { has_trait = vengeful } add = 8 }
	if = { limit = { has_trait = arbitrary } add = 8 }
	if = { limit = { has_trait = ambitious } add = 8 }
	if = { limit = { has_trait = wrathful } add = 12 }
	if = { limit = { has_trait = sadistic } add = 16 }
	if = { limit = { has_trait = compassionate } add = -12 }
	if = { limit = { has_trait = forgiving } add = -12 }
	if = { limit = { has_trait = calm } add = -8 }
	if = { limit = { has_trait = just } add = -8 }
	if = { limit = { has_trait = trusting } add = -4 }
	if = { limit = { has_trait = content } add = -4 }
	if = {
		limit = {
			root.age >= 45
		}
		multiply = 6
		min = 20
	}
	else_if = {
		limit = {
			root.age >= 35
		}
		multiply = 5
		min = 15
	}
	else_if = {
		limit = {
			root.age >= 25
		}
		multiply = 4
		min = 10
	}
	else = { multiply = 3 }
	if = {
		limit = {
			calc_true_if = {
            	amount = 1
				has_trait = logistician
				has_trait = military_engineer
				has_trait = aggressive_attacker
				has_trait = unyielding_defender
				has_trait = flexible_leader
				has_trait = desert_warrior
				has_trait = jungle_stalker
				has_trait = reaver
				has_trait = reckless
				has_trait = holy_warrior
				has_trait = open_terrain_expert
				has_trait = rough_terrain_expert
				has_trait = forest_fighter
				has_trait = cautious_leader
				has_trait = organizer
				has_trait = winter_soldier
			}
		}
		multiply = 0.75
	}
	if = {
		limit = {
			NOR = {
				has_trait = logistician
				has_trait = military_engineer
				has_trait = aggressive_attacker
				has_trait = unyielding_defender
				has_trait = flexible_leader
				has_trait = desert_warrior
				has_trait = jungle_stalker
				has_trait = reaver
				has_trait = reckless
				has_trait = holy_warrior
				has_trait = open_terrain_expert
				has_trait = rough_terrain_expert
				has_trait = forest_fighter
				has_trait = cautious_leader
				has_trait = organizer
				has_trait = winter_soldier
			}
		}
		multiply = 0.5
	}
	multiply = 0.7
}

gpt_quarterly_xp_dip = {
	value = 0
	add = root.diplomacy
	divide = 30
	if = {
		limit = {
			is_commanding_army = yes
		}
		multiply = 2
	}
	min = 0.1
	max = 1.5
}
gpt_quarterly_xp_stw = {
	value = 0
	add = root.stewardship
	divide = 30
	if = {
		limit = {
			is_commanding_army = yes
		}
		multiply = 2
	}
	min = 0.1
	max = 1.5
}
gpt_quarterly_xp_mar = {
	value = 0
	add = root.martial
	divide = 30
	if = {
		limit = {
			is_commanding_army = yes
		}
		multiply = 2
	}
	min = 0.1
	max = 1.5
}
gpt_quarterly_xp_int = {
	value = 0
	add = root.intrigue
	divide = 30
	if = {
		limit = {
			is_commanding_army = yes
		}
		multiply = 2
	}
	min = 0.1
	max = 1.5
}
gpt_quarterly_xp_ler = {
	value = 0
	add = root.learning
	divide = 30
	if = {
		limit = {
			is_commanding_army = yes
		}
		multiply = 2
	}
	min = 0.1
	max = 1.5
}
gpt_quarterly_xp_dread = {
	value = 0
	add = root.dread
	divide = 90
	if = {
		limit = {
			is_commanding_army = yes
		}
		multiply = 2
	}
	min = 0.1
	max = 1.5
}

gpt_rfavor_tier = {
	value = 0
	if = {
		limit = {
			has_game_rule = GPT_rfavor_count
		}
		add = 2
	}
	if = {
		limit = {
			has_game_rule = GPT_rfavor_duke
		}
		add = 3
	}
	if = {
		limit = {
			has_game_rule = GPT_rfavor_king
		}
		add = 4
	}
}





















gpt_camp_temperament_value = {
	value = current_camp_temperament_average_value
}


amount_of_officers_value = {
	value = 0
	every_courtier = {
		limit = { is_adult = yes has_any_court_position = yes }
		add = 1
	}
}

gpt_camp_average_dip = {
	value = 0
	every_courtier = {
		limit = { is_adult = yes }
		add = "diplomacy"
	}
	divide = amount_of_followers_value
}

gpt_camp_average_mar = {
	value = 0
	every_courtier = {
		limit = { is_adult = yes }
		add = "martial"
	}
	divide = amount_of_followers_value
}

gpt_camp_average_stw = {
	value = 0
	every_courtier = {
		limit = { is_adult = yes }
		add = "stewardship"
	}
	divide = amount_of_followers_value
}

gpt_camp_average_int = {
	value = 0
	every_courtier = {
		limit = { is_adult = yes }
		add = "intrigue"
	}
	divide = amount_of_followers_value
}

gpt_camp_average_ler = {
	value = 0
	every_courtier = {
		limit = { is_adult = yes }
		add = "learning"
	}
	divide = amount_of_followers_value
}

gpt_camp_average_pro = {
	value = 0
	every_courtier = {
		limit = { is_adult = yes }
		add = "prowess"
	}
	divide = amount_of_followers_value
}

gpt_officer_average_dip = {
	value = 0
	every_courtier = {
		limit = { is_adult = yes has_any_court_position = yes }
		add = "diplomacy"
	}
	divide = amount_of_officers_value
	divide = 3
}

gpt_officer_average_mar = {
	value = 0
	every_courtier = {
		limit = { is_adult = yes has_any_court_position = yes }
		add = "martial"
	}
	divide = amount_of_officers_value
	divide = 3
}

gpt_officer_average_stw = {
	value = 0
	every_courtier = {
		limit = { is_adult = yes has_any_court_position = yes }
		add = "stewardship"
	}
	divide = amount_of_officers_value
	divide = 2
}

gpt_officer_average_int = {
	value = 0
	every_courtier = {
		limit = { is_adult = yes has_any_court_position = yes }
		add = "intrigue"
	}
	divide = amount_of_officers_value
	divide = 3
}

gpt_officer_average_ler = {
	value = 0
	every_courtier = {
		limit = { is_adult = yes has_any_court_position = yes }
		add = "learning"
	}
	divide = amount_of_officers_value
	divide = 2
}

gpt_officer_average_pro = {
	value = 0
	every_courtier = {
		limit = { is_adult = yes has_any_court_position = yes }
		add = "prowess"
	}
	divide = amount_of_officers_value
	divide = 5
}



















gpt_adv_initial_xp_dip = {
	value = 0
	add = root.diplomacy
	if = {
		limit = {
			root.age >= 45
		}
		multiply = 6
		min = 20
	}
	else_if = {
		limit = {
			root.age >= 35
		}
		multiply = 5
		min = 15
	}
	else_if = {
		limit = {
			root.age >= 25
		}
		multiply = 4
		min = 10
	}
	else = { multiply = 3 }
	divide = 2
}
gpt_adv_initial_xp_stw = {
	value = 0
	add = root.stewardship
	if = {
		limit = {
			root.age >= 45
		}
		multiply = 6
		min = 20
	}
	else_if = {
		limit = {
			root.age >= 35
		}
		multiply = 5
		min = 15
	}
	else_if = {
		limit = {
			root.age >= 25
		}
		multiply = 4
		min = 10
	}
	else = { multiply = 3 }
	divide = 2
}
gpt_adv_initial_xp_mar = {
	value = 0
	add = root.martial
	if = {
		limit = {
			root.age >= 45
		}
		multiply = 6
		min = 20
	}
	else_if = {
		limit = {
			root.age >= 35
		}
		multiply = 5
		min = 15
	}
	else_if = {
		limit = {
			root.age >= 25
		}
		multiply = 4
		min = 10
	}
	else = { multiply = 3 }
	divide = 2
}
gpt_adv_initial_xp_int = {
	value = 0
	add = root.intrigue
	if = {
		limit = {
			root.age >= 45
		}
		multiply = 6
		min = 20
	}
	else_if = {
		limit = {
			root.age >= 35
		}
		multiply = 5
		min = 15
	}
	else_if = {
		limit = {
			root.age >= 25
		}
		multiply = 4
		min = 10
	}
	else = { multiply = 3 }
	divide = 2
}
gpt_adv_initial_xp_ler = {
	value = 0
	add = root.learning
	if = {
		limit = {
			root.age >= 45
		}
		multiply = 6
		min = 20
	}
	else_if = {
		limit = {
			root.age >= 35
		}
		multiply = 5
		min = 15
	}
	else_if = {
		limit = {
			root.age >= 25
		}
		multiply = 4
		min = 10
	}
	else = { multiply = 3 }
	divide = 2
}
gpt_adv_initial_xp_dread = {
	value = 0
	if = { limit = { has_trait = paranoid } add = 4 }
	if = { limit = { has_trait = deceitful } add = 4 }
	if = { limit = { has_trait = vengeful } add = 8 }
	if = { limit = { has_trait = arbitrary } add = 8 }
	if = { limit = { has_trait = ambitious } add = 8 }
	if = { limit = { has_trait = wrathful } add = 12 }
	if = { limit = { has_trait = sadistic } add = 16 }
	if = { limit = { has_trait = compassionate } add = -12 }
	if = { limit = { has_trait = forgiving } add = -12 }
	if = { limit = { has_trait = calm } add = -8 }
	if = { limit = { has_trait = just } add = -8 }
	if = { limit = { has_trait = trusting } add = -4 }
	if = { limit = { has_trait = content } add = -4 }
	if = {
		limit = {
			root.age >= 45
		}
		multiply = 6
		min = 20
	}
	else_if = {
		limit = {
			root.age >= 35
		}
		multiply = 5
		min = 15
	}
	else_if = {
		limit = {
			root.age >= 25
		}
		multiply = 4
		min = 10
	}
	else = { multiply = 3 }
	divide = 2
}

gpt_adv_travel_xp_dip = {
	value = 0
	add = diplomacy
	divide = 200
}
gpt_adv_travel_xp_stw = {
	value = 0
	add = stewardship
	divide = 200
}
gpt_adv_travel_xp_mar = {
	value = 0
	add = martial
	divide = 200
}
gpt_adv_travel_xp_int = {
	value = 0
	add = intrigue
	divide = 200
}
gpt_adv_travel_xp_ler = {
	value = 0
	add = learning
	divide = 200
}
gpt_adv_travel_xp_dread = {
	value = 0
	add = dread
	divide = 500
}





