Atilius
03-12-2006, 22:11
Particularly for mods with only one Roman faction, I've always wanted to be able to start the game with characters belonging to more than one family. I've also wanted to be able to start the game with several historical characters who aren't related to one another.
Here's a way to do it:
SUMMARY:
Create a trait for each surname you wish to assign to a character at the start of the game. An epithet can be associated with the trait - you simply define the epithet as the surname. In order for the character's sons to also bear this surname, you must create a trigger which always causes the sons to inherit this trait.
IN DETAIL:
It's necessary to edit the following files:
Data\export_descr_character_traits.txt
Data\text\export_VnVs.txt
Data\world\maps\campaign\(campaign_folder)\descr_strat.txt
As always, create backups before proceeding.
Create a trait for the surname (I'm actually using nomen-cognomen) "Fabius Maximus". Open up export_descr_character_traits.txt and add the following trait:
;------------------------------------------
Trait FabiusMaximus
Characters family
Hidden
Level Fabius_Maximus
Description Fabius_Maximus_desc
EffectsDescription Fabius_Maximus_effects_desc
Epithet Fabius_Maximus_epithet_desc
Threshold 1
I've made this a "hidden" trait so it doesn't show up in the character's list of traits, but for reasons mentioned below it might be wise to make it visible while you're testing.
Now add the trigger which assigns the trait to the character's sons:
;------------------------------------------
Trigger dads_fabiusmaximus
WhenToTest CharacterComesOfAge
Condition FatherTrait FabiusMaximus >= 1
Affects FabiusMaximus 1 Chance 100
Next, open up text\export_VnVs.txt and add at the bottom:
¬--------------------
{Fabius_Maximus} Fabius Maximus
{Fabius_Maximus_desc}
This man is a member of the Fabius Maximus family.
{Fabius_Maximus_effects_desc}
He gains the name Fabius Maximus as an epithet.
{Fabius_Maximus_epithet_desc} Fabius Maximus
I may be superstitious, but it's best to be careful with the tabs between the "}" and "Fabius Maximus" in the first and last lines.
Finally, open up descr_strat.txt and give Quintus Julius the FabiusMaximus trait:
character Quintus Julius, named character, age 29, , x 96, y 82
traits FabiusMaximus 1 , NaturalMilitarySkill 3 , GoodAttacker 1 , Energetic 1
ancillaries drillmaster
That's it.
A few notes:
Unfortunately, when you start the game Quintus Julius doesn't appear as Quintus Fabius Maximus. If you remove the "Hidden" keyword from the FabiusMaximus trait, you'll see it's been assigned but for some reason the effect doesn't show up. However, if you immediately save and reload, Quintus Julius becomes Quintus Fabius Maximus. His minor children will still have the Julius surname in the family tree but are properly named when they come of age - no intervention needed.
Quintus Fabius Maximus still appears in the family tree as a son of Flavius Julius.
If QFM or any of his descendents adopt another character, this character will retain his surname, which how the vanilla game behaves.
Here's a way to do it:
SUMMARY:
Create a trait for each surname you wish to assign to a character at the start of the game. An epithet can be associated with the trait - you simply define the epithet as the surname. In order for the character's sons to also bear this surname, you must create a trigger which always causes the sons to inherit this trait.
IN DETAIL:
It's necessary to edit the following files:
Data\export_descr_character_traits.txt
Data\text\export_VnVs.txt
Data\world\maps\campaign\(campaign_folder)\descr_strat.txt
As always, create backups before proceeding.
Create a trait for the surname (I'm actually using nomen-cognomen) "Fabius Maximus". Open up export_descr_character_traits.txt and add the following trait:
;------------------------------------------
Trait FabiusMaximus
Characters family
Hidden
Level Fabius_Maximus
Description Fabius_Maximus_desc
EffectsDescription Fabius_Maximus_effects_desc
Epithet Fabius_Maximus_epithet_desc
Threshold 1
I've made this a "hidden" trait so it doesn't show up in the character's list of traits, but for reasons mentioned below it might be wise to make it visible while you're testing.
Now add the trigger which assigns the trait to the character's sons:
;------------------------------------------
Trigger dads_fabiusmaximus
WhenToTest CharacterComesOfAge
Condition FatherTrait FabiusMaximus >= 1
Affects FabiusMaximus 1 Chance 100
Next, open up text\export_VnVs.txt and add at the bottom:
¬--------------------
{Fabius_Maximus} Fabius Maximus
{Fabius_Maximus_desc}
This man is a member of the Fabius Maximus family.
{Fabius_Maximus_effects_desc}
He gains the name Fabius Maximus as an epithet.
{Fabius_Maximus_epithet_desc} Fabius Maximus
I may be superstitious, but it's best to be careful with the tabs between the "}" and "Fabius Maximus" in the first and last lines.
Finally, open up descr_strat.txt and give Quintus Julius the FabiusMaximus trait:
character Quintus Julius, named character, age 29, , x 96, y 82
traits FabiusMaximus 1 , NaturalMilitarySkill 3 , GoodAttacker 1 , Energetic 1
ancillaries drillmaster
That's it.
A few notes:
Unfortunately, when you start the game Quintus Julius doesn't appear as Quintus Fabius Maximus. If you remove the "Hidden" keyword from the FabiusMaximus trait, you'll see it's been assigned but for some reason the effect doesn't show up. However, if you immediately save and reload, Quintus Julius becomes Quintus Fabius Maximus. His minor children will still have the Julius surname in the family tree but are properly named when they come of age - no intervention needed.
Quintus Fabius Maximus still appears in the family tree as a son of Flavius Julius.
If QFM or any of his descendents adopt another character, this character will retain his surname, which how the vanilla game behaves.