Is it possible to implement gold cost for units...

Aceman101

Emperor
Joined
Dec 25, 2006
Messages
1,522
So is it possible to implement a gold cost for a unit on completion of production? (Or pre-production?) This is not to replace shields but as an additional cost for units/improvements. For example, on completion of building a warrior, the civ must pay 5 or 10 gold as a lump sum. If the civ does not have 5 or 10 gold on completion of the unit then production is canceled, or at least put on hold. I've thought of such an idea but can't find a way to implement it, at least not in the standard civ3 editor.

I'm quite certain this isn't possible but just wanted to make sure. I apologize if this is a silly question, I pretty much have no idea how to mod other than simple tweaks :). I wanted to incorporate this idea in my "mod" but if I can't then I'll just leave it be and use some other ideas that so far work. I could post this mod but it's pretty much just basic amateur editing to try and make a more "realistic" civ game. I might however post some more questions/concepts in this thread when I think of them...
 
No, unfortunately you cannot.

Although one option you might think of is having the buildable unit be completely useless, ie. 0/0 and immoble, and having it upgrade to an actual unit which is also a king unit, meaning it cannot be built directly, thus forcing the payment of the upgrade cost.

I don't know if that would work for you, or if it might cause the AI to go crazy, as the idea just came to me while I was reading your post and have not tested it, but anyways it might be a solution.
 
You can also make this useless unit built via autoproduction from a building, and then make it upgrade to the real unit.
This way, you can control the cost of the "upgrade", AND also have a variable maintenance cost for the building (so a tank factory could be a lot more expensive than an infantry barrack).
 
Hi all, thanks for your input. I like the idea of these useless units being upgraded into king units. But I have some questions:

1) I suppose it would be a setback for the AI to do this? They don't seem to have much gold in their coffers and so would be unable to upgrade until they get enough gold. This could take a long time, especially for better units. At least that's my experience from a Monarch AI. The AI seems to be a bottleneck for a lot of new ideas :(

2) A potential problem could be that when an AI builds a unit, it can't upgrade the useless unit as it has no barracks/harbour/airport and would have to wait until it produces such a building to upgrade the units. Probably it could be solved by the useless units not requiring such buildings to upgrade...

Also, I ran into a slight problem when testing my mod. Two civs, Inca and India have the exact some shade of purple, and when looking into the histograph, they're directly next to each other so it just looks like one huge purple civ. But I can't remember touching civ colours? I never saw such a problem in a regular civ game, but maybe its a bug when Inca and India are on the map? Probably something in my mod, I'll have to check.

Edit: I just checked and the colours are unchanged India used that particular shade of purple as it's default colour (and a grey colour as its alternative) and Inca uses it as an alternative, with pink being its default. Hmm that is strange.
 
1) Since the cost to upgrade is the difference between the cost to build the useless and actual units, you can just make the difference whatever you think is enough to implement the "gold cost" you wanted in the opening post, but small enough not to hinder the AI too much. You can even make the useless unit more costly than the king unit if you want the cost to be 0 (but then I don't see what would be the point of it in your case).

2) It works well when you create the useless unit via auto production from a building, just give the produce veteran flag to the said building.
 
1) Yes, but my original idea was to make the units get more expensive as they advance into the ages. I'll have to make a compromise on that.

2) That's true. Sound like an interesting idea, I'll be sure to try it out soon.

I'll test this a bit more in the editor and see if I can get it working well enough for game-play
 
You can have the AI accumulate more gold in its coffers by reducing the max research to 70 or so, as the reason that the AI never has gold is because it is all spent on research.
 
^ This is actually an excellent idea, thanks. Presumably this could be done in the standard civ 3 editor? Also, if the AI can't have 100% science research won't it just spend the rest on entertainment?

One more question (yes too many) is there a way to make upgrades a lesser priority than new units? Because once upgrade time comes then there might not be too much gold left for the AI's to build new units with.

Thanks everyone for your input.
 
You can change the research limit for indivdual governments, you have to do them individually.
 
This isn't really what you want but I'll just mention it as it's kind of related.

You can make it so units and buildings ONLY cost gold to produce. This can be done by making all terrain produce no shields. In this case units and buildings can be obtained only by using the rush option which can be set in the govts tab to gold (or population). The amount of gold it costs to build the unit or building will depend on the sheild cost set in the editor. So the end effect is that you can build anything in one turn by rushing it if you have enough gold.

Probably not what you want though, and I'm not sure if the AI can use it.
 
This isn't really what you want but I'll just mention it as it's kind of related.

You can make it so units and buildings ONLY cost gold to produce. This can be done by making all terrain produce no shields. In this case units and buildings can be obtained only by using the rush option which can be set in the govts tab to gold (or population). The amount of gold it costs to build the unit or building will depend on the sheild cost set in the editor. So the end effect is that you can build anything in one turn by rushing it if you have enough gold.

Probably not what you want though, and I'm not sure if the AI can use it.

What an interesting idea! :lol: Although I assume the game forces a shield in the city center square (not sure), that would be quite interesting to see something like that working.
 
Hi nick,

All ideas are welcome, thanks for posting. Although I have to admit this idea isn't new to me; there was a thread in the GD section about gold cost for units without shields like you had it in mind, which then prompted me to make a thread here about a different variation of that.

Unfortunately I think the OP was having trouble with this idea as I think as tom pointed out the city center produces 1 shield which is hard-coded (?) into the game. This then causes the AI to build units normally (with shield) albeit at a much slower rate. I have not tried it out but apparently the AI does use the rush feature more during war time. I'm not sure of this can be remedied but good idea anyways. :)
 
Bugger. I tested it a bit but hadn't got round to removing shields from terrian yet. Was just assuming it was possible to make production zero in all cities. I hadn't realised that the city centre automatically has 1 shield. Now that you and Tom mention it though it sounds right. I guess if the shield cost is high enough units and buildings will be practically speaking unbuildable though it kind of ruins the effect somewhat.

I'm working on a mod where everything was supposed to be bought with gold in this manner so I hope a way can be found to remove or neutralise that centre shield.
 
You're right that (especially later in the game) units and buildings will become impractical to build with such a low spt rate, and a human would then normally use the rush option as intended. However the AI is not smart enough to realise this and will build whatever it can this way, even if it does take hundreds of turns. It might be possible to somehow make them rush-build or at least give them incentives to do so, but I wouldn't know.

I too hope the city center shield can be removed, but I don't think it can be done by any practical way...

Edit: Also, even if the center shield were to be removed, I don't think the AI would react by suddenly building everything with gold. I think they'd just end up not building anything without a "hack" of some sort. Anyway that's just my theory, could be wrong of course.
 
You're right that (especially later in the game) units and buildings will become impractical to build with such a low spt rate, and a human would then normally use the rush option as intended. However the AI is not smart enough to realise this and will build whatever it can this way, even if it does take hundreds of turns. It might be possible to somehow make them rush-build or at least give them incentives to do so, but I wouldn't know.

I too hope the city center shield can be removed, but I don't think it can be done by any practical way...

Edit: Also, even if the center shield were to be removed, I don't think the AI would react by suddenly building everything with gold. I think they'd just end up not building anything without a "hack" of some sort. Anyway that's just my theory, could be wrong of course.

Yeah your probably right about the AI not using it. Luckily though I actually only need it for human use. In the scenario I'm planning the AI willl get all it's units from auto-production. I think this can be used but not really for a general epic game but maybe for specific scenarios.
 
Top Bottom