jrider
Veteran
Playing for some time, I became somewhat frustrated by the native title system, being unable to distinguish between Rhodoks and Swadian lords and all the Ladies being Lady whatever faction or status they had, looking for something in the notes took forever.
What I wanted was, basicaly, a title system that would allow to identify clearly a lord's faction and his land ownership (ie. ruler, town, castle, village, landless), as well as their wife's position (titled according to her husband), and to distinguish between all the unmarried daughter and sister of the various factions.
after some research I didn't see anything like this existing and the only mention of it was as a suggestion in the Privy Council (here's the link for reference: http://forums.taleworlds.com/index.php/topic,118571.0.html ).
Most of the new titles comes from the suggestions in that thread (or from external material referenced in it).
NB: notable exceptions are for unmarried women titles and rhodoks titles (went for Scot Gaelic instead of Italian) and I chose latin for player faction.
Here is what I came up with:
Screenshots:
Using this with a previous savegame, shouldn't cause major problems, there may be some displaced strings due to the extension of the existing titles strings.
Following Caprera's questions, here is a break down of the general principle if you want to adapt/expand the code:
step 6 can mix the result of the various 3 & 4 steps' blocks (if you made several)
use strings in module_strings.py to reduce coding effort (NB: never use an empty string, always put something in it).
keeping the rank value for other things should use the one computed in step 4 to stay generic (unless you love long try_begin/else_try blocks or want to make something unique for each rank).
and one important last thing, even if you have only one condition keep the whole thing into a try_begin/try_end block (except for the script parameters and common stuff that can be derived from them).
here is the changelog and code (for Warband v1.127), feel free to reuse anywhere (this is v0.3.3):
Changelog:
for suffix added in v0.3 :
... out of available space, hooks and native code modifications are described in post #6 (http://forums.taleworlds.com/index.php/topic,129691.msg3128066.html#msg3128066)
What I wanted was, basicaly, a title system that would allow to identify clearly a lord's faction and his land ownership (ie. ruler, town, castle, village, landless), as well as their wife's position (titled according to her husband), and to distinguish between all the unmarried daughter and sister of the various factions.
after some research I didn't see anything like this existing and the only mention of it was as a suggestion in the Privy Council (here's the link for reference: http://forums.taleworlds.com/index.php/topic,118571.0.html ).
Most of the new titles comes from the suggestions in that thread (or from external material referenced in it).
NB: notable exceptions are for unmarried women titles and rhodoks titles (went for Scot Gaelic instead of Italian) and I chose latin for player faction.
Here is what I came up with:
- Faction based titles for ruler, town, castle, village, landless (based on the biggest fief owned) and unmarried status.
- Wife-husband relationship taken into account for the spouse not holding land (if both hold land the best title is applied).
- Lords and Ladies' titles are updated for fief grant, faction change and weddings.
- Unmarried daughters and sisters have a title equivalent to Mistress (not a very noble one, but the best I could come with to set them apart).
- v0.3: Added title suffix to reflect relation with liege (from caprera's questions) (used latin non-faction specific ones).
- v0.3.1: enabled the player for titles (also derived from caprera's questions).
- Titles for companions (not as vassals, they get the standard title in that case) in the party (unique title so they're all next to each others in the notes) or outside the party (according to major skills).
- Companions' titles are changed when they join/leave the party (except when vassals).
- since the aim was to have a nice sorted list in game Notes, the mongol titles have been swapped.
- The titles come from Latin [player], English [swadian], Russian [vaegir], Mongol (or chinese) [khergit], Old Norse (or mid-norwegian) [nords], Scots Gaelic [rhodoks] and Arabic [sarranid].
Almost no source were available for them so most female Mongol titles are made up (I'm no linguist but I tried my best).
Screenshots:
Using this with a previous savegame, shouldn't cause major problems, there may be some displaced strings due to the extension of the existing titles strings.
Following Caprera's questions, here is a break down of the general principle if you want to adapt/expand the code:
- basic conditions to check troop is eligible for title (faction, lords, ladies and such)
- store the plural form of the troop name (for named characters this one is never modified thus providing the uncorrupted base character name, player is handled slightly differently since the plural name is never updated in native code).
- External computation block for the conditions to be used to attribute the rank (examples : gender, biggest fief for husband/wife couple, relation to liege)
- Rank calculation block, which translate to the base index of the rank string, starting at 0 (example : quality computation)
- find the corresponding string index in the module_strings.py (examples: index for quality in a faction context, index for suffix derived from relation number, index for out of party companions)
- build the new character name string using that string index
- replace the old character name by the new one
- rename the character's party (if he has one) according to its new name.
step 6 can mix the result of the various 3 & 4 steps' blocks (if you made several)
use strings in module_strings.py to reduce coding effort (NB: never use an empty string, always put something in it).
keeping the rank value for other things should use the one computed in step 4 to stay generic (unless you love long try_begin/else_try blocks or want to make something unique for each rank).
and one important last thing, even if you have only one condition keep the whole thing into a try_begin/try_end block (except for the script parameters and common stuff that can be derived from them).
here is the changelog and code (for Warband v1.127), feel free to reuse anywhere (this is v0.3.3):
Changelog:
v0.0: initial release
v0.1: generic fix
v0.1: generic fix
- changed the conditions slightly in the main script to exclude pretenders from being retitled.
- changes to the troop_set_title_according_to_faction_gender_and_lands script
- changes to the get_troop_specialisation scripts.
- new modifications to make in module_dialog.py added.
- troop_change_relation_with_troop modified to update title if both troops are same faction and second is faction ruler
- new script modified to add suffix computation block
- modified new kingdom titles in module_strings.py to add relation suffix
- added new set of strings in module_strings.py for suffix
- added condition to non-vassal companion title (problem occured when player with kingdom swore allegiance to a king)
- modified game_reset_player_party_name script to store plural name and reset player's title
- modified player_join_faction to update spouse and player's titles
- modified player_leave_faction to update spouse and player's titles
- new script modified to allow player to be titled
- moved added code block to end of give_center_to_lord script
- moved added code block in troop_change_relation_with_troop script
- added call to title change in change_player_relation_with_troop
- added call to title change in activate_player_faction script
- initial condition for computing suffixes in new script modified
- new conditions for female character in new script to priorize ruler title
- New tags used in the scripts to put in module_constants.py :
NB: I use the second tag in an extended note system, it has no direct use for the title code itself.
Code:
# Jrider + for Heroes specialization titles and descriptions
hero_titles_begin = "str_hero_titles_none"
hero_specdesc_begin = "str_hero_specdesc_none"
# Jrider -
- New titles strings (and descriptions for companion titles) to put in module_strings.py :
NB: I use the descriptions in an extended game note system they are not used in this code.
Code:
# Jrider + TITLES v0.3 new titles, for suffix, {reg10?-{s61}:} has been add to all titles except for king's
# ("faction_title_male_player", "Lord {s0}"),
# ("faction_title_male_1", "Count {s0}"),
# ("faction_title_male_2", "Boyar {s0}"),
# ("faction_title_male_3", "{s0} Noyan"),
# ("faction_title_male_4", "Jarl {s0}"),
# ("faction_title_male_5", "Count {s0}"),
# ("faction_title_male_6", "Emir {s0}"),
#
# ("faction_title_female_player", "Lady {s0}"),
# ("faction_title_female_1", "Countess {s0}"),
# ("faction_title_female_2", "Boyarina {s0}"),
# ("faction_title_female_3", "{s0} Hatun"),
# ("faction_title_female_4", "Grevinne {s0}"),
# ("faction_title_female_5", "Countess {s0}"),
# ("faction_title_female_6", "Sayeda {s0}"),
("faction_title_male_player", "Dominus{reg10?-{s61}:} {s0}"), # Latin
("faction_title_male_player_village", "Baro{reg10?-{s61}:} {s0}"),
("faction_title_male_player_castle", "Comes{reg10?-{s61}:} {s0}"),
("faction_title_male_player_town", "Dux{reg10?-{s61}:} {s0}"),
("faction_title_male_player_king", "Rex {s0}"),
("faction_title_male_1", "Lord{reg10?-{s61}:} {s0}"), # English
("faction_title_male_1_village", "Baron{reg10?-{s61}:} {s0}"),
("faction_title_male_1_castle", "Count{reg10?-{s61}:} {s0}"),
("faction_title_male_1_town", "Duke{reg10?-{s61}:} {s0}"),
("faction_title_male_1_king", "King {s0}"),
("faction_title_male_2", "Dvorianin{reg10?-{s61}:} {s0}"), # Russian
("faction_title_male_2_village", "Posadnik{reg10?-{s61}:} {s0}"),
("faction_title_male_2_castle", "Boyar{reg10?-{s61}:} {s0}"),
("faction_title_male_2_town", "Kniaz{reg10?-{s61}:} {s0}"),
("faction_title_male_2_king", "Korol {s0}"),
("faction_title_male_3", "Taishi{reg10?-{s61}:} {s0}"), # Mongol/Chinese
("faction_title_male_3_village", "Darga{reg10?-{s61}:} {s0}"),
("faction_title_male_3_castle", "Noyan{reg10?-{s61}:} {s0}"),
("faction_title_male_3_town", "Wang{reg10?-{s61}:} {s0}"),
("faction_title_male_3_king", "Khan {s0}"),
("faction_title_male_4", "Heera{reg10?-{s61}:} {s0}"), # Old norse/mid-norwegian
("faction_title_male_4_village", "Hersir{reg10?-{s61}:} {s0}"),
("faction_title_male_4_castle", "Jarl{reg10?-{s61}:} {s0}"),
("faction_title_male_4_town", "Hertogi{reg10?-{s61}:} {s0}"),
("faction_title_male_4_king", "Konungr {s0}"),
("faction_title_male_5", "Tigheam{reg10?-{s61}:} {s0}"), # Scots Gaelic
("faction_title_male_5_village", "Thegn{reg10?-{s61}:} {s0}"),
("faction_title_male_5_castle", "Iarla{reg10?-{s61}:} {s0}"),
("faction_title_male_5_town", "Diuc{reg10?-{s61}:} {s0}"),
("faction_title_male_5_king", "Righ {s0}"),
("faction_title_male_6", "Sayyid{reg10?-{s61}:} {s0}"), # Arabic
("faction_title_male_6_village", "Sheik{reg10?-{s61}:} {s0}"),
("faction_title_male_6_castle", "Quadi{reg10?-{s61}:} {s0}"),
("faction_title_male_6_town", "Mushir{reg10?-{s61}:} {s0}"),
("faction_title_male_6_king", "Sultan {s0}"),
# equivalent for female character/wife and specific for landless unmarried daugther/sister
("faction_title_female_player", "Domina{reg10?-{s61}:} {s0}"), # Latin
("faction_title_female_player_village", "Baronessa{reg10?-{s61}:} {s0}"),
("faction_title_female_player_castle", "Comitessa{reg10?-{s61}:} {s0}"),
("faction_title_female_player_town", "Ducessa{reg10?-{s61}:} {s0}"),
("faction_title_female_player_queen", "Regina {s0}"),
("faction_title_female_player_unmarried", "Magistra {s0}"),
("faction_title_female_1", "Lady{reg10?-{s61}:} {s0}"), # English
("faction_title_female_1_village", "Baroness{reg10?-{s61}:} {s0}"),
("faction_title_female_1_castle", "Countess{reg10?-{s61}:} {s0}"),
("faction_title_female_1_town", "Duchess{reg10?-{s61}:} {s0}"),
("faction_title_female_1_queen", "Queen {s0}"),
("faction_title_female_1_unmarried", "Mistress {s0}"),
("faction_title_female_2", "Dvorianska{reg10?-{s61}:} {s0}"), # Russian
("faction_title_female_2_village", "Posadnitsa{reg10?-{s61}:} {s0}"),
("faction_title_female_2_castle", "Boiaryna{reg10?-{s61}:} {s0}"),
("faction_title_female_2_town", "Kniaginia{reg10?-{s61}:} {s0}"),
("faction_title_female_2_queen", "Koroleva {s0}"),
("faction_title_female_2_unmarried", "Mestari {s0}"),
("faction_title_female_3", "Behi{reg10?-{s61}:} {s0}"), # Mongol/Chinese
("faction_title_female_3_village", "Darthun{reg10?-{s61}:} {s0}"),
("faction_title_female_3_castle", "Nohi{reg10?-{s61}:} {s0}"),
("faction_title_female_3_town", "Wathun{reg10?-{s61}:} {s0}"),
("faction_title_female_3_queen", "Khathun {s0}"),
("faction_title_female_3_unmarried", "Gongzhu {s0}"),
("faction_title_female_4", "Fru{reg10?-{s61}:} {s0}"), # Old norse/mid-norwegian
("faction_title_female_4_village", "Baronsfru{reg10?-{s61}:} {s0}"),
("faction_title_female_4_castle", "Greifynja{reg10?-{s61}:} {s0}"),
("faction_title_female_4_town", "Hertogafru{reg10?-{s61}:} {s0}"),
("faction_title_female_4_queen", "Drottning {s0}"),
("faction_title_female_4_unmarried", "Mesterinde {s0}"),
("faction_title_female_5", "Baintigheam{reg10?-{s61}:} {s0}"), # Scots Gaelic
("faction_title_female_5_village", "Bannthegn{reg10?-{s61}:} {s0}"),
("faction_title_female_5_castle", "Baniarla{reg10?-{s61}:} {s0}"),
("faction_title_female_5_town", "Bandiuc{reg10?-{s61}:} {s0}"),
("faction_title_female_5_queen", "Banrinn {s0}"),
("faction_title_female_5_unmarried", "Meistres {s0}"),
("faction_title_female_6", "Sayyida{reg10?-{s61}:} {s0}"), # Arabic
("faction_title_female_6_village", "Sheika{reg10?-{s61}:} {s0}"),
("faction_title_female_6_castle", "Qadiya{reg10?-{s61}:} {s0}"),
("faction_title_female_6_town", "Mushira{reg10?-{s61}:} {s0}"),
("faction_title_female_6_queen", "Sultana {s0}"),
("faction_title_female_6_unmarried", "Maulana {s0}"),
# Jrider -
Code:
# Jrider + TITLES v0.0 specialization strings, you can put these at the end of the file
("hero_titles_none", "Hero {s0}"),
("hero_titles_diplomat", "Missi {s0}"),
("hero_titles_tactician", "Tassein {s0}"),
("hero_titles_scout", "Ausculare {s0}"),
("hero_titles_physician", "Fisique {s0}"),
("hero_titles_trader", "Empori {s0}"),
("hero_titles_party", "Palantinus {s0}"),
("hero_specdesc_none", "none"),
("hero_specdesc_diplomat", "Diplomacy (Persuasion)"),
("hero_specdesc_tactician", "Tactical matters (Tactics, Engineer and Trainer)"),
("hero_specdesc_scout", "Scouting (Spotting, Tracking and Path finding)"),
("hero_specdesc_physician", "Healing (Wound treatment, Surgery and First aid)"),
("hero_specdesc_trader", "Trade (Trading, Looting and Foraging)"),
# Jrider -
# Jrider + TITLES v0.3 relation to ruler suffix, you can put these at the end of the file
("ruler_relation_mnus_100_ns", "vindicta"), # -100 Vengeful
("ruler_relation_mnus_80_ns", "ultio"), # -80 Vengeful/revengeful
("ruler_relation_mnus_60_ns", "invisus"), # -60 Hateful
("ruler_relation_mnus_40_ns", "dolor"), # -40 Resentful
("ruler_relation_mnus_20_ns", "fremo"), # -20 Grumbling
("ruler_relation_plus_0_ns", "placeholder shouldn't appear"),# 0...19
("ruler_relation_plus_20_ns", "consensio"), # cooperative
("ruler_relation_plus_40_ns", "faveo"), # supportive
("ruler_relation_plus_60_ns", "pius"), # gracious
("ruler_relation_plus_80_ns", "confero"), # devoted
# Jrider -
- New scripts to put in module_scripts.py (v0.3.3 change)
Code:
# Jrider + Begin new scripts
# TITLES v0.3.3 #####
# script troop_set_title_according_to_faction_gender_and_lands
# calculate and set new title for lords, ladies and companions
# use s0 and s1
# change v0.3: use s61 and reg10
("troop_set_title_according_to_faction_gender_and_lands",
[
(store_script_param, ":troop_no", 1),
(store_script_param, ":faction_no", 2),
# Ensure we process only npcs member of a kingdom, including player
(try_begin), # Npcs serving as lord and ladies
# v0.1 change +
(is_between, ":faction_no", kingdoms_begin, kingdoms_end), # normaly this one should exclude companions that are not vassals
(neg|is_between, ":troop_no", pretenders_begin, pretenders_end), # exclude pretenders
(this_or_next|is_between, ":troop_no", active_npcs_begin, kingdom_ladies_end), # v0.3.1 change to include player
(eq, ":troop_no", "trp_player"), # include player player # v0.3.1 change
# (neq, ":troop_no", "trp_player"), # exclude player # v0.3.1 commented, wasn't relevant anyway
(faction_get_slot, ":faction_leader", ":faction_no", slot_faction_leader),
(str_store_troop_name_plural, s0, ":troop_no"),
# v0.1 change -
# External computation blocks
# Get Gender
(troop_get_type, ":gender", ":troop_no"),
# NPC's largest fief (works for male and female, compute spouse fief as well)
# 1 no fief, 2 village, 3 castle, 4 town
(assign, ":largest_fief", 0),
(try_for_range, ":cur_center", centers_begin, centers_end),
(troop_get_slot, ":spouse_no", ":troop_no", slot_troop_spouse),
(neq, ":troop_no", ":faction_leader"), # exclude research for ruler
(neq, ":spouse_no", ":faction_leader"), # exclude research for ruler's wife
(lt, ":largest_fief", 3),
(party_slot_ge, ":cur_center", slot_town_lord, 0),
(this_or_next|party_slot_eq, ":cur_center", slot_town_lord, ":spouse_no"),
(party_slot_eq, ":cur_center", slot_town_lord, ":troop_no"),
(try_begin),
(party_slot_eq, ":cur_center", slot_party_type, spt_town),
(lt, ":largest_fief", 3),
(assign, ":largest_fief", 3),
(else_try),
(party_slot_eq, ":cur_center", slot_party_type, spt_castle),
(lt, ":largest_fief", 2),
(assign, ":largest_fief", 2),
(else_try),
(party_slot_eq, ":cur_center", slot_party_type, spt_village),
(lt, ":largest_fief", 1),
(assign, ":largest_fief", 1),
(try_end),
(try_end),
# base title(s) computation blocks
# Determine NPCs quality in order of importance
# for male NPCs: 4 Ruler, 3 town, 2 castle, 1 village, 0 landless
# for female NPCs: 5 unmarried (kingdom lady only), 4 queen, 3 wife or town, 2 wife or castle, 1 wife or village, 0 wife or landless
(assign, ":quality", 0),
(try_begin), # Male npcs
(eq, ":gender", 0),
(try_begin),
(eq, ":troop_no", ":faction_leader"), # is king
(assign, ":quality", 4),
(else_try),
(assign, ":quality", ":largest_fief"),
(try_end),
(else_try), # Female npcs, a bit more complex queen, landowner, companions without a fief,
(try_begin), # wife of faction leader
# v0.3.3 change +
(this_or_next|troop_slot_eq, ":troop_no", slot_troop_spouse, ":faction_leader"),
(eq, ":troop_no", ":faction_leader"), # is queen
# v0.3.3 change -
(assign, ":quality", 4),
(else_try), # is a landowner - index 1 to 3
(gt, ":largest_fief", 0),
(assign, ":quality", ":largest_fief"),
(else_try), # a companion vassal without fief
(is_between, ":troop_no", companions_begin, companions_end),
(assign, ":quality", 0),
(else_try), # married lady whose husband has no fief
(troop_slot_ge, ":troop_no", slot_troop_spouse, 0),
(assign, ":quality", 0),
(else_try), # unmarried lady without fief
(assign, ":quality", 5),
(try_end),
(try_end),
# v0.3 changes +
# compute troop relation to ruler suffix
(try_begin),
(neq, ":troop_no", ":faction_leader"), # exclude from suffix if king v0.3.2 change
(call_script, "script_troop_get_relation_with_troop", ":troop_no", ":faction_leader"),
(assign, ":relation", reg0),
(str_clear, s61),
(assign, reg10, 0),
(try_begin), # update reg10
(this_or_next|gt, ":relation", 19),
(lt, ":relation", -19),
(assign, reg10, ":relation"),
(store_add, ":normalized_relation", ":relation", 100),
(store_div, ":str_offset", ":normalized_relation", 20),
(val_clamp, ":str_offset", 0, 10), # does 10 work ? only 10 strings in there
(store_add, ":str_rel_id", "str_ruler_relation_mnus_100_ns", ":str_offset"),
(str_store_string, s61, ":str_rel_id"),
(try_end),
(else_try), # clear register and string
(str_clear, s61),
(assign, reg10, 0),
(try_end),
# v0.3 changes -
# Find title index in strings block
(store_sub, ":title_index", ":faction_no", kingdoms_begin), # 0 player, 1 swadian ...
(try_begin), #male, 5 title entries
(eq, ":gender", 0),
(val_mul, ":title_index", 5),
(val_add, ":title_index", kingdom_titles_male_begin),
(else_try), # female, 6 title entries
(val_mul, ":title_index", 6),
(val_add, ":title_index", kingdom_titles_female_begin),
(try_end),
(val_add, ":title_index", ":quality"),
# Set title and party name block
# assign title
(str_store_string, s1, ":title_index"),
(troop_set_name, ":troop_no", s1),
# rename party
(troop_get_slot, ":troop_party", ":troop_no", slot_troop_leaded_party),
(try_begin),
# v0.2 change to prevent opcode error
(gt, ":troop_party", 0),
(str_store_troop_name, s5, ":troop_no"),
(party_set_name, ":troop_party", "str_s5_s_party"),
(try_end), # v0.2 change
(try_end),
# Special titles for companions not used as vassals
(try_begin),
(neg|eq, ":faction_no", "fac_player_supporters_faction"), # v0.2 change
(neg|troop_slot_eq, ":troop_no", slot_troop_occupation, slto_kingdom_hero), # v0.3 change, exclude companion if he became a kingdom lord
(is_between, ":troop_no", companions_begin, companions_end),
# Store the plural name
(str_store_troop_name_plural, s0, ":troop_no"),
# Set the title
(try_begin), # Male npcs
(troop_slot_eq, ":troop_no", slot_troop_occupation, slto_player_companion),
(str_store_string, s1, "str_hero_titles_party"),
(else_try),
(call_script, "script_get_troop_specialisation", ":troop_no", ":faction_no"),
(assign, ":title_index", reg0),
(val_add, ":title_index", hero_titles_begin),
(str_store_string, s1, ":title_index"),
(try_end),
# assign title
(troop_set_name, ":troop_no", s1),
(try_end),
]),
# Script get_troop_specialisation
# Assess companion current skills to find the strongest trend
("get_troop_specialisation",
[
(store_script_param, ":troop_no", 1),
(store_script_param, ":faction_no", 2),
(try_begin),
(neg|eq, ":faction_no", "fac_player_supporters_faction"), # v0.2 change
(is_between, ":troop_no", companions_begin, companions_end),
# Other titles according to function in group
# Scout (Ausculare) - PathFinding, Tracking and Spotting
(store_skill_level, ":scout", "skl_spotting", ":troop_no"),
(store_skill_level, ":scout_skill", "skl_pathfinding", ":troop_no"),
(val_add, ":scout", ":scout_skill"),
(store_skill_level, ":scout_skill", "skl_tracking", ":troop_no"),
(val_add, ":scout", ":scout_skill"),
# Physician (Fisique) - Wound Treatment, Surgery, First Aid
(store_skill_level, ":physician", "skl_wound_treatment", ":troop_no"),
(store_skill_level, ":physician_skill", "skl_first_aid", ":troop_no"),
(val_add, ":physician", ":physician_skill"),
(store_skill_level, ":physician_skill", "skl_surgery", ":troop_no"),
(val_add, ":physician", ":physician_skill"),
# Tactician (Tassein) - Tactics, Engineer, Trainer
(store_skill_level, ":tactician", "skl_tactics", ":troop_no"),
(store_skill_level, ":tactician_skill", "skl_engineer", ":troop_no"),
(val_add, ":tactician", ":tactician_skill"),
(store_skill_level, ":tactician_skill", "skl_trainer", ":troop_no"),
(val_add, ":tactician", ":tactician_skill"),
# Trader (Empori) - Trade Looting, Foraging (foraging is a new skill I'm working on)
(store_skill_level, ":trader", "skl_trade", ":troop_no"),
(store_skill_level, ":trader_skill", "skl_looting", ":troop_no"),
(val_add, ":trader", ":trader_skill"),
#(store_skill_level, ":trader_skill", "skl_foraging", ":troop_no"), # uncomment if using foraging
#(val_add, ":trader", ":trader_skill"), # uncomment if using foraging
(val_mul, ":trader", 3), # comment if using foraging
(val_div, ":trader", 2), # comment if using foraging
# Diplomat (Missi) - Persuasion
(store_skill_level, ":diplomat", "skl_persuasion", ":troop_no"),
(val_mul, ":diplomat", 3),
(try_begin), # Just your basic hero
(eq, ":diplomat", 0),
(eq, ":tactician", 0),
(eq, ":scout", 0),
(eq, ":physician", 0),
(eq, ":trader", 0),
(assign, reg0, 0),
(else_try), # Diplomat - skilled in Persuasion and Trainer
(gt, ":diplomat", 0),
(ge, ":diplomat", ":tactician"),
(ge, ":diplomat", ":scout"),
(ge, ":diplomat", ":physician"),
(ge, ":diplomat", ":trader"),
(assign, reg0, 1),
(else_try), # Tactician - skilled in Tactics and Engineer
(gt, ":tactician", 0),
(ge, ":diplomat", ":scout"),
(ge, ":diplomat", ":physician"),
(ge, ":diplomat", ":trader"),
(assign, reg0, 2),
(else_try), # Scout - skilled in Spotting, Tracking and Pathfinding
(gt, ":scout", 0),
(ge, ":diplomat", ":physician"),
(ge, ":diplomat", ":trader"),
(assign, reg0, 3),
(else_try), # Physician - skilled in Wound Treatment, Surgery and First Aid
(gt, ":physician", 0),
(ge, ":physician", ":trader"),
(assign, reg0, 4),
(else_try), # Trader - skilled in Trade
(gt, ":trader", 0),
(assign, reg0, 5),
(try_end),
(try_end),
]),
- The module_info_pages.py entry, if you want the historical background :
Code:
# Jrider + TITLES v0.0 titles descriptions
("nobility_titles", "Nobility Titles",
"Titles vary from kingdom to kingdom the most common interpretation is:^\
King (ruler): ^ Rex, King, Korol, Khan, Konungr, Righ, Sultan^^\
Duke (lord of a town): ^\
A duke is, historically, of highest rank below the monarch, and historically controlling a duchy. The title comes from the Latin Dux Bellorum, a term that ancient Roman chroniclers used to describe tribal Germanic and Celtic war leaders.^\
In the Middle Ages the title signified first among the Germanic monarchies. Dukes were the rulers of the provinces and the superiors of the counts in the cities and later, in the feudal monarchies, the highest-ranking peers of the king.^\
Dux, Duke, Kniaz, Wang, Hertogi, Diuc, Mushir^^\
Earl/Count (lord of a castle): ^\
Earl was the Anglo-Saxon form and jarl the Scandinavian form of a title meaning \"chieftain\" and referring especially to chieftains set to rule a territory in a king's stead. In Scandinavia, it became obsolete in the Middle Ages and was replaced with duke (hertig/hertug); in later medieval Britain, it became the equivalent of the continental count.^\
Comes, Count, Boyar, Noyan, Jarl, Iarla, Quadi^^\
Baron (lord of a village): ^\
The word baron comes from Old French baron, itself from Old High German and Latin (liber) baro meaning \"(free) man, (free) warrior\"; it merged with cognate Old English beorn meaning \"nobleman\".^\
Baro, Baron, Posadnik, Darga, Hersir, Thegn, Sheik^^\
Lord (landless noble): ^\
The etymology of the word can be traced back to the Old English word 'hlaford' which originated from 'hlafweard' meaning 'bread keeper' or 'loaf-ward', reflecting the Germanic tribal custom of a chieftain providing food for his followers.^\
Dominus, Lord, Dvorianin, Taishi, Heera, Tigheam, Sayyid^^\
The female equivalents are (whether they own the land themselves or hold the title from their husband's):^\
Queen: ^ Regina, Queen, Koroleva, Khathun, Drottning, Banrinn, Sultana^^\
Duchess: ^ Ducessa, Duchess, Kniaginia, Wathun, Hertogafru, Bandiuc, Mushira^^\
Countess: ^ Comitessa, Countess, Boiaryna, Nohi, Greifynja, Baniarla, Qadiya^^\
Baroness: ^ Baronessa, Baroness, Posadnitsa, Darthun, Baronsfru, Bannthegn, Sheika^^\
Lady: ^ Domina, Lady, Dvorianska, Behi, Fru, Baintigheam, Sayyida^^\
In addition unmarried, landless daugthers (or sisters) are named as follow:^\
Magistra, Mistress, Mestari, Gongzhu, Mesterinde, Meistres, Maulana^^\
The titles come from Latin, English, Russian, Mongol (or chinese), Old Norse (or mid-norwegian), Scots Gaelic and Arabic.^^\
Mongol titles should have the name placed before the title (not the case here for sorting considerations in the notes), female equivalents for the title were unavailable for most of the titles and were made up.^^\
Companions currently in the party are titled Palatinus.^\
The members of the Imperial Guard were named after Palatine Hill, the mythical founding place of Rome. On the same hill lived the members of the older of two schools of the ancient Salii brotherhood of God of War Mars, which had some symbolism in common with that of the imperial palace. Military training schools were the scholae, and the Imperial Guard was called Scholae Palatinae.^It was a personal army that the emperor was allowed to use personally on campaigns.^^\
Other companions who are not vassals are titled as Hero if they don't have any specialty, otherwise:^\
Missi : best suited for diplomacy.^\
Tassein : has a good knowledge of tactical related skills, including engineering and training.\
Ausculare : a master of scouting through the use of tracking, spotting and path-finding.^\
Fisique : inclined toward the healing arts of surgery, first aid and wound treatment.^\
Empori : goods management, either through trade, looting or foraging."),
# Jrider -
Code:
# Jrider + TITLES v0.3 title's suffixed description
("titles_suffix", "Titles's suffix",
"In order to reflec a lord's (or lady's) relation with his liege, a suffix is added to his title (used generic latin suffixes), from worse to best:^\
negative suffixes: vindicta, ultio, invisus, dolor, fremo^\
positive suffixes: consensio, faveo, pius, confero"),
# Jrider -
... out of available space, hooks and native code modifications are described in post #6 (http://forums.taleworlds.com/index.php/topic,129691.msg3128066.html#msg3128066)