How does the order of loading files/mods matter?

ArgonV

Chieftain
Joined
Oct 21, 2010
Messages
5
Hey guys, I've got a couple of assumptions which I'd like to run by you.

1 - loading files into a mod. Say I've got two files in a mod. One is an SQL file that changes the costs of all buildings by a percentage, the other is an XML file that loads a custom building.
If I load the building first, then the cost modifier, the cost of the custom building would be modified, right? If I load the cost modifier first, then the custom building, all the standard buildings would be modified and then custom building would be loaded, with the original, unmodified cost stated in the XML file, right?

2 - Same principle, except with mods. One mod modifies the cost of buildings, another loads custom buildings. Provided the buildings are added first and then the costs modified, the added buildings would have modded construction costs. However, how does the game decide which mod comes first? Is it alphabetically or something?
 
Hey guys, I've got a couple of assumptions which I'd like to run by you.

1 - loading files into a mod. Say I've got two files in a mod. One is an SQL file that changes the costs of all buildings by a percentage, the other is an XML file that loads a custom building.
If I load the building first, then the cost modifier, the cost of the custom building would be modified, right? If I load the cost modifier first, then the custom building, all the standard buildings would be modified and then custom building would be loaded, with the original, unmodified cost stated in the XML file, right?

2 - Same principle, except with mods. One mod modifies the cost of buildings, another loads custom buildings. Provided the buildings are added first and then the costs modified, the added buildings would have modded construction costs. However, how does the game decide which mod comes first? Is it alphabetically or something?

For #2, I believe it is activation order in the modbrowser. In fact, I'm almost 100% that's the right answer.

For #1, I think it loads the entire mod in top-down fashion (first file loads first, etc.)
 
I did a test with 3 XML-mods A/B/C setting the Settler move rate on a different value.
The result is that the installation time of the civ5mod files is of importance. The last installed mod is the winner.
Changing the file date of the single XML files didn't make a difference.

No matter in which order I activated the mods, the C mod’s value was used because I installed it at last. A was used when I installed that at last.

In case you have several civ5mod files ready for installation, alphabetic order of the mod’s name is used for installation order.
I compiled the three A/B/C mods in reverse order, copied the files into the MODS folder in reverse order and value of C was used after multi-installation. Renaming the civ5mod files themselves has no effect, the stored mod name is used.

Let’s summarize for mods using XML files:

- The last installed modification will be handled last, possibly overwriting older mods
- Activation time doesn’t matter (however mods using only installation-scripts should work properly according to activation sequence)
- Compiling time doesn't matter
- Alphabetical order of mod’s name is used if you install several civ5mod files in the MODS folder at same time, so the Zeta Mod will rule over Alpha Mod
 
Mod authors will have some control over this if and when they actually make mod relationships work.
 
well thanks for testing that Mentos, and I think Gazebo is right on #1, but I haven't tested it.
 
I did a test with 3 mini-mods A/B/C setting the Settler move rate on a different value.
The result is that the installation time of the civ5mod files is of importance. The last installed mod is the winner.
Changing the file date of the single XML files didn't make a difference.

No matter in which order I activated the mods, the C mod’s value was used because I installed it at last. A was used when I installed that at last.

In case you have several civ5mod files ready for installation, alphabetic order of the mod’s name is used for installation order.
I compiled the three A/B/C mods in reverse order, copied the files into the MODS folder in reverse order and value of C was used after multi-installation. Renaming the civ5mod files themselves has no effect, the stored mod name is used.

Let’s summarize:

- The last installed modification will be handled last, possibly overwriting older mods
- Activation time doesn’t matter
- Compiling time doesn't matter
- Alphabetical order of mod’s name is used if you install several civ5mod files in the MODS folder at same time, so the Zeta Mod will rule over Alpha Mod

interesting tests... did the order change if you delete the cache folder ?
 
No matter in which order I activated the mods, the C mod’s value was used because I installed it at last. A was used when I installed that at last.

I've done a few test again, as I had the same feeling as gazebo, and I confirm that in my case, the activation order is the key (testing with City States mod for YnAEMP).
 
Oh, didn't see there is a cache folder. No, I haven't deleted that one; only deleted all mods after each test.
I've done the test only with XML files where installation order was important.
I guess it behaves correctly according to proper activation sequence if only installation-scripts are used.

I recommend to install and activate one mod after each other then if someone isn't sure if more than one mod changes the same thing. The mod with the most desired effect should be installed and activated at last then.
 
Back
Top Bottom