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.

Want to play a different Civilization game ?
Interested by Revolutions, Supply Lines, Front Lines, Resources stockpile and much more ?
Help me design and develop my most ambitious modding project so far.​

I know you guys are talking about art defines but I thought I'd share my experience in case this helps. I am also experiencing a loading order problem with the Poland DLC. My fix is to duplicate the Gamedata xml from the DLC and put it in my mod. I replace all instances of <Row> With <Replace> in the gamedata added to my mod to make sure the data loads if the mod loads after the DLC. My unit changes will always reference the data added to my mod because I attach it to the end of the Gamedata file. If the DLC loads after my mod then the data file in the DLC gets dumped and has no affect on the game. I have found the load order reverses when a saved game is loaded.

.... I have found the load order reverses when a saved game is loaded.

Click to expand...

Wonderful.

Did you try the <LoadOrder> property? Both the PolandScenario.modinfo and VikingScenario.modinfo set it to 100 for their <UpdateDatabase>. I'd been assuming it would refer to the load order *within* a mod since <Dependencies> and <References> see designed to control the load order between mods, but maybe it actually works between mods instead. I know testing it within a mod on different <GameplayScript> components did nothing (though <GameplayScript> has other issues as well, like apparently only allowing 1 file per component).

Did you try the <LoadOrder> property? Both the PolandScenario.modinfo and VikingScenario.modinfo set it to 100 for their <UpdateDatabase>. I'd been assuming it would refer to the load order *within* a mod since <Dependencies> and <References> see designed to control the load order between mods, but maybe it actually works between mods instead. I know testing it within a mod on different <GameplayScript> components did nothing (though <GameplayScript> has other issues as well, like apparently only allowing 1 file per component).

Click to expand...

I haven't tried the <LoadOrder> property. But I was having a load order problem within a mod when the xml files were in separate folders. The problem went away when I placed the files in the same folder. It doesn't make any sense to me.

I haven't tried the <LoadOrder> property. But I was having a load order problem within a mod when the xml files were in separate folders. The problem went away when I placed the files in the same folder. It doesn't make any sense to me.

Click to expand...

Load order inside a mod it determined by 2 factors. 1) Components - Seems to Load top to bottom. 2) Order of your files in the <Files> Tags this also effects what files to load in what order inside each component. The order iside each component is ignored, it always goes by the order inside <Files> .

There's also a "Priority" attribute you can use with <File> under <Items> that presumably should let you set the order within a component, but when I was testing it, I was using <GameplayScript> which is broken with more than 1 file anyway, so I haven't actually tested it with a working component and don't know if higher or lower numbers should load first, if it works at all.

Load order inside a mod it determined by 2 factors. 1) Components - Seems to Load top to bottom. 2) Order of your files in the <Files> Tags this also effects what files to load in what order inside each component. The order iside each component is ignored, it always goes by the order inside <Files> .

Click to expand...

This is what I thought also but I was still having a problem with saved games not loading properly. I would need to test it again to confirm.

I kept trying to reproduce what you experienced, about having your mod load after the DLC when you created a game, but before the DLC when you loaded a game. No matter what I did, my mod *always* loaded after the DLC.

Then, looking at the log, I got a hunch, that turned out to be right, and allowed me to reproduce what you experienced.. During game creation, mods load according to their ModRowId in mods.sqlite. However, during game loading, mods load according to the alpha-numerical sorting of their ModId--i.e., the value of the "id" attribute in the root <Mod> attribute of the .modinfo.

Start your ModId with "00", and when you reload a game, it will always load before the DLC. Start your ModId with "Z", and it will always load after the DLC when you reload a game.

Since the highest DLC id so far starts with "38...", you would have never discovered this issue if your ID had started with "4" or higher. Unfortunately, the GUID gods punished you with a "039...", meaning on reloads you come before everything except the Aztec DLC ("02A...").

Of course you can't change your ModId now without breaking saved games, but I've learned a lot in the past few hours about how "Priority" and "LoadOrder" work, I'm going to start a new thread on mod, component, and file load order in a few hours once I finish testing whether what I've found also holds for <ModArt>, etc., but what I've found out already can fix your issues--for UpdateDatabase and Gameplayscripts, at least, <LoadOrder> does cross mod boundaries, with the highest component loading last no matter what mod it is in; and within a component, Priority gives a deterministic load order, but this time with the highest loading first.

I kept trying to reproduce what you experienced, about having your mod load after the DLC when you created a game, but before the DLC when you loaded a game. No matter what I did, my mod *always* loaded after the DLC.

Then, looking at the log, I got a hunch, that turned out to be right, and allowed me to reproduce what you experienced.. During game creation, mods load according to their ModRowId in mods.sqlite. However, during game loading, mods load according to the alpha-numerical sorting of their ModId--i.e., the value of the "id" attribute in the root <Mod> attribute of the .modinfo.

Start your ModId with "00", and when you reload a game, it will always load before the DLC. Start your ModId with "Z", and it will always load after the DLC when you reload a game.

Since the highest DLC id so far starts with "38...", you would have never discovered this issue if your ID had started with "4" or higher. Unfortunately, the GUID gods punished you with a "039...", meaning on reloads you come before everything except the Aztec DLC ("02A...").

Of course you can't change your ModId now without breaking saved games, but I've learned a lot in the past few hours about how "Priority" and "LoadOrder" work, I'm going to start a new thread on mod, component, and file load order in a few hours once I finish testing whether what I've found also holds for <ModArt>, etc., but what I've found out already can fix your issues--for UpdateDatabase and Gameplayscripts, at least, <LoadOrder> does cross mod boundaries, with the highest component loading last no matter what mod it is in; and within a component, Priority gives a deterministic load order, but this time with the highest loading first.

Is it possible to add FontIcons currently? What I'm trying doesn't seem to be working.

Click to expand...

Is there any info on this? I wouldn't even need to add a new icon, I'd just need to add a new entry for an already existing one (the icon for the city center is named as DISTRICT_CITYCENTER instead of DISTRICT_CITY_CENTER, and the latter is being used in the database...).
When I edit the UI/FontIcons.xml directly it works, but I don't seem to be able to add an entry to it via a mod or even replace the file as a whole.

Is there any info on this? I wouldn't even need to add a new icon, I'd just need to add a new entry for an already existing one (the icon for the city center is named as DISTRICT_CITYCENTER instead of DISTRICT_CITY_CENTER, and the latter is being used in the database...).
When I edit the UI/FontIcons.xml directly it works, but I don't seem to be able to add an entry to it via a mod or even replace the file as a whole.

Click to expand...

Yeah, this is my main barrier to adding new resources. Technically it works, but you need to be able to change FontIcons.xml or else the Reports screen gets messed up when trying to display the new resources (it just shows up as ICON_RESOURCENAME and covers the name of the city it's going to). I haven't been able to find anything that works except editing the file manually as you said.

I kept trying to reproduce what you experienced, about having your mod load after the DLC when you created a game, but before the DLC when you loaded a game. No matter what I did, my mod *always* loaded after the DLC.

Then, looking at the log, I got a hunch, that turned out to be right, and allowed me to reproduce what you experienced.. During game creation, mods load according to their ModRowId in mods.sqlite. However, during game loading, mods load according to the alpha-numerical sorting of their ModId--i.e., the value of the "id" attribute in the root <Mod> attribute of the .modinfo.

Start your ModId with "00", and when you reload a game, it will always load before the DLC. Start your ModId with "Z", and it will always load after the DLC when you reload a game.

Since the highest DLC id so far starts with "38...", you would have never discovered this issue if your ID had started with "4" or higher. Unfortunately, the GUID gods punished you with a "039...", meaning on reloads you come before everything except the Aztec DLC ("02A...").

Of course you can't change your ModId now without breaking saved games, but I've learned a lot in the past few hours about how "Priority" and "LoadOrder" work, I'm going to start a new thread on mod, component, and file load order in a few hours once I finish testing whether what I've found also holds for <ModArt>, etc., but what I've found out already can fix your issues--for UpdateDatabase and Gameplayscripts, at least, <LoadOrder> does cross mod boundaries, with the highest component loading last no matter what mod it is in; and within a component, Priority gives a deterministic load order, but this time with the highest loading first.

For artdefs, you *have* to use the same name as the file you are adding to

Click to expand...

I'm not so sure about this. I found that the file name you have to put in the .dep file is not the name of the file in the base game, it's the name of your .artdef file. So if, for instance, you put units.artdef in your .dep and name your file newunit.artdef it won't work, but it's not (as far as I can tell) because they're different – it's because you needed to put newunit.artdef in your .dep.

That said I'm as new as it gets to modding and can barely get my units to show, leaving my custom district that's meant to look like a Mbanza and my custom improvement that's meant to look like a goody hut not showing. I ran across this thread while looking for ways to get those two showing, which I presume has something to do with my .dep.

If anyone knows that I'm talking gibberish please correct me, as I'm very confused and all (polite) input is welcome.

What am I missing..? Every things is is working except that the actual Improvement isn't visible...
(The improvement: Kurgan was used as a base.)

Click to expand...

I suspect (though I'm far from certain) that your issue may not be in that file at all: Is the file referenced in your .dep?

I'd be certain, except that I'm having the same problem. If you get to the bottom of it please reply with details because though my experimentation with my .dep has made my units appear as required my improvement is still invisible.

Neither of those .xml files is mentioned elsewhere in this article so I don't see what this section achieves.

Also the Art/Icons/Tech folder isn't described in the directory structure, so I'm unclear about where the relative folder location starts for the purpose of getting the ImportFiles to process the files. Also, does the ID of the ImportFiles matter?