There are alot of mod out there for civ4, and his post is both for Mod-makers and Mod-users alike, laying out the most basic information about setting up a mod the right way.
Please note that this post has been re-written more intelligibly than its original form.
The WRONG Way:: Do not ever modify the original files!
Replacing your original files. Under no circumstances should a mod require you to replace or overwrite your original game files. There simply is no reason to, civ4 and all it's expansions allow very simple and effective ways to load customization items while leaving all the original files unaltered. The one exception I can think of is Blue Marble, but that mod has been around for years, and it makes very specific and minor alterations to some textures.
The RIGHT way:
There are two ways to add customized content. One is to create or install a proper mod, the other is to put the modifications in Custom Assets.
Making a proper mod:
Mods go in the mod's directory, which is generally along the .../$Program Files/Firaxis/Sid Meier's Civilization 4/Beyond the Sword/ path (obviously no BtS if you're installing into Vanilla, and it's a Warlords folder for Warlords). When you install a mod the path to the mod should look something like this (the exact $Installpath is different, but for most users it's along $ProgramFiles, there is also a similar mods directory along $MyDocuments/$MyGames, but it's buggy, so it's not recommended to use it):
$InstallPath/Beyond the Sword/Mods/$ModName
Each Mod should get its OWN folder, and should contain copies of the files it overrides. If you have a mod you enjoy and want to launch it automatically, copy your BtS shortcut on your desktop or start menu, then name the copy shortcut the name of the mod, and right click on it and select properties. In the target line add mod="ModName" to the end of the path, as an example this is what the Legends of Revolution installer created shortcut target looks like on my computer: "C:\Program Files\Firaxis Games\Sid Meier's Civilization 4\Beyond the Sword\Civ4BeyondSword.exe" mod="LoR"
This method prevents you from having to worry about backing up your files, and is the way the Firaxians wanted us to do things. Mods that request you to back up your originals because they are being overwritten, are doing things the wrong way; you should not install them, or create them, and especially don't release them.
Custom Assets:
Custom assets modding will work, and it wol't mess up your original game, but for the most part it's not recommended. This is because custom assets are loaded first before anything else, so the can cause conflicts with some mods. If you release a mod, you definitely should not have it install to custom assets (the exception being the BUG mod). The nice thing about custom assets is that they are loaded automatically, so many modders start out using custom assets, but in the long run it can be a hassle. To use custom assets simply find the file you want to alter, and copy it into the custom assets folder; ensure you maintain the same basic file structure as Civ4 does. For instance if tweaking Unit values with custom assets, copy your CIV4UnitInfos.xml from $ProgramFiles/../BtS/Assets/XML/Units to $MyGames/BtS/Custom Assets/XML/Units, then make the changes to the file in your custom assets folder.
The Cache
Please note that Civ4 keeps a cache. For the most part the cache will not break properly created BtS mods, but it may, and it's known to cause many conflicts with Pre BtS mods and custom assets. The cache is a backup of many files, to enable Civ4 to load frequently-used (or particularly large) files faster -- the cache is a compressed version of the file re-written to be more easily machine readable. Why is this important? The game loads the cache first -- if a file is in the cache, it will NOT reload it if it was modified. How do you get around it? clear the cache! Simply hold down shift while starting up Civ4. Also you may manually delete the cache file by browsing to this directory:
$UserName\Application Data\My Games\Sid Meier's Civilization 4\cache
You can also disable caching in the main Civ4 Config file. The civ4 config file will be found in the main folder where custom assets is, and there is also a link to it from the main BtS installation folder. The name of the file is: CivilizationIV.ini
There are some usefull items you may want to change in the config file:
Thank you all, and Happy Modding!
Moderator Action: Updated with content supplied by phungus420 - thanks for your help.
Please note that this post has been re-written more intelligibly than its original form.
The WRONG Way:: Do not ever modify the original files!
Replacing your original files. Under no circumstances should a mod require you to replace or overwrite your original game files. There simply is no reason to, civ4 and all it's expansions allow very simple and effective ways to load customization items while leaving all the original files unaltered. The one exception I can think of is Blue Marble, but that mod has been around for years, and it makes very specific and minor alterations to some textures.
The RIGHT way:
There are two ways to add customized content. One is to create or install a proper mod, the other is to put the modifications in Custom Assets.
Making a proper mod:
Mods go in the mod's directory, which is generally along the .../$Program Files/Firaxis/Sid Meier's Civilization 4/Beyond the Sword/ path (obviously no BtS if you're installing into Vanilla, and it's a Warlords folder for Warlords). When you install a mod the path to the mod should look something like this (the exact $Installpath is different, but for most users it's along $ProgramFiles, there is also a similar mods directory along $MyDocuments/$MyGames, but it's buggy, so it's not recommended to use it):
$InstallPath/Beyond the Sword/Mods/$ModName
Each Mod should get its OWN folder, and should contain copies of the files it overrides. If you have a mod you enjoy and want to launch it automatically, copy your BtS shortcut on your desktop or start menu, then name the copy shortcut the name of the mod, and right click on it and select properties. In the target line add mod="ModName" to the end of the path, as an example this is what the Legends of Revolution installer created shortcut target looks like on my computer: "C:\Program Files\Firaxis Games\Sid Meier's Civilization 4\Beyond the Sword\Civ4BeyondSword.exe" mod="LoR"
This method prevents you from having to worry about backing up your files, and is the way the Firaxians wanted us to do things. Mods that request you to back up your originals because they are being overwritten, are doing things the wrong way; you should not install them, or create them, and especially don't release them.
Custom Assets:
Custom assets modding will work, and it wol't mess up your original game, but for the most part it's not recommended. This is because custom assets are loaded first before anything else, so the can cause conflicts with some mods. If you release a mod, you definitely should not have it install to custom assets (the exception being the BUG mod). The nice thing about custom assets is that they are loaded automatically, so many modders start out using custom assets, but in the long run it can be a hassle. To use custom assets simply find the file you want to alter, and copy it into the custom assets folder; ensure you maintain the same basic file structure as Civ4 does. For instance if tweaking Unit values with custom assets, copy your CIV4UnitInfos.xml from $ProgramFiles/../BtS/Assets/XML/Units to $MyGames/BtS/Custom Assets/XML/Units, then make the changes to the file in your custom assets folder.
The Cache
Please note that Civ4 keeps a cache. For the most part the cache will not break properly created BtS mods, but it may, and it's known to cause many conflicts with Pre BtS mods and custom assets. The cache is a backup of many files, to enable Civ4 to load frequently-used (or particularly large) files faster -- the cache is a compressed version of the file re-written to be more easily machine readable. Why is this important? The game loads the cache first -- if a file is in the cache, it will NOT reload it if it was modified. How do you get around it? clear the cache! Simply hold down shift while starting up Civ4. Also you may manually delete the cache file by browsing to this directory:
$UserName\Application Data\My Games\Sid Meier's Civilization 4\cache
You can also disable caching in the main Civ4 Config file. The civ4 config file will be found in the main folder where custom assets is, and there is also a link to it from the main BtS installation folder. The name of the file is: CivilizationIV.ini
There are some usefull items you may want to change in the config file:
Spoiler :
Toggles the game into windowed mode if set to zero, to easily tab out of the game.
Setting to 0 will give debugging statements about python going wrong. You should probably only turn these on if you know what python is.
Pretty self explanitory:
Also self explanitory, if you're using mods or doing alot of modding you should definatly set these to 1 to disable them:
Debugging mode, change the "0" to "chiptole" as shown below. Very useful, it opens up quite a few tools. For instance pressing ctrl + z reveals the map. In all RevDCM based mods pressing ctrl + shift + X starts AI Autoplay, and ctrl + shift + l will allow you to switch players.
Pretty self explanitory, but you need to have some idea of what you're doing in order to make sense of the logs:
Code:
; Specify whether to play in fullscreen mode 0/1/ask
FullScreen = 0
Code:
; Set to 1 for no python exception popups
HidePythonExceptions = 0
Code:
; The maximum number of autosaves kept in the directory before being deleted.
MaxAutoSaves = 5
; Specify the number of turns between autoSaves. 0 means no autosave.
AutoSaveInterval = 4
Code:
; Disable caching of file system (may slow initialization)
DisableFileCaching = 1
; Disable caching of xml and file system (may slow initialization)
DisableCaching = 1
Code:
; Move along
CheatCode = chipotle
Code:
; Create a dump file if the application crashes
GenerateCrashDumps = 1
; Enable the logging system
LoggingEnabled = 1
Thank you all, and Happy Modding!
Moderator Action: Updated with content supplied by phungus420 - thanks for your help.