Dude211212
Chieftain
Hello all.
I can't get my mod to update the Agendas, through SQL or XML. I'm not sure what I'm doing wrong.
I've been working for the past few months on adjusting the AI agendas and traits to make them more aggressive and domination victory focused. I edited the game files in Notepad++ and playtested, and now I'm trying to put those edits into two nice concise mods- 'Aggressive AI Traits' and 'Aggressive AI Agendas'.
The 'Aggressive AI Agendas' changes themselves are not complicated; simply adding agenda traits and updating existing agenda's traits, descriptions, and what leaders they are assigned to. 'Aggressive AI Traits' works fine, however I am having great difficulty getting 'Aggressive AI Agendas' to work at all. I'm not familiar with SQL or XML, but I'm not a stranger to coding or modding in general and I've run out of ideas.
Originally, I had one XML file that both updated and added agenda traits (AggressiveAIAgendasV1, which is in the zip). Everything runs with no errors, but when I boot the game there is no observable changes whatsoever (you can't see agendas traits in-game). After picking through it with a fine tooth comb for errorswithout success, I tried writing the update commands in SQL in a new document (AggressiveAIAgendasUpdates). It still doesn't work. Additionally, I don't have any errors in Database.log, ModBuddy, or during in-game testing.
It seems that adding things works fine in XML, but updating simply does not register. I'm hoping I'm overlooking a simple syntax error or something similar.
<!-- AggressiveAIAgendas -->
<!-- Author: Dude211212 -->
<!-- DateCreated: 5/16/2019 8:00:44 PM -->
<GameData>
<ExclusiveAgendas>
<Row AgendaOne="AGENDA_BILLIONAIRE" AgendaTwo="AGENDA_MONEY_GRUBBER"/>
<Row AgendaOne="AGENDA_CITY_PLANNER" AgendaTwo="AGENDA_INDUSTRIALIST"/>
<Row AgendaOne="AGENDA_PATRON_OF_ARTS" AgendaTwo="AGENDA_TECHNOPHILE"/>
<Row AgendaOne="AGENDA_BARBARIAN_LOVER" AgendaTwo="AGENDA_PILLAGER"/>
<Row AgendaOne="AGENDA_CIVILIZED" AgendaTwo="AGENDA_IDEOLOGUE"/>
<Row AgendaOne="AGENDA_DARWINIST" AgendaTwo="AGENDA_PARANOID"/>
...continues...
</ExclusiveAgendas>
<AgendaTraits>
<Row AgendaType="AGENDA_BLACK_QUEEN" TraitType="TRAIT_AGENDA_ENJOYS_WAR"/>
<Row AgendaType="AGENDA_BLACK_QUEEN" TraitType="TRAIT_AGENDA_PREFER_NUKES"/>
<Row AgendaType="AGENDA_BLACK_QUEEN" TraitType="TRAIT_AGENDA_IGNORE_WARMONGERING"/>
<Row AgendaType="AGENDA_BLACK_QUEEN" TraitType="TRAIT_AGENDA_MAURYA_EMPIRE"/>
...these four repeat for numerous agendas...
</AgendaTraits>
</GameData>
-- Aggressive AI Agendas
-- Author: Dude211212
-- DateCreated: 5/15/2019 8:22:51 PM
--------------------------------------------------------------
-- Historical-Agendas
UPDATE HistoricalAgendas SET AgendaType = 'AGENDA_LORD_OF_MINES' WHERE LeaderType = 'LEADER_BARBAROSSA';
UPDATE HistoricalAgendas SET AgendaType = 'AGENDA_BLACK_QUEEN' WHERE LeaderType = 'LEADER_CLEOPATRA';
UPDATE HistoricalAgendas SET AgendaType = 'AGENDA_SAINT' WHERE LeaderType = 'LEADER_GANDHI';
...this continues for all leaders...
-- Exclusive-Agendas
UPDATE ExclusiveAgendas SET AgendaTwo = 'AGENDA_WONDER_ADVOCATE' WHERE AgendaOne = 'AGENDA_BLACK_QUEEN' AND AgendaTwo = 'AGENDA_GOSSIP';
UPDATE ExclusiveAgendas SET AgendaTwo = 'AGENDA_GREAT_PERSON_ADVOCATE' WHERE AgendaOne = 'AGENDA_DELIAN_LEAGUE' AND AgendaTwo = 'AGENDA_CITY_STATE_ALLY';
UPDATE ExclusiveAgendas SET AgendaTwo = 'AGENDA_CULTURED' WHERE AgendaOne = 'AGENDA_GREAT_PERSON_OBSESSED' AND AgendaTwo = 'AGENDA_GREAT_PERSON_ADVOCATE';
UPDATE ExclusiveAgendas SET AgendaTwo = 'AGENDA_INDUSTRIALIST' WHERE AgendaOne = 'AGENDA_LORD_OF_MINES' AND AgendaTwo = 'AGENDA_MONEY_GRUBBER';
-- Update-Traits
UPDATE AgendaTraits SET TraitType = 'TRAIT_AGENDA_WONDER_OBSESSED' WHERE AgendaType = 'AGENDA_BLACK_QUEEN' AND TraitType='TRAIT_AGENDA_BLACK_QUEEN';
UPDATE AgendaTraits SET TraitType = 'TRAIT_AGENDA_GREAT_PERSON_OBSESSED' WHERE AgendaType = 'AGENDA_DELIAN_LEAGUE' AND TraitType='TRAIT_AGENDA_DELIAN_LEAGUE';
UPDATE AgendaTraits SET TraitType = 'TRAIT_AGENDA_PREFER_CULTURE' WHERE AgendaType = 'AGENDA_GREAT_PERSON_OBSESSED' AND TraitType='TRAIT_AGENDA_GREAT_PERSON_OBSESSED';
UPDATE AgendaTraits SET TraitType = 'TRAIT_AGENDA_LORD_OF_MINES' WHERE AgendaType = 'AGENDA_BILLIONAIRE' AND TraitType='TRAIT_AGENDA_BILLIONAIRE';
...this continues for all used agendas...
--Agenda Descriptions
UPDATE Agendas SET Description = 'LOC_AGENDA_PILLAGER_DESCRIPTION' WHERE AgendaType = 'AGENDA_BARBARIAN_LOVER';
UPDATE Agendas SET Description = 'LOC_TRAIT_AGENDA_PREFER_SAME_GOVERNMENT_DESCRIPTION' WHERE AgendaType = 'AGENDA_CIVILIZED';
UPDATE Agendas SET Description = 'LOC_AGENDA_AIRPOWER_DESCRIPTION' WHERE AgendaType = 'AGENDA_NUKE_LOVER';
UPDATE Agendas SET Description = 'LOC_AGENDA_IDEOLOGUE_DESCRIPTION' WHERE AgendaType = 'AGENDA_DEMAGOGUE';
...and so on for all agenda descriptions that need to change.
<?xml version="1.0" encoding="utf-8"?>
<!-- Aggressive AI Agendas -->
<!-- Author: Dude211212 -->
<!-- DateCreated: 5/5/2019 10:58:46 PM -->
<GameInfo>
<!-- Descriptions -->
<Agendas>
<Update>
<Where AgendaType="AGENDA_BARBARIAN_LOVER" Name="LOC_AGENDA_BARBARIAN_LOVER_NAME" Description="LOC_AGENDA_BARBARIAN_LOVER_DESCRIPTION"/>
<Set>
<Description>"LOC_AGENDA_PILLAGER_DESCRIPTION"</Description>
</Set>
</Update>
...and so on, for all descriptions...
</Agendas>
<!-- Historical-Agendas -->
<HistoricalAgendas>
<Update>
<!-- Base-Game -->
<Where LeaderType="LEADER_BARBAROSSA" AgendaType="AGENDA_IRON_CROWN"/>
<Set>
<AgendaType>"AGENDA_LORD_OF_MINES"</AgendaType>
</Set>
</Update>
<Update>
<Where LeaderType="LEADER_CLEOPATRA" AgendaType="AGENDA_QUEEN_OF_NILE"/>
<Set>
<AgendaType>"AGENDA_BLACK_QUEEN"</AgendaType>
</Set>
</Update>
...and so on, for all leaders....
<HistoricalAgendas>
<!-- Update-Traits -->
<AgendaTraits>
<Update>
<Where AgendaType="AGENDA_BLACK_QUEEN" TraitType="TRAIT_AGENDA_BLACK_QUEEN"/>
<Set>
<TraitType>"TRAIT_AGENDA_WONDER_OBSESSED"</TraitType>
</Set>
</Update>
<Update>
<Where AgendaType="AGENDA_DELIAN_LEAGUE" TraitType="TRAIT_AGENDA_DELIAN_LEAGUE"/>
<Set>
<TraitType>"TRAIT_AGENDA_GREAT_PERSON_OBSESSED"</TraitType>
</Set>
</Update>
...And so on, for all traits...
<AgendaTraits>
Any input would be appreciated. Attached is the zipped mod with the original XML file.
I can't get my mod to update the Agendas, through SQL or XML. I'm not sure what I'm doing wrong.
I've been working for the past few months on adjusting the AI agendas and traits to make them more aggressive and domination victory focused. I edited the game files in Notepad++ and playtested, and now I'm trying to put those edits into two nice concise mods- 'Aggressive AI Traits' and 'Aggressive AI Agendas'.
The 'Aggressive AI Agendas' changes themselves are not complicated; simply adding agenda traits and updating existing agenda's traits, descriptions, and what leaders they are assigned to. 'Aggressive AI Traits' works fine, however I am having great difficulty getting 'Aggressive AI Agendas' to work at all. I'm not familiar with SQL or XML, but I'm not a stranger to coding or modding in general and I've run out of ideas.
Originally, I had one XML file that both updated and added agenda traits (AggressiveAIAgendasV1, which is in the zip). Everything runs with no errors, but when I boot the game there is no observable changes whatsoever (you can't see agendas traits in-game). After picking through it with a fine tooth comb for errorswithout success, I tried writing the update commands in SQL in a new document (AggressiveAIAgendasUpdates). It still doesn't work. Additionally, I don't have any errors in Database.log, ModBuddy, or during in-game testing.
It seems that adding things works fine in XML, but updating simply does not register. I'm hoping I'm overlooking a simple syntax error or something similar.
Spoiler Here is code snippets from the current XML file: :
<!-- AggressiveAIAgendas -->
<!-- Author: Dude211212 -->
<!-- DateCreated: 5/16/2019 8:00:44 PM -->
<GameData>
<ExclusiveAgendas>
<Row AgendaOne="AGENDA_BILLIONAIRE" AgendaTwo="AGENDA_MONEY_GRUBBER"/>
<Row AgendaOne="AGENDA_CITY_PLANNER" AgendaTwo="AGENDA_INDUSTRIALIST"/>
<Row AgendaOne="AGENDA_PATRON_OF_ARTS" AgendaTwo="AGENDA_TECHNOPHILE"/>
<Row AgendaOne="AGENDA_BARBARIAN_LOVER" AgendaTwo="AGENDA_PILLAGER"/>
<Row AgendaOne="AGENDA_CIVILIZED" AgendaTwo="AGENDA_IDEOLOGUE"/>
<Row AgendaOne="AGENDA_DARWINIST" AgendaTwo="AGENDA_PARANOID"/>
...continues...
</ExclusiveAgendas>
<AgendaTraits>
<Row AgendaType="AGENDA_BLACK_QUEEN" TraitType="TRAIT_AGENDA_ENJOYS_WAR"/>
<Row AgendaType="AGENDA_BLACK_QUEEN" TraitType="TRAIT_AGENDA_PREFER_NUKES"/>
<Row AgendaType="AGENDA_BLACK_QUEEN" TraitType="TRAIT_AGENDA_IGNORE_WARMONGERING"/>
<Row AgendaType="AGENDA_BLACK_QUEEN" TraitType="TRAIT_AGENDA_MAURYA_EMPIRE"/>
...these four repeat for numerous agendas...
</AgendaTraits>
</GameData>
Spoiler Here is code snippets from the current SQL file: :
-- Aggressive AI Agendas
-- Author: Dude211212
-- DateCreated: 5/15/2019 8:22:51 PM
--------------------------------------------------------------
-- Historical-Agendas
UPDATE HistoricalAgendas SET AgendaType = 'AGENDA_LORD_OF_MINES' WHERE LeaderType = 'LEADER_BARBAROSSA';
UPDATE HistoricalAgendas SET AgendaType = 'AGENDA_BLACK_QUEEN' WHERE LeaderType = 'LEADER_CLEOPATRA';
UPDATE HistoricalAgendas SET AgendaType = 'AGENDA_SAINT' WHERE LeaderType = 'LEADER_GANDHI';
...this continues for all leaders...
-- Exclusive-Agendas
UPDATE ExclusiveAgendas SET AgendaTwo = 'AGENDA_WONDER_ADVOCATE' WHERE AgendaOne = 'AGENDA_BLACK_QUEEN' AND AgendaTwo = 'AGENDA_GOSSIP';
UPDATE ExclusiveAgendas SET AgendaTwo = 'AGENDA_GREAT_PERSON_ADVOCATE' WHERE AgendaOne = 'AGENDA_DELIAN_LEAGUE' AND AgendaTwo = 'AGENDA_CITY_STATE_ALLY';
UPDATE ExclusiveAgendas SET AgendaTwo = 'AGENDA_CULTURED' WHERE AgendaOne = 'AGENDA_GREAT_PERSON_OBSESSED' AND AgendaTwo = 'AGENDA_GREAT_PERSON_ADVOCATE';
UPDATE ExclusiveAgendas SET AgendaTwo = 'AGENDA_INDUSTRIALIST' WHERE AgendaOne = 'AGENDA_LORD_OF_MINES' AND AgendaTwo = 'AGENDA_MONEY_GRUBBER';
-- Update-Traits
UPDATE AgendaTraits SET TraitType = 'TRAIT_AGENDA_WONDER_OBSESSED' WHERE AgendaType = 'AGENDA_BLACK_QUEEN' AND TraitType='TRAIT_AGENDA_BLACK_QUEEN';
UPDATE AgendaTraits SET TraitType = 'TRAIT_AGENDA_GREAT_PERSON_OBSESSED' WHERE AgendaType = 'AGENDA_DELIAN_LEAGUE' AND TraitType='TRAIT_AGENDA_DELIAN_LEAGUE';
UPDATE AgendaTraits SET TraitType = 'TRAIT_AGENDA_PREFER_CULTURE' WHERE AgendaType = 'AGENDA_GREAT_PERSON_OBSESSED' AND TraitType='TRAIT_AGENDA_GREAT_PERSON_OBSESSED';
UPDATE AgendaTraits SET TraitType = 'TRAIT_AGENDA_LORD_OF_MINES' WHERE AgendaType = 'AGENDA_BILLIONAIRE' AND TraitType='TRAIT_AGENDA_BILLIONAIRE';
...this continues for all used agendas...
--Agenda Descriptions
UPDATE Agendas SET Description = 'LOC_AGENDA_PILLAGER_DESCRIPTION' WHERE AgendaType = 'AGENDA_BARBARIAN_LOVER';
UPDATE Agendas SET Description = 'LOC_TRAIT_AGENDA_PREFER_SAME_GOVERNMENT_DESCRIPTION' WHERE AgendaType = 'AGENDA_CIVILIZED';
UPDATE Agendas SET Description = 'LOC_AGENDA_AIRPOWER_DESCRIPTION' WHERE AgendaType = 'AGENDA_NUKE_LOVER';
UPDATE Agendas SET Description = 'LOC_AGENDA_IDEOLOGUE_DESCRIPTION' WHERE AgendaType = 'AGENDA_DEMAGOGUE';
...and so on for all agenda descriptions that need to change.
Spoiler Here is code snippets from the original XML file: :
<?xml version="1.0" encoding="utf-8"?>
<!-- Aggressive AI Agendas -->
<!-- Author: Dude211212 -->
<!-- DateCreated: 5/5/2019 10:58:46 PM -->
<GameInfo>
<!-- Descriptions -->
<Agendas>
<Update>
<Where AgendaType="AGENDA_BARBARIAN_LOVER" Name="LOC_AGENDA_BARBARIAN_LOVER_NAME" Description="LOC_AGENDA_BARBARIAN_LOVER_DESCRIPTION"/>
<Set>
<Description>"LOC_AGENDA_PILLAGER_DESCRIPTION"</Description>
</Set>
</Update>
...and so on, for all descriptions...
</Agendas>
<!-- Historical-Agendas -->
<HistoricalAgendas>
<Update>
<!-- Base-Game -->
<Where LeaderType="LEADER_BARBAROSSA" AgendaType="AGENDA_IRON_CROWN"/>
<Set>
<AgendaType>"AGENDA_LORD_OF_MINES"</AgendaType>
</Set>
</Update>
<Update>
<Where LeaderType="LEADER_CLEOPATRA" AgendaType="AGENDA_QUEEN_OF_NILE"/>
<Set>
<AgendaType>"AGENDA_BLACK_QUEEN"</AgendaType>
</Set>
</Update>
...and so on, for all leaders....
<HistoricalAgendas>
<!-- Update-Traits -->
<AgendaTraits>
<Update>
<Where AgendaType="AGENDA_BLACK_QUEEN" TraitType="TRAIT_AGENDA_BLACK_QUEEN"/>
<Set>
<TraitType>"TRAIT_AGENDA_WONDER_OBSESSED"</TraitType>
</Set>
</Update>
<Update>
<Where AgendaType="AGENDA_DELIAN_LEAGUE" TraitType="TRAIT_AGENDA_DELIAN_LEAGUE"/>
<Set>
<TraitType>"TRAIT_AGENDA_GREAT_PERSON_OBSESSED"</TraitType>
</Set>
</Update>
...And so on, for all traits...
<AgendaTraits>
Any input would be appreciated. Attached is the zipped mod with the original XML file.
Attachments
Last edited: