[GS] Trying to delete a new building (Flood Barriers)

daisho

Chieftain
Joined
Feb 28, 2019
Messages
1
Hi,

I am trying to create a simple mod that removes Flood Barriers from the game, but somehow I don't really understand why it doesn't work (completely new to civ mods).

Currently my latest try looks like this:
Code:
<GameInfo>
    <!-- Delete base game data that is irrelevant to the scenario.-->
    <Buildings>
        <!-- Buildings -->
        <Delete Type="BUILDING_FLOOD_BARRIER"/>
    </Buildings>
    <DeleteMissingReferences table="Buildings" column="Type"/>
</GameData>

It's probably just a problem that I somehow doing a wrong XML hierarchy or something, not sure.

Thematically:
- Why?
- Just want to add this to a mod that removes flooded tiles, so creating this building would be useless (both for the player and AI).
 
Also the column name is BuildingType in the <Buildings> table.
 
a load order of 1 works just fine too

the expansions have load order 0 (default) so you just need a number higher than that, so that your mod loads after the expansions
With R&F I would have agreed with you as most of my mod LoadOrders were under 100. But post-GS DLC LoadOrders can occasionally get a bit wonky and I've found it's better to go with a much higher LoadOrder just to be on the safe side.
 
Code:
<GameInfo>
    <!-- Delete base game data that is irrelevant to the scenario.-->
    <Buildings>
        <!-- Buildings -->
        <Delete Type="BUILDING_FLOOD_BARRIER"/>
    </Buildings>
    <DeleteMissingReferences table="Buildings" column="Type"/>
</GameData>
Not only are you using the wrong sorts of column-names as @Gedemon mentioned, you have incorrect procedures. You open the code with <GameInfo> and attempt to close it with </GameData>. The opener and closer must both be "GameInfo" or "GameData" and cannot be a mix-and-match of the two.

This line is not needed:
Code:
<DeleteMissingReferences table="Buildings" column="Type"/>
It is Civ5 code. The Schema of Civ6 is defined differently. Firaxis uses the ON DELETE CASCADE ON UPDATE CASCADE (or an equivalent) in their SQL that sets up the tables used by the game wherever there is a Reference requirement.
 
Back
Top Bottom