ENDLESS™ Legend is a turn-based 4X fantasy-strategy game, where you control every aspect of your civilization as you struggle to save your homeworld Auriga. Create your own Legend!
In response to this thread(link), I made the following mod / tutorial. Since it's such a basic mod that changes one thing for one unit, it's more of an exploration of how to implement it, than a useful mod.
1.
If you want no winter movement penalty, you can use:
A) UnitAbilityImmuneToWinterMovementPenalty
If you want complete winter immunity, you can use:
B) UnitAbilityDarkProof
2.
Let's go deeper. These abilities are defined in:
\Simulation\UnitAbilities.xml
A)
[code]
[/code]
B)
[code]
[/code]
These are the abilities that appear in the "traits" section of the unit view.
Side-note, these abilities are described and made visible in the GUI here:
\Gui\GuiElements[UnitAbilities].xml
The actual text is localised here, but if you omit the % symbol you can give an absolute description rather than a localised description:
We aren't making changes to abilities so we don't really care.
3.
Furthermore, the effects of each of these Winter-based "SimulationDescriptors" are defined in:
\Simulation\SimulationDescriptors[Season].xml
like so:
[code]
[/code]
You'll notice that for each of the Immunity's there's nothing between the tags, that's because it's basically a "null effect" - i.e. rather than having a malus (e.g. WinterMovementReduction), it does nothing instead.
Compared to 2. which chooses which effects to use for each ability, these SimulationDescriptors describe the actual in-game effects.
4.
Let's go even deeper. Each of these unit attributes / properties (e.g. VisionRange) is defined in:
\Simulation\SimulationDescriptors[Class].xml
What each of them do, you'll just have to figure out based on the name, because I assume this is the point where the XML code interfaces with the underlying game. I could be wrong though. Every other XML file only modifies these properties.
Each of these properties applies to a certain class. And here's the point where I'm still trying to figure things out.
5.
Back to the top now. Let's give the Ice Warg the ability "Dark Proof" (complete winter immunity).
The definition for Geldirus / Ice Warg is found in:
\Simulation\UnitBodyDefinitions.xml
Look at, say, Hurnas Orc:
[code]
...
[/code]
Clearly, you place any unit abilities between the UnitBodyDefinition tags. From this, you would conclude that you (essentially) add the new unit ability to that XML file between the existing UnitBodyDefinition tags:
[code]
[/code]
Yes, all of that explanation for such a simple change. But never mind.
6.
Now to implementing the mod.
i) First, we create a new folder in My Documents\Endless Legend\Community called NiceWarg
ii) Then we download ModdingReference.rar from [URL=https://www.games2gether.com/endless-legend/forum/15-modding/thread/5777-tutorials-for-modding-endless-legendandextractittothefolderwecreatedabove:MyDocuments\EndlessLegend\CommunityNiceWarg
Grants winter immunity to the Geldirus minor faction unit Ice Warg.
[/code]
v) we re-create the Simulation folder in NiceWarg: My Documents\Endless Legend\CommunityNiceWarg\Simulation
And for ease, we copy the steamapps\Endless Legend\Public\Simulation[/I]UnitBodyDefinitions.xml file into our new folder.
vi) We open and edit the UnitBodyDefinitions.xml file. First we remove all of the unrelated UnitBodyDefinition tags we aren't making changes to (all except the Geldirus faction unit). My assumption is that mod tags effectively overwriteexisting tags if using the same name (in this case UnitBodyGeldirusIceWarg), so we can't just add our one line, but we must keep the entire UnitBodyDefinition tag for the Geldirus faction in order to preserve the actual unit. So the entire content of our xml file is (with my single line addition in bold):
$Path(.../EmpireTypeMajor/EmpireTypeMinor,AffinityGeldirus) or $Path(.../EmpireTypeMinor,AffinityGeldirus)
$Path(.../EmpireTypeMajor/EmpireTypeMinor,AffinityGeldirus) or $Path(.../EmpireTypeMinor,AffinityGeldirus)
($Property(ClassCity,Garrison:MaximumUnitSlotCount) - $Property(ClassCity,Garrison:UnitSlotCount)) ge 1
[/code]
7. Now we can select the mod in-game and play the game.
Notes:
- You could, of course, create your own UnitAbility instead of using the existing Dark Proof one, and make the appropriate changes, making sure to add the new UnitAbility in \Gui\GuiElements[UnitAbilities].xml and \Localization[language]\EF_Localization_Assets_Locales.xml as necessary.
- I wish there was some sort of map relating each of the d
Tigregalis
Newcomer
Tigregalis
Newcomer
100g2g ptsReport comment
Why do you report Tigregalis?
Are you sure you want to block Tigregalis ?
BlockCancelAre you sure you want to unblock Tigregalis ?
UnblockCancelKingsguard
Old Fanatic
Winter is coming.
Kingsguard
Old Fanatic
24 500g2g ptsReport comment
Why do you report Kingsguard?
Are you sure you want to block Kingsguard ?
BlockCancelAre you sure you want to unblock Kingsguard ?
UnblockCancel