How do you change the production cost of a building/unit?

bb82

Chieftain
Joined
Apr 25, 2009
Messages
5
I'd like to change the production cost/shields of units and buildings. I'd like to play a marathon type game, but keep many buildings and units at a lesser cost. Meaning, I like the high research times and turns, but I want to be able to enjoy certain types of units for a longer period of time. So I dont want their production cost to increase, just because I want a longer game.

What's the easiest way to change the costs? What file, formula, etc.?
 
If you do not want to change all units: Units\Civ4UnitInfos.xml, search for iCost.

For all units: Civ4GameInfo\Civ4GameSpeedInfo.xml,
PHP:
<iTrainPercent>200</iTrainPercent>
			<iConstructPercent>300</iConstructPercent>
			<iCreatePercent>300</iCreatePercent>

these values.


And welcome to CFC :).
 
Thanks for the help.

Any chance I can get more info about how to do this and what those values are, based on what I actually want to do?

Let me be more specific, I want to make unit/building costs/shields the same values that they are in a normal game, even though i'm in a marathon game. Except settlers. I actually want to increase their cost in a marathon game by about 50%.
 
In that case..

In the copies of the files in your mod folder... (NOT the originals)

In Civ4GameSpeedInfo.xml, set all three of the values that The_J listed to 100 - they say "Set this to cost to 100% (or whatever the value is) of the normal cost"
iTrain = unit costs
iConstruct = building costs
iCreate = research costs

Then in Civ4UnitInfos.xml, increase the value for the settler's iCost entry to whatever you want it to cost.
 
If I did all of that:

Would it affect the current game i'm in?

Or when I start my next BTS game, with marathon selected, it would be how I want it?


Thanks again.
 
In that case..

In the copies of the files in your mod folder... (NOT the originals)

In Civ4GameSpeedInfo.xml, set all three of the values that The_J listed to 100 - they say "Set this to cost to 100% (or whatever the value is) of the normal cost"
iTrain = unit costs
iConstruct = building costs
iCreate = research costs

Then in Civ4UnitInfos.xml, increase the value for the settler's iCost entry to whatever you want it to cost.


I'm pretty confused. Why the mod folder? I want to do this for games in CivIV bts. So wouldn't I be looking in the assets folder for bts? Wouldn't the mod folder affect the mod/senerio games?

Aslo, when I found the file, how do I edit it? Seems I can't even open it. Do I need a special tool to edit it and save it? Do I have to recompile it or just edit it and save the file? Will any text editor work, notepad even?
 
I think I was able to figure it out. I changed the following to 100 and my current game reflected this, as soon as I reloaded BTS. But I noticed that the settlers value stayed the same. Shouldn't it's value also change? It stayed at 300 shields, when the normal value is 100 shields. Do I manually have to do settlers?

iTrain = unit costs
iConstruct = building costs
 
You can open the XML files with Notepad, just right-click and select "open with" and then choose Notepad or any other text editor (Not Word, it's not text editor).

You should really make a mod folder and put your modded files there or put the files in the <My Documents>\My Games\Civilization\CustomAssets, which will override the standard files.

If you make changes directly to BtS, you might break something. Making a mini-mod would spare you a lot of potential problems.

I think the settler cost varies depending on the gamespeed. But in CIV4UnitInfos.xml, you can edit the iCost tag for the settler.
 
I'm pretty confused. Why the mod folder? I want to do this for games in CivIV bts. So wouldn't I be looking in the assets folder for bts? Wouldn't the mod folder affect the mod/senerio games?

Aslo, when I found the file, how do I edit it? Seems I can't even open it. Do I need a special tool to edit it and save it? Do I have to recompile it or just edit it and save the file? Will any text editor work, notepad even?

The reason to do it in a Mod is so that you always have the original files around - this can be impotant if you ever screw something up.

Go to your BTS mods folder, create a new folder inside it. Copy the desired files to subfolders named just like they are in the Assests folder. Change those copies.

And yes, any text editor will do.
 
Back
Top Bottom