WoC is a way of writing XML for Civ IV.
Background
Originally the XML had to be in what we call the core files which makes it difficult for more that one modder to work on a mod. Modules were introduced. In the module you had to have the whole object and it replaced base object defined in the core files.
This does not support optional content nor does it allow two options to be on at the same time. It may require players to physically move modules in and out of their mod.
Basics of how it works
WoC works similar to the industry standard mechanism for updating a master file. In this case the Master is the core files and the transactions are the modules. This makes life easier for the modder because they only need the object key and the values they want changed in their module. It also enables to different modules to work on different parts of the same object and have their changes combined.
(Note: It is possible with this method that the Master record is in one of the modules with transactions to it in other modules. IE Just like any other update mechanism.)
There are two "bugs" or "design features" that cause some confusion to modders using WoC
- you can't set a value back to it's default value
- group elements add to the group they don't replace it.
The way WoC gets around this is with the bForceOverwrite tag set to 1. With this you replace the current core with what is in this definition.
With all these transactions it becomes important to have away of ordering them and turning on or off optional components. This is where the
Modular Loading Controls, or MLF comes in. These files, one in each folder, indicate which module (sub folder) to load in which order. You can set up a number of different orders to suit your needs and switch between them. This allows players to edit a small number of files rather than move files. (Note: C2C does not use the MLF ability of different load sets well if at all.)
In addition WoC allows you to turn off content in one module depending on the existence of game objects making it possible to keep things working across modules. This is done using the
AndDependencyTypes tags. All the objects in this list must exist for this transaction to be processed.
Rise of Mankind/A New Dawn extensions
RoM/AND extended WoC slightly by adding adding Game Option tags which turn objects on and off depending on options set in the Custom Game screen.