1. We have added a Gift Upgrades feature that allows you to gift an account upgrade to another member, just in time for the holiday season. You can see the gift option when going to the Account Upgrades screen, or on any user profile screen.
    Dismiss Notice

Custom XML File

Discussion in 'Civ6 - Creation & Customization' started by Thorn, Oct 26, 2016.

  1. Thorn

    Thorn Chieftain

    Joined:
    Jan 5, 2002
    Messages:
    816
    Location:
    Project Tic-Toc
    I want to change one of the default XML files (in this case Technologies.xml). I'm not sure how to configure the .modinfo file or where to put the new Technologies.xml file. I'm sure it's simple but I can't get it to work. Can someone help? I put the new Technologies.xml file in my mod root directory. Here's what I put in the .modinfo file:

    <Mod id="111-1">
    <Files>
    <File>Technologies.xml</File>
    </Files>
    </Mod>
     
  2. Thorn

    Thorn Chieftain

    Joined:
    Jan 5, 2002
    Messages:
    816
    Location:
    Project Tic-Toc
    Ok, finally figured this out. It required the .modinfo file and a new Technologies.xml file (but NOT named Technologies.xml). You have to use a custom file name and use <Replace to actually change the information in the desired .xml file. Here's what the .modinfo file looks like:

    Code:
    <?xml version="1.0" encoding="utf-8"?>
    <Mod id="edaf340a-f95c-4665-ad54-7e97635dd568" version="1">
        <Properties>
            <Name>TechTimeMod</Name>
            <Teaser>TechTimeMod</Teaser>
            <Description>TechTimeMod</Description>
            <Authors>Thorn</Authors>
        </Properties>
        <Components>
            <UpdateDatabase id="TechTimeMod_COMPONENT">
                <Properties>
                    <Ruleset>RULESET_STANDARD</Ruleset>
                </Properties>
                <Items>
                    <File>TechTimeMod_Technologies.xml</File>
                </Items>
            </UpdateDatabase>
        </Components>
        <Files>
            <File>TechTimeMod_Technologies.xml</File>
        </Files>
    </Mod>
    So, to change the research time ('Cost') for Pottery, this is what the file TechTimeMod_Technologies.xml would look like:
    Code:
    <?xml version="1.0" encoding="utf-8"?>
    <!-- edited with XMLSPY v2004 rel. 2 U (http://www.xmlspy.com) by Ed Beach (Firaxis Games) -->
    <GameInfo>
        <Technologies>
            <!-- Ancient Era-->
            <Replace TechnologyType="TECH_POTTERY" Name="LOC_TECH_POTTERY_NAME" Description="LOC_TECH_POTTERY_DESCRIPTION" Cost="999" AdvisorType="ADVISOR_GENERIC" EraType="ERA_ANCIENT" UITreeRow="0"/>
        </Technologies>
    </GameInfo>
    That will override the line in the original Technologies.xml file.

    Thanks everyone for all the help! :rolleyes:
     

Share This Page