Creating New Traits

By SubRosa

Want to create new traits for your characters? Or simply modify the existing ones? This article will show you how, giving an example of creating a new trait in the process.

There are three files that must be edited to create new character traits:

RTW\Data\export_descr_character_traits.txt
RTW\Data\export_descr_VnVs_enums.txt (optional)
RTW\Data\Text\export_VnVs.txt

Make sure to make a copy of each as a backup before you edit them. That way you can fall back to the original in case you make a mistake you cannot correct.

Step One

Go to export_descr_character_traits.txt. This file is split into two sections. At the top is the Trait Data, while at the bottom is the Trigger Data. Every trait will have an entry in both sections.

Here is an example of the Trait Data for a new trait in Amazon: Total War:

;------------------------------------------
Trait HatesAmazon
   Characters family
   NoGoingBackLevel 3
   ExcludeCultures amazon
   AntiTraits FearsAmazon
 
   Level Despises_Amazon_Ways
      Description Despises_Amazon_Ways_desc
      EffectsDescription Despises_Amazon_Ways_effects_desc
      Threshold 1
 
      Effect Combat_V_Amazon 1
 
   Level Hates_Amazons
      Description Hates_Amazons_desc
      EffectsDescription Hates_Amazons_effects_desc
      Threshold 2
 
      Effect Combat_V_Amazon 2
 
   Level Loathes_Vile_Amazons
      Description Loathes_Vile_Amazons_desc
      EffectsDescription Loathes_Vile_Amazons_effects_desc
      Epithet Loathes_Vile_Amazons_epithet_desc
      Threshold 4
 
      Effect Combat_V_Amazon 3

Now we will break this down line by line and see what it all means.

Trait - This line gives the name of the trait. It must be unique.

Characters - This determines what kind of character may gain the trait. If you specify more than one, only the first listed will work. They are:

  • family
  • spy
  • assassin
  • admiral
  • diplomat
  • all

NoGoingBackLevel - At the level specified the levels of the trait cannot be reduced by gaining its Anti-Traits.

ExcludeCultures - (Optional) Characters belonging to the cultures listed here cannot gain this trait. You can find a list of the available cultures in the game in RTW\Data\descr_sm_cultures.txt

AntiTraits - (Optional) Characters with the new trait cannot possess the traits listed here. Instead if they gain one listed here it reduces the level of the new trait by the level of those gained. For example, if a character had HatesAmazon at level 2, then gained FearsAmazon at level 1, they would end up with their HatesAmazon trait at level 1.

Level - Most traits have multiple levels to them, each with their own unique name.

Description - This points to the description that the game will use for the trait when you mouse over it in the game. This is found in the RTW\Data\Text\export_VnVs.txt file. It can also be found in RTW\Data\export_descr_VnVs_enums.txt, but this is optional.

EffectsDescription - This points to the description of the game effects you see in the game. Again this can be found in RTW\Data\Text\export_VnVs.txt and RTW\Data\export_descr_VnVs_enums.txt

GainMessage - (Optional) This points to an description in RTW\Data\Text\export_VnVs.txt that appears in the Faction Announcments when the trait is gained. This can also optionally be found in RTW\Data\export_descr_VnVs_enums.txt

LoseMessage - (Optional) The same as with GainMessage.

Epithet - (Optional) This points to a description found in RTW\Data\Text\export_VnVs.txt (and again optionally in RTW\Data\export_descr_VnVs_enums.txt. This description will appear after the characters first name in the game. Note that when assigning traits with epithets to starting generals (by editing Descr_Strat.txt), only Faction Leaders will gain the epithet. Other family members will have the trait, but not the epithet.

Threshold - A character must have the trait at this intensity (see Trigger Data below) in order to gain the trait at this level.

Effect - The actual effect the trait has, followed by the intensity of the effect, with can be positive or negative.

Here is a list of the possible Effects:

  • MovementPoints
  • Command
  • Attack
  • Defence
  • Management
  • Influence
  • TroopMorale
  • SenateStanding
  • PopularStanding
  • Ambush
  • MovementPoints
  • Law
  • SiegeAttack
  • SiegeDefence
  • Construction
  • PublicSecurity
  • Unrest
  • LineOfSight
  • Electability
  • Trading
  • Squalor
  • BribeResistance
  • PersonalSecurity
  • TrainingAgents
  • Subterfuge
  • Negotiation
  • Bribery
  • Farming
  • Mining
  • SiegeEngineering
  • NightBattle
  • NavalCommand
  • HitPoints
  • InfantryCommand
  • CavalryCommand
  • Combat_V_Roman
  • Combat_V_Greek
  • Combat_V_Slave
  • Combat_V_Carthaginian
  • Combat_V_Eastern
  • Combat_V_Barbarian
  • Combat_V_Egyptian
  • Fertility
  • TaxCollection
  • Looting

Step Two

Next we add the trigger data. This is what determines how the trait is gained during gameplay. There can be any number of triggers for a trait. There are two for this one we are creating. One gives a chance of inheriting it from the father, and the second gives a chance to gain it after a losing a battle.

;------------------------------------------
Trigger dad_HatesAmazon
   WhenToTest CharacterComesOfAge
 
   Condition FatherTrait HatesAmazon >= 1
 
   Affects HatesAmazon 1 Chance 25

and

;------------------------------------------
Trigger hate_n_fear13
   WhenToTest PostBattle
   Condition IsGeneral
      and not WonBattle
      and BattleSuccess = crushing
      and I_ConflictType Normal
      and BattleOdds >= 0.5
      and BattleOdds < 1.5
      and GeneralFoughtCulture amazon
   Affects HatesAmazon 1 Chance 40

Trigger - The name of the trigger, this must be unique.

WhenToTest - When the game runs the trigger code to see if a character gains the trait.

Condition - These are a number of conditions which must be present in order to gain the trait.

Affects - This lists the name of the trait gained, followed by the intensity (threshold) it is gained at, then by the chance (1-100) there is to actually gain the trait. The higher the number the more likely the trait will be gained.

A list of WhenToTest is:

  • CharacterComesOfAge
  • PostBattle
  • PreBattleWithdrawal
  • OfferedForAdoption
  • OfferedForMarriage
  • CharacterTurnEnd
  • BecomeAedile
  • BecomeCensor
  • BecomeConsul
  • BecomePontifexMaximus
  • BecomePraetor
  • BecomeQuaestor
  • CeasedAedile
  • CeasedCensor
  • CeasedConsul
  • CeasedPontifexMaximus
  • CeasedPraetor
  • CeasedQuaestor
  • GeneralCaptureSettlement
  • LeaderDestroyedFaction
  • GeneralCaptureWonder
  • CharacterDamagedByDisaster
  • BrotherAdopted
  • LostLegionaryEagle
  • CapturedLegionaryEagle
  • RecapturedLegionaryEagle
  • QuaestorInvestigation
  • QuaestorInvestigationMinor
  • QuaestorInvestigationMajor
  • CharacterMarries
  • CharacterBecomesAFather
  • LeaderOrderedSpyingMission
  • AssassinationMission
  • SufferAssassinationAttempt
  • LeaderOrderedAssassination
  • SabotageMission
  • LeaderOrderedSabotage
  • BriberyMission
  • LeaderOrderedBribery
  • AcceptBribe
  • RefuseBribe
  • Insurrection
  • DiplomacyMission
  • ExecutesAnAssassinOnAMission
  • ExecutesASpyOnAMission
  • LeaderOrderedDiplomacy
  • LeaderSenateMissionSuccess
  • GovernorUnitTrained
  • GovernorBuildingDestroyed
  • GovernorBuildingCompleted
  • AgentCreated
  • GeneralDevastatesTile
  • LesserGeneralOfferedForAdoption
  • BecomesFactionLeader
  • BecomesFactionHeir
  • CeasedFactionHeir
  • GovernorThrowGames
  • GovernorThrowRaces
A list of Conditions are:
  • WasAttacker
  • not WasAttacker
  • IsGeneral
  • WonBattle
  • not WonBattle
  • BattleSuccess = (clear or crushing)
  • I_ConflictType Normal
  • BattleOdds (>= 0.5 or < 1.5)
  • I_WithdrawsBeforeBattle
  • EndedInSettlement
  • RemainingMPPercentage
  • SettlementBuildingExist
  • RandomPercent > (x)
  • Treasury > (x)
  • FatherTrait (trait)
  • CultureType (culture)
  • not CultureType (culture)
  • Trait (trait)
  • GeneralFoughtCulture (culture)
  • EndedInEnemyZOC
  • GeneralHPLostRatioinBattle > (0.3)
  • GeneralNumKillsInBattle > (6 or 8)
  • PercentageEnemyKilled = (0)
  • BattleGeneralRouted
  • IsUnderSiege
  • MissionSuccessLevel = (not_successful, slightly_successful, partly_successful, highly_successful)
  • MissionSucceeded
  • not MissionSucceeded
  • GovernorTaxLevel > (tax_high, tax_low)
  • SettlementBuildingFinished
  • not SettlementBuildingFinished
  • AdviseBuild
  • GovernorLoyaltyLevel = (loyalty_disillusioned)
  • AgentType = (diplomat, spy, or assassin)
  • IsFactionLeader

Step Three (optional)

This step is not needed for RTW 1.5. It will be necessary to work on earlier versions of the game however.

Go to RTW\Data\export_descr_VnVs_enums.txt. In this file add the name in the Trait line from the Trait Data section. Also add the name for each Level, for each Description, and for each EffectsDescription. Finally add in the Epithet if there is one.

So for example, for the Hates Amazon trait above you would add the following:

HatesAmazon
Despises_Amazon_Ways
Despises_Amazon_Ways_desc
Despises_Amazon_Ways_effects_desc
Hates_Amazons
Hates_Amazons_desc
Hates_Amazon_Ways_effects_desc
Loathes_Vile_Amazons
Loathes_Vile_Amazons_desc
Loathes_Vile_Amazons_effects_desc
Loathes_Vile_Amazons_epithet_desc

Step Four

Go to RTW\Data\Text\export_VnVs.txt. This file is where you place the text that you will see in the game when you move your mouse over the trait's name in a character's information scroll.

If you did create the entires for export_descr_VnVs_enums.txt above then simply copy all of them over to the bottom of the file, except the Trait name. Like so:

Despises_Amazon_Ways
Despises_Amazon_Ways_desc
Despises_Amazon_Ways_effects_desc
Hates_Amazons
Hates_Amazons_desc
Hates_Amazon_Ways_effects_desc
Loathes_Vile_Amazons
Loathes_Vile_Amazons_desc
Loathes_Vile_Amazons_effects_desc
Loathes_Vile_Amazons_epithet_desc

Then add {curly brackets} around each line, and add a space between each line. It is not necessary, but you can also place a seperator between the lines for each level. So you have this:

--------------------

{Despises_Amazon_Ways}

{Despises_Amazon_Ways_desc}

{Despises_Amazon_Ways_effects_desc}

--------------------

{Hates_Amazons}

{Hates_Amazons_desc}

{Hates_Amazons_effects_desc}

--------------------

{Loathes_Vile_Amazons}

{Loathes_Vile_Amazons_desc}

{Loathes_Vile_Amazons_effects_desc}

{Loathes_Vile_Amazons_epithet_desc}

--------------------

Now add in your description after the curly brackets of each line. Note that you need to use the Tab key to make a space after the Level name. The other descriptions are commonly placed in a new line beneath the brackets. Like so:

--------------------

{Despises_Amazon_Ways} Despises Amazon Ways

{Despises_Amazon_Ways_desc}
Amazons? The sword's edge is the only gift this general would give them.

{Despises_Amazon_Ways_effects_desc}
+1 Command when fighting against Amazon enemies

--------------------

{Hates_Amazons} Hates Amazons

{Hates_Amazons_desc}
Amazon upstarts are too much for this general, who can think of nothing finer than seeing them dead on the field.

{Hates_Amazons_effects_desc}
+2 Command when fighting against Amazon enemies

--------------------

{Loathes_Vile_Amazons} Loathes Vile Amazons

{Loathes_Vile_Amazons_desc}
Amazons and their unnatural ways drive this general into a controlled, focused rage.

{Loathes_Vile_Amazons_effects_desc}
+3 Command when fighting against Amazon enemies

{Loathes_Vile_Amazons_epithet_desc} the Scourge of the Amazons

--------------------

Step Five

That is it, you are done! Here is a pic of our new trait in the game:

The best way to test a trait you have just made is to assign it to a General in RTW\Data\World\Maps\Camapign\Imperial_Campaign\Descr_Strat.txt. You can find a complete guide on how to edit this file here. Then begin a new campaign as the faction the general belongs to, bring up his information scroll, and mouse over the trait.

"));