[BNW] Unlock existing UU & UB for an existing civ ( especially shoshone pathfinder )

Caocao84

Chieftain
Joined
Jan 26, 2023
Messages
4
Hello to anyone reading this, hope I can find some answer after reading dozens of threads on the forum.
First of all thanks to sir Lee S, this guy is a blessing for so many civ 5 players, he provided me dozens of answers to the questions I had, and even to some I did not even think about through all the threads on the forum while he was answering to other people's issues.

In short I would like to use existing UA and UU from other civs, I could edit the UA and add some for Spain in
C:\Program Files (x86)\Steam\steamapps\common\Sid Meier's Civilization V\Assets\DLC\DLC_02\Gameplay\XML\CIV5TRAITS-DLC-02
I just added a few extra UA under the existing ones and It worked ( nothing apears in civilopedia or select screen, but the effects apply in game ):
Spoiler :

<GameData>
<!-- Table data -->
<Traits>
<Row>
<Type>TRAIT_SEVEN_CITIES</Type>
<Description>TXT_KEY_TRAIT_SEVEN_CITIES</Description>
<ShortDescription>TXT_KEY_TRAIT_SEVEN_CITIES_SHORT</ShortDescription>
<NaturalWonderFirstFinderGold>500</NaturalWonderFirstFinderGold>
<NaturalWonderSubsequentFinderGold>100</NaturalWonderSubsequentFinderGold>
<NaturalWonderYieldModifier>100</NaturalWonderYieldModifier>
<NaturalWonderHappinessModifier>100</NaturalWonderHappinessModifier>
<WonderProductionModifier>20</WonderProductionModifier>
<FreeSocialPoliciesPerEra>1</FreeSocialPoliciesPerEra>
<BonusReligiousBelief>true</BonusReligiousBelief>
</Row>


Now my issue comes with unique units like longbowmen, cho ku nu, camel archers, impis, and pathfinders, I would like to unlock 1 or 2 of them depending on the civ I play.

Spain's updated UU are not in Steam\steamapps\common\Sid Meier's Civilization V\Assets\DLC\DLC_02\Gameplay\XML\CIV5Units_DLC_02 (both Tercio and Conquistador only have 18 combat strength there, which are not the right values, but 26 and 20 respectively).

I found their unique units in 2 other folders with the correct values:

Steam\steamapps\common\Sid Meier's Civilization V\Assets\DLC\Expansion\DLC\DLC_02\Gameplay\XML\CIV5Units_DLC_02

Steam\steamapps\common\Sid Meier's Civilization V\Assets\DLC\Expansion2\DLC\DLC_02\Gameplay\XML\CIV5Units_DLC_02

The 2 files located in expansion 1 and 2 contain the proper combat values for Spain's unique units, and when I add unitclassoverride for pathfinder It doesn't work ( no change happens, still have basic scout ).

I read many threads talking about using <Update> but I don't know exactly how and where using It if this can solve my issue, I tried with adding this in unitclassoverrides in each of the 3 Spain's Civilization files separately ( not all 3 at the same time, was afraid to push the experiment further without any additive knowledge) :

Spoiler :

<Row>
<CivilizationType>CIVILIZATION_SPAIN</CivilizationType>
<UnitClassType>UNITCLASS_SCOUT</UnitClassType>
<UnitType>UNIT_SHOSHONE_PATHFINDER</UnitType>
</Row>

In each case It just doesn't change anything in game.

I am wondering what goes wrong now:
- did I make a mistake in the override?
- is It the wrong file location?
- do I need to implement the change in all 3 Spain Civilization files? And do the <insert> <abort> about some of Spain's info in expansion mess with that?
- is the pathfinder considered not a scout because he has higher combat strength, upgrades into composite bowman and costs more than a scout to produce?
- do I need to add the pathfinder in Spain's units file? If yes, do I need to implement all the UNITAI info as well?
- do I need to rename him SPANISH-PATHFINDER?
- all above + even more???
- can I apply the traits changes for civs that are located in expansion with traits from civs located in expansion 2, since expansion is anterior?
- If I want camel archers as Spain or any other civ with UU for knights already existing, how should I process?

I saw that unique buildings could also be unlocked, but since I can't make spanish pathfinders, I won't go further without knowing how to do It properly.

Thanks in advance, below is just the context of how I came to edit XML files and can be skipped.
Spoiler :

After playing for a few hundreds hours ( OK, over 1000 I admit ), and beating deity multiple times fair and square with different civs, I wanted to have some fun and mix UU from other civilizations with IGE, but the best I could do was just creating let's say a cho ku nu and delete my crossbowman when built ( or pathfinder when scout built, but It is already problematic cuz they don't have the same production cost, and every time I open the IGE console, It is a strange feeling, and to be honest It is much longer to load a return to menu and roll a new map when going through mods).

That's how I looked for how to edit the existing civilizations in a different way, and spent many hours on civfanatics.

( I know It is not recommended to edit XML files for some reasons, but I have a backup file of the original if anything goes wrong, and I delete the modifications ).
 
From what I understand, the issue is in the following: Spain was changed in Gods&Kings, and the relevant changes are no longer stored in the DLC files, but rather in the expansion's own. E.g. the "Assets\DLC\Expansion\Gameplay\XML\Civilizations\CIV5Civilizations_Expansion.xml" is containing the lines that remove any DLC data you had from Spain (using <Delete> tags) and adds stuff again. The DLC files are actually unused (they aren't mentioned in the "Expansion1.Civ5Pkg" file), which is why they have zero effect. Why the DLC files are shipped with the expansion at all is not entirely clear to me.

I tried adding the pathfinders on top of Spain's existing UUs through simple duplication and changing the unit class and type, and it worked like a charm. You do have to reload the game data to see the effect, though; you can either turn G&K off->confirm->turn on->confirm, or go to the modded game setup (only as far as you need to get the "Configuring Game Data" popup) and back to the main menu (which will show the same popup again). The latter option appears to be faster, though you need at least one mod to be selected for it to work.
 
From what I understand, the issue is in the following: Spain was changed in Gods&Kings, and the relevant changes are no longer stored in the DLC files, but rather in the expansion's own. E.g. the "Assets\DLC\Expansion\Gameplay\XML\Civilizations\CIV5Civilizations_Expansion.xml" is containing the lines that remove any DLC data you had from Spain (using <Delete> tags) and adds stuff again. The DLC files are actually unused (they aren't mentioned in the "Expansion1.Civ5Pkg" file), which is why they have zero effect. Why the DLC files are shipped with the expansion at all is not entirely clear to me.

I tried adding the pathfinders on top of Spain's existing UUs through simple duplication and changing the unit class and type, and it worked like a charm. You do have to reload the game data to see the effect, though; you can either turn G&K off->confirm->turn on->confirm, or go to the modded game setup (only as far as you need to get the "Configuring Game Data" popup) and back to the main menu (which will show the same popup again). The latter option appears to be faster, though you need at least one mod to be selected for it to work.
Hello, and thanks for answering,can I please ask you to copy paste what you did please? This would greatly help me in understanding how DLC and expansion 1&2 work ( I have tried the UA thing with other civs, and with Arabia It just works fine, but with shoshones for example It crashes the game every time I return to menu ( but still works in game with no problem, as long as I don't go menu ).
 
Hello, and thanks for answering,can I please ask you to copy paste what you did please? This would greatly help me in understanding how DLC and expansion 1&2 work ( I have tried the UA thing with other civs, and with Arabia It just works fine, but with shoshones for example It crashes the game every time I return to menu ( but still works in game with no problem, as long as I don't go menu ).
Spoiler Spanish Pathfinders :
XML:
<Civilization_UnitClassOverrides>
    <!-- Skipping the other unit class overrides... -->
    <Delete CivilizationType="CIVILIZATION_SPAIN"/>
    <Replace>
        <CivilizationType>CIVILIZATION_SPAIN</CivilizationType>
        <UnitClassType>UNITCLASS_MUSKETMAN</UnitClassType>
        <UnitType>UNIT_SPANISH_TERCIO</UnitType>
    </Replace>
    <Replace>
        <CivilizationType>CIVILIZATION_SPAIN</CivilizationType>
        <UnitClassType>UNITCLASS_KNIGHT</UnitClassType>
        <UnitType>UNIT_SPANISH_CONQUISTADOR</UnitType>
    </Replace>
    <!-- This is what I've added -->
    <Replace>
        <CivilizationType>CIVILIZATION_SPAIN</CivilizationType>
        <UnitClassType>UNITCLASS_SCOUT</UnitClassType>
        <UnitType>UNIT_SHOSHONE_PATHFINDER</UnitType>
    </Replace>
    <!-- End of the added section -->
</Civilization_UnitClassOverrides>

This is towards the end of the "Assets\DLC\Expansion\Gameplay\XML\Civilizations\CIV5Civilizations_Expansion.xml" file.

As for Shoshones, making this change in "Assets\DLC\Expansion2\Gameplay\XML\Civilizations\CIV5Traits_Expansion2.xml" using the same effects that you've added to Spain in your first post didn't seem to crash the game on going back to the main menu either. (I can't exactly say if that matters or not, but I have EUI (the UI mod) installed; a crash when going to the menu might perhaps be UI-related)

Spoiler Extra UA effects for Shoshone :
XML:
<Traits>
    <!-- ... -->
    <Row>
        <Type>TRAIT_GREAT_EXPANSE</Type>
        <Description>TXT_KEY_TRAIT_GREAT_EXPANSE</Description>
        <ShortDescription>TXT_KEY_TRAIT_GREAT_EXPANSE_SHORT</ShortDescription>
        <ExtraFoundedCityTerritoryClaimRange>8</ExtraFoundedCityTerritoryClaimRange>
        <NaturalWonderFirstFinderGold>500</NaturalWonderFirstFinderGold>
        <NaturalWonderSubsequentFinderGold>100</NaturalWonderSubsequentFinderGold>
        <NaturalWonderYieldModifier>100</NaturalWonderYieldModifier>
        <NaturalWonderHappinessModifier>100</NaturalWonderHappinessModifier>
        <WonderProductionModifier>20</WonderProductionModifier>
        <FreeSocialPoliciesPerEra>1</FreeSocialPoliciesPerEra>
        <BonusReligiousBelief>true</BonusReligiousBelief>
    </Row>
    <!-- ... -->
</Traits>
 
Last edited:
Spoiler Spanish Pathfinders :
XML:
<Civilization_UnitClassOverrides>
    <!-- Skipping the other unit class overrides... -->
    <Delete CivilizationType="CIVILIZATION_SPAIN"/>
    <Replace>
        <CivilizationType>CIVILIZATION_SPAIN</CivilizationType>
        <UnitClassType>UNITCLASS_MUSKETMAN</UnitClassType>
        <UnitType>UNIT_SPANISH_TERCIO</UnitType>
    </Replace>
    <Replace>
        <CivilizationType>CIVILIZATION_SPAIN</CivilizationType>
        <UnitClassType>UNITCLASS_KNIGHT</UnitClassType>
        <UnitType>UNIT_SPANISH_CONQUISTADOR</UnitType>
    </Replace>
    <!-- This is what I've added -->
    <Replace>
        <CivilizationType>CIVILIZATION_SPAIN</CivilizationType>
        <UnitClassType>UNITCLASS_SCOUT</UnitClassType>
        <UnitType>UNIT_SHOSHONE_PATHFINDER</UnitType>
    </Replace>
    <!-- End of the added section -->
</Civilization_UnitClassOverrides>

This is towards the end of the "Assets\DLC\Expansion\Gameplay\XML\Civilizations\CIV5Civilizations_Expansion.xml" file.

As for Shoshones, making this change in "Assets\DLC\Expansion2\Gameplay\XML\Civilizations\CIV5Traits_Expansion2.xml" using the same effects that you've added to Spain in your first post didn't seem to crash the game on going back to the main menu either. (I can't exactly say if that matters or not, but I have EUI (the UI mod) installed; a crash when going to the menu might perhaps be UI-related)

Spoiler Extra UA effects for Shoshone :
XML:
<Traits>
    <!-- ... -->
    <Row>
        <Type>TRAIT_GREAT_EXPANSE</Type>
        <Description>TXT_KEY_TRAIT_GREAT_EXPANSE</Description>
        <ShortDescription>TXT_KEY_TRAIT_GREAT_EXPANSE_SHORT</ShortDescription>
        <ExtraFoundedCityTerritoryClaimRange>8</ExtraFoundedCityTerritoryClaimRange>
        <NaturalWonderFirstFinderGold>500</NaturalWonderFirstFinderGold>
        <NaturalWonderSubsequentFinderGold>100</NaturalWonderSubsequentFinderGold>
        <NaturalWonderYieldModifier>100</NaturalWonderYieldModifier>
        <NaturalWonderHappinessModifier>100</NaturalWonderHappinessModifier>
        <WonderProductionModifier>20</WonderProductionModifier>
        <FreeSocialPoliciesPerEra>1</FreeSocialPoliciesPerEra>
        <BonusReligiousBelief>true</BonusReligiousBelief>
    </Row>
    <!-- ... -->
</Traits>
Thanks again bro, I will try that asap, there are so many abilities and/or UU/UB that I need to try together.
 
Top Bottom