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!
The tutorials in the mod tutorial thread are nice, and useful, but I'd like to ask for a tutorial on adding a faction trait similar to Strength of the Vault, or Deep Generator. Basically a trait which adds a research to the tree without starting with it researched. Adding a trait that unlocks a tech from the start is easy, but adding a tech without unlocking it from the start seems noticeably more involved, and it's a bit difficult to tell what all is required from looking at the base game files.
Really what I want to do is just add traits that make the Exotic Alloys and Exotic Armor techs researchable without having to get them from quests, but I'm having trouble figuring it out.
I think you will need to duplicate the two techs (the original to be unlocked through quests, the copy to be unlocked through research). Otherwise I don't (yet) know how you would do it.
Part 1) Game effects
1. Create the SimulationDescriptor in SimulationDescriptors[FactionTrait].xml (all you are doing here is creating a "tag" of sorts) e.g.
[code]
[/code]
For technologies, "TechnologyDefinitionArmorCommonTier3" and "TechnologyDefinitionWeaponCommonTier3" refer to Exotic Armor and Exotic Alloys respectively.
2. Make copies of the relevant technologies in DepartmentOfScience+Constructibles[Era2Technology].xml (BUT change the parent, add the faction prerequisite, and have the technology cost science and increase the technology count), and paste into DepartmentOfScience+Constructibles[Custom].xml.
e.g. Using TechnologyDefinitionArmorCommonTier3 in [Era2Technology] and TechnologyDefinitionVaulters3Custom in [Custom] as references, place in [Custom]:
Notice that under PathPrerequisite you have used the faction trait tag you created in step 1.
3. Create a GUI element for the custom technology in GuiElements[Technology].xml, by simply duplicating and renaming it e.g.
[code]
%TechnologyDefinitionArmorCommonTier3Title
%TechnologyDefinitionArmorCommonTier3Description
[/code]
Existing localisation pairs are used, and so they do not need to be created.
Part 2) The trait
1. Define the faction trait "FactionTraitExoticArmor" in FactionTraits[Custom].xml and add as an effect the SimulationDescriptor "FactionTraitExoticArmor" from Part 1
e.g.
[code]
[/code]
2. Create a GUI Element for the faction trait in GuiElements[FactionTraits].xml, using FactionTraitVaulters3Custom as a reference. Cheating a bit, we will make this almost the same as the GUI element in Part 1, but we remove some information (GuiElement instead of TechnologyGuiElement, no X or Y coordinates, no TechnologyEraReference) and change the name e.g.:
[code]
%TechnologyDefinitionArmorCommonTier3Title
%TechnologyDefinitionArmorCommonTier3Description
[/code]
Existing localisation pairs are used, and so they do not need to be created.
You will need to repeat the above from step 2 of part 1 for Exotic Alloys.
Screenshots:
Possible Issues:
- Because of the duplication, it will be possible to have both Exotic Armor and Exotic Armor Custom, but their effects will not stack. They are two separate, but identical technologies. Unlocking one will not unlock the other. One work-around may be to add a prerequisite for the original such that you can't access the original via quest if you have this custom faction trait, implying that you can only research this tech (custom) and never access it via quest (original).
Another possibility might be to, instead of duplicating the tech, simply convert the original tech to a researchable tech that requires a prerequisite (part 1 step 2). Part 1 step 3 will then be unnecessary since there is no new tech. Part 2 will all be necessary (but get rid of the "Custom" appellation). I'm hoping that doesn't mess with quest rewards for your faction or other factions, but I have a feeling that it may very well do (because of the faction trait prerequisite you added).
Thank you so much for the detailed help, Tigregalis, but I'm having another set of problems with modding.
I followed your guide exactly and while it seems to work just fine for 'normal' technologies and traits, it doesn't seem to work for technologies that come from quests. Specifically, I'm trying to mod Sacrificial Amplifiers and Secrets of the Virtuals. The former is a normal unlock and it works just fine, letting me push it up and down the tech tree and select it as normal. Unfortunately, Secrets of the Virtuals has no such luck. I'm able to add it in character creation just fine and the tooltips are working properly -- however, it doesn't show up in the actual research screen in the right place. I even tried switching around the X and Y coordinates to see if that would help, but it never showed up even when I hotswapped it with a technology that did.
What should I do to make this and similar quest unlocks visible without having to do the quest?
I have been trying and failing to do something like this for the past several hours. If you gentlemen happen to have a solution for these sorts of things, please consider posting it as a standalone mod.
After spending a few more fruitless hours tinkering around, at this point I'm almost convinced that the real problem is that this duplicated modded trait (Secrets of the Virtuals) is conflicting with the 'base' trait and that's what's taking precedence. Unfortunately, I don't know what to put in to tell the game 'no, treat it as a normal trait, not something that's behind a quest wall'. Any ideas?
Just a quick update; I deleted everything, downloaded the exotic.zip file attached to this thread, then did everything EXACTLY as the tutorial said, using the examples as a template. And now it works just fine.
I don't have the old files anymore, but what I suspect that I did wrong was that I never changed TechnologyFlags="VisibleWhenUnlocked" to TechnologyFlags="Affinity". It is like that now and what was once a quest tech is now visible in the technology screen and ready to be unlocked. Shows the importance of following steps exactly, I suppose.
GammaPaladin
Newcomer
GammaPaladin
Newcomer
100g2g ptsReport comment
Why do you report GammaPaladin?
Are you sure you want to block GammaPaladin ?
BlockCancelAre you sure you want to unblock GammaPaladin ?
UnblockCancelTigregalis
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 ?
UnblockCancelGammaPaladin
Newcomer
GammaPaladin
Newcomer
100g2g ptsReport comment
Why do you report GammaPaladin?
Are you sure you want to block GammaPaladin ?
BlockCancelAre you sure you want to unblock GammaPaladin ?
UnblockCancelTigregalis
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 ?
UnblockCancelRofel_Wodring
Newcomer
Rofel_Wodring
Newcomer
100g2g ptsReport comment
Why do you report Rofel_Wodring?
Are you sure you want to block Rofel_Wodring ?
BlockCancelAre you sure you want to unblock Rofel_Wodring ?
UnblockCancelHael
Newcomer
Hael
Newcomer
1 700g2g ptsReport comment
Why do you report Hael?
Are you sure you want to block Hael ?
BlockCancelAre you sure you want to unblock Hael ?
UnblockCancelRofel_Wodring
Newcomer
Rofel_Wodring
Newcomer
100g2g ptsReport comment
Why do you report Rofel_Wodring?
Are you sure you want to block Rofel_Wodring ?
BlockCancelAre you sure you want to unblock Rofel_Wodring ?
UnblockCancelRofel_Wodring
Newcomer
Rofel_Wodring
Newcomer
100g2g ptsReport comment
Why do you report Rofel_Wodring?
Are you sure you want to block Rofel_Wodring ?
BlockCancelAre you sure you want to unblock Rofel_Wodring ?
UnblockCancel