Changing Text for Compatibility with Multiple Mods

InkAxis

King
Joined
Feb 24, 2020
Messages
779
So I have this problem and I've been trying for a bit to solve it but I think I just don't have enough understanding of SQL to solve it.
So in my case, I have a mod that adds multiple buildings, and I want those buildings to change slightly to be compatible with other mods. As a hypothetical example, let's say I have a building that I want to add +1 gold if Mod A is active. Also, I want it to get +1 Culture if Mod B is active. Now this isn't hard at all. The problem I'm getting is with the text.
In this case, I would have four different Help texts:
"+1 Gold." - If Mod A is active
"+1 Culture." -If Mod B is active
"+1 Gold. +1 Culture." -If both are active
And neither if none of the mods are active.
Now it's not to hard to update the text 4 times depending on which mods are active, but this gets out of control pretty fast. I have three mods I am trying to have compatibility with, which isn't that much. So that would mean 9 options. But, I also have 10 buildings. Meaning I would have to make 90 entries. Yeah.
So I was wondering if anyone knew how to make it modular.

So with example code, for the example building, I would want something like:
Code:
INSERT INTO Language_en_US (Tag, Text)
SELECT
'TXT_KEY_BUILDING_EXAMPLE_HELP', GoldText || CultureText || 'Building Description'
FROM ???

So I would want GoldText to be "+1 Gold" if the Mod is active, "" Otherwise. same with CultureText. And I can figure out how to set those columns but then I'm not sure where to select from. That's the best I got, how should I do it?
 
Top Bottom