January 25, 2004, 22:23
|
#1
|
Firaxis Games Software Engineer
Local Time: 13:04
Local Date: November 2, 2010
Join Date: Mar 1998
Posts: 5,360
|
Everything about Corruption: C3C edition
This is a guide about how corruption works in Conquests. It's slightly different than how it used to work in PTW and vanilla Civ3.
The information that follows was discovered by extensive testing and contributions by numerous members of the Civ3 community, including Aeson, DaviddesJ, Nor Me, and Qitai. We also recently got some inside information (a look at some of the actual corruption code), which helped find the last few missing pieces of the corruption puzzle.
DEFINITIONS
Corruption in Civilization 3 is commerce from city tiles that cannot be used by the empire. Corrupted commerce is indicated graphically in the city screen by stacks of red coins. There are numerous factors that influence corruption, all of which are addressed in this article.
Waste is the loss of production as opposed to commerce, and is governed by almost the same rules as corruption. Everything in this article that applies to corruption, also applies to waste, unless otherwise mentioned.
CORRUPTION BASICS
The total corruption in each city is equal to the sum of two independent components: distance corruption, and rank corruption.
For non-communal government types, distance corruption depends on the distance of each city from its closest palace. Rank corruption in a city depends on how many other cities are closer than that city to the palace.
For communal government types, distance corruption does not actually depend on distance. Each city is considered to be the same distance from the Palace. Rank corruption depends on the total number of cities in the empire.
You can reduce corruption in your cities by building appropriate city improvements and Wonders, changing to a more efficient government, choosing a Commercial civilization, and connecting your cities to the trade network of your empire. In addition, you can reduce waste by bringing your cities into a WLTKD celebration.
You can determine the total number of ‘red’ commerce in a city by multiplying its total corruption by the number of raw commerce produced by citizens working the land, rounded to the closest integer.
DISTANCE CORRUPTION
For all non-communal government types, the distance corruption component is proportional to the distance of a given city from its closest Palace. For communal governments, the distance to the closest Palace is considered to be the same for all cities on a given map. The “closest palace” to a city can be the Palace, the Forbidden Palace, or any other Wonder with the “reduces corruption” ability.
For corruption purposes, distance is always an integer number, and is given by:
Code:
|
d = max(x,y) + min(x,y)/2
where
max(x,y) denotes the maximum between x and y,
min(x,y) denotes the minimum between x and y,
x is the distance in the NW/SE direction,
y is the distance in the NE/SW direction,
and the integer division is rounded down. |
In the special case of communal governments, the distance for all cities is taken as:
where MaxD = (MapW+MapH)/4, MapW is the width of the map, and MapH is the height of the map, as given in the editor.
The distance, d, is used to get the adjusted distance, da, as follows:
Code:
|
da = 0.5^Ni * min(Gd * t * d, MaxD)
where
Ni is the number of anti-corruption buildings,
t = 1 if the city is on the trade network
5/4 otherwise
Gd = 3/2 for Rampant corruption (Despotism)
3/4 for Minimal corruption (Democracy)
1 otherwise |
For waste calculations only, when the city is in a WLTKD celebration, divide da by 2.
So each anti-corruption building, which is a city improvement with the “reduces corruption” ability in the editor (Courthouse and Police Station), divides distance corruption by 2.
Finally, the exact value of the distance corruption component is given by:
RANK CORRUPTION
The rank corruption component depends on the rank (R) and optimal city number (Nopt) of each city.
In a non-communal type of government all cities of an empire are ranked in order of distance to the capital, starting at zero for the capital itself. If several cities have the same distance to the capital, they are ranked in order of founding, and if they also have the same date of founding, they are ranked by their order in the database. In a communal form of government, all cities have the same rank, which is half the total number of cities in the empire, rounded down.
Each city also has its own optimal city number, Nopt, given by:
Code:
|
Nopt = max(OCN * (L/100 * (1 + c + Gr + Gp*Nwe) + 0.25*Ni), 1)
where
OCN is the optimal number of cities for the map size,
as found in the editor
L is the percentage of optimal cities for the current
difficulty level, as given in the editor
Nwe is the number of active Wonders in the empire with
the “reduces corruption” ability
(Forbidden Palace, SPHQ)
c = 0.25 for a commercial civilization,
0 otherwise
Gr = 0.1 for minimal or nuisance corruption
2 for communal corruption
0 otherwise
Gp = 3/8 non-communal corruption
3 for communal corruption |
For waste calculations only, when the city is in a WLTKD celebration, add OCN/4 to Nopt.
The rank corruption for a city is then given by:
Code:
|
Cr = R / (2 * Nopt), if R < Nopt
(2 * R – Nopt) / (2 * Nopt) otherwise |
MAXIMUM CORRUPTION
The sum of the distance and rank components of corruption can be greater than 100%. The game sets an upper limit for the total corruption in a city to be equal to 90% minus 10% for each city improvement and minus 70% for each Wonder in the city with the “reduces corruption” ability:
Code:
|
Cmax = max(0.9 – (0.1 * Ni + 0.7 * Nwc), 0) |
POLICEMAN SPECIALISTS
By assigning one of your citizens to be a policeman, you can cause one corrupted commerce and one wasted shield to become uncorrupted. This reduction in corruption comes before applying the maximum corruption limit described in the previous section, so the city may not show any reduction if was already taking advantage of that limit.
SUMMARY
To summarize the above, distance corruption depends on the distance of the city from the closest palace (or a constant number for communal governments), multiplied by a factor that depends on the government type, and another factor if the city is not connected to your capital by road, harbor, or airport. Each corruption-reducing building in the city halves distance corruption.
Rank corruption depends on the ratio of the city rank to the adjusted optimal city number. The city rank is equal to the number of cities closer to the capital (or half the total number of cities for Communism). The rate of increase of this corruption with rank doubles after rank exceeds the optimal city number. The optimal city number of the map gets modified by the difficulty level, the commercial trait, the current government, and the number of improvements and Wonders with the “reduces corruption” ability.
Courthouses and Police Stations decrease distance corruption and increase the optimal number of cities. They also each decrease the maximum corruption limit.
The Forbidden Palace acts as a second Palace for distance corruption calculations, but not for rank calculations. The Forbidden Palace itself will have low corruption, but if there are many cities closer to the Palace than the Forbidden Palace, the cities around the Forbidden Palace will have high rank corruption. However, even though it doesn’t provide a new set of city ranks, the Forbidden Palace reduces rank corruption throughout the empire by increasing the optimal number of cities.
Last edited by alexman; May 18, 2004 at 09:21.
|
|
|
|
January 25, 2004, 22:36
|
#2
|
Deity
Local Time: 13:04
Local Date: November 2, 2010
Join Date: Nov 2001
Location: Oviedo, Fl
Posts: 14,103
|
Thanks for the report alexman. More fine work.
|
|
|
|
January 25, 2004, 23:17
|
#3
|
Emperor
Local Time: 12:04
Local Date: November 2, 2010
Join Date: May 2001
Location: flying too low to the ground
Posts: 4,625
|
i second the kudos. i now completely understand why i can't build anything in half of my empire.
i will not go about demanding the cost of a palace be lowered significantly.
__________________
"I've lived too long with pain. I won't know who I am without it. We have to leave this place, I am almost happy here."
- Ender, from Ender's Game by Orson Scott Card
|
|
|
|
January 26, 2004, 05:12
|
#4
|
Prince
Local Time: 19:04
Local Date: November 2, 2010
Join Date: Jun 2002
Location: Sweden
Posts: 635
|
thanks Alexman, It all seems so easy now
__________________
You saw what you wanted
You took what you saw
We know how you did it
Your method equals wipe out
|
|
|
|
January 26, 2004, 09:35
|
#5
|
Prince
Local Time: 12:04
Local Date: November 2, 2010
Join Date: Dec 1969
Location: London, Ontario, Canada
Posts: 657
|
Great work!
|
|
|
|
January 26, 2004, 10:50
|
#6
|
Emperor
Local Time: 12:04
Local Date: November 2, 2010
Join Date: Mar 2002
Location: listening too long to one song
Posts: 7,395
|
This is great alexman.
One question, is this how its going to remain throughout the rest of the patching process?
|
|
|
|
January 26, 2004, 11:45
|
#7
|
Emperor
Local Time: 13:04
Local Date: November 2, 2010
Join Date: Apr 2002
Location: pittsburgh
Posts: 4,132
|
Thanks for the clear exposition. I now think I understand this for the moment. Of course, that will change and my understanding will decline as the distance from this thread increases.
__________________
Illegitimi Non Carborundum
|
|
|
|
January 26, 2004, 11:49
|
#8
|
Prince
Local Time: 10:04
Local Date: November 2, 2010
Join Date: Mar 2002
Location: Sunny Southern California
Posts: 900
|
A helpful well painted picture. I may actually have a clear grasp on this issue, for perhaps the first time.
__________________
"Guess what? I got a fever! And the only prescription is ... more cow bell!"
|
|
|
|
January 26, 2004, 11:55
|
#9
|
Deity
Local Time: 13:04
Local Date: November 2, 2010
Join Date: Feb 2001
Posts: 21,822
|
Effective corruption (by which I mean that actual number of shields/commerce lost) should be capped at something like 60%
__________________
[Obama] is either a troll or has no ****ing clue how government works - GePap
Later amendments to the Constitution don't supersede earlier amendments - GePap
|
|
|
|
January 26, 2004, 13:37
|
#10
|
Prince
Local Time: 17:04
Local Date: November 2, 2010
Join Date: Dec 2000
Posts: 525
|
Quote:
|
Originally posted by jshelr
Thanks for the clear exposition. I now think I understand this for the moment. Of course, that will change and my understanding will decline as the distance from this thread increases.
|
|
|
|
|
January 26, 2004, 13:46
|
#11
|
Prince
Local Time: 12:04
Local Date: November 2, 2010
Join Date: Apr 2002
Location: Waterloo, Ontario
Posts: 687
|
Nice work . I assume the SPHQ works the same as the FP, in that it lowers the distance constant for Communal gov'nts, as well as raising the OCN?
__________________
I AM.CHRISTIAN
|
|
|
|
January 26, 2004, 13:52
|
#12
|
Firaxis Games Software Engineer
Local Time: 13:04
Local Date: November 2, 2010
Join Date: Mar 1998
Posts: 5,360
|
In Communism the distance constant does not depend on the presence of a FP or a SPHQ. It's always MaxD/4.
So, yes, the SPHQ works like the FP, but no, it doesn't affect distance corruption, just like the FP doesn't. It affects only the rank corruption.
If the SPHQ worked outside Communism, however, it would affect distance corruption.
|
|
|
|
January 26, 2004, 14:03
|
#13
|
Prince
Local Time: 12:04
Local Date: November 2, 2010
Join Date: Apr 2002
Location: Waterloo, Ontario
Posts: 687
|
OK...so it just lowers the OCN?
And in that case, it really doesn't matter one bit where you build your FP or SPHQ in communism, right?
__________________
I AM.CHRISTIAN
|
|
|
|
January 26, 2004, 14:06
|
#14
|
Firaxis Games Software Engineer
Local Time: 13:04
Local Date: November 2, 2010
Join Date: Mar 1998
Posts: 5,360
|
It just raises the OCN, yes.
And you are right that it doesn't matter where you build the FP and SPHQ in Communism, except that the cities with these Wonders have very low corruption, so you usually want them to be high-population/high-production cities.
|
|
|
|
January 26, 2004, 14:53
|
#15
|
Emperor
Local Time: 12:04
Local Date: November 2, 2010
Join Date: Mar 2002
Location: listening too long to one song
Posts: 7,395
|
Alexman, in case you missed my earlier question, do you know if this is how corruption will remain throughout the rest of the patching process?
|
|
|
|
January 26, 2004, 14:56
|
#16
|
Firaxis Games Software Engineer
Local Time: 13:04
Local Date: November 2, 2010
Join Date: Mar 1998
Posts: 5,360
|
Sorry, no I don't know.
I suspect that it will remain the same, because this was the intended corruption model, even in vanilla Civ3.
|
|
|
|
January 26, 2004, 14:59
|
#17
|
Emperor
Local Time: 12:04
Local Date: November 2, 2010
Join Date: Mar 2002
Location: listening too long to one song
Posts: 7,395
|
Quote:
|
Originally posted by alexman
Sorry, no I don't know.
I suspect that it will remain the same, because this was the intended corruption model, even in vanilla Civ3.
|
I figured that, I was just curious if you knew which way the wind was blowing....
thanks for all the good work
|
|
|
|
January 26, 2004, 16:27
|
#18
|
Deity
Local Time: 13:04
Local Date: November 2, 2010
Join Date: Jul 2001
Location: Kneel before Grog!
Posts: 17,978
|
Thanks, alexman, for laying out the nuts 'n bolts of corruption in Conquests 1.15.
I'm still trying to get a feel for FP placement, though.
I started a new game on thursday of last week, because I had finally downloaded and applied the patch, but the AU game wasn't posted yet. I have gotten some MGLs, one of which I used to rush a FP. If I post the game, will those of you (such as alexman) who seem to grasp the corruption system a bit better than I do check it out and give their thoughts on my placement?
-Arrian
__________________
grog want tank...Grog Want Tank... GROG WANT TANK!
The trick isn't to break some eggs to make an omelette, it's convincing the eggs to break themselves in order to aspire to omelettehood.
|
|
|
|
January 26, 2004, 16:39
|
#19
|
Firaxis Games Software Engineer
Local Time: 13:04
Local Date: November 2, 2010
Join Date: Mar 1998
Posts: 5,360
|
Sure!
|
|
|
|
January 26, 2004, 17:27
|
#20
|
Deity
Local Time: 13:04
Local Date: November 2, 2010
Join Date: Jul 2001
Location: Kneel before Grog!
Posts: 17,978
|
Sweet. Will do when I get home (~3 hours, blah, grocery shopping to do).
By the way, kudos to the AI in this particular game. I went looking for a pump start spot (playing as Iroquois) because I wanted a strong game w/a FP to try and work on the placement. Hence the start I got... it took me a few restarts to get it. Once I got a pump-capable start spot, it turned out to be just awesome. When it rains, it pours, and when the sun shines, you get skin cancer. Or something like that. Anyway, my REXmania was interrupted not once but twice by Russian sneak attacks, each of which cost me a border town (they took out one, I abandoned the other and retreated to fight them off closer to my core). They were a major pain in the ass until I unloaded on them with swords, MWs, and ancient cavalry (I got Zeus, but fairly late, because it took forever to connect my ivory). Granted, the first sneak attack was just a couple of warriors, but it was justified, since all I had to counter it was a couple of warriors. They got a little lucky (took out fortified reg warrior on hill with vet warrior) and it cost me a town. The second attack was more serious - about 5 archers and a warrior or two. I fought it off with a couple of spears, several warriors (vets now, as I was preparing for sword upgrade) and an archer or two. I won, but kudos to the AI for hitting me when I was running almost zero military and REXing like a madman. It did hurt me, and annoyed the hell out of me.
-Arrian
__________________
grog want tank...Grog Want Tank... GROG WANT TANK!
The trick isn't to break some eggs to make an omelette, it's convincing the eggs to break themselves in order to aspire to omelettehood.
|
|
|
|
January 26, 2004, 20:13
|
#21
|
Deity
Local Time: 13:04
Local Date: November 2, 2010
Join Date: Jul 2001
Location: Kneel before Grog!
Posts: 17,978
|
Ok, here is the save...
The FP is in the south, in the city built on the ruins of Moscow.
-Arrian
__________________
grog want tank...Grog Want Tank... GROG WANT TANK!
The trick isn't to break some eggs to make an omelette, it's convincing the eggs to break themselves in order to aspire to omelettehood.
|
|
|
|
January 26, 2004, 20:52
|
#22
|
Deity
Local Time: 13:04
Local Date: November 2, 2010
Join Date: Jul 2001
Location: Kneel before Grog!
Posts: 17,978
|
By the way, I know I need some galleys, especially since I have the Lighthouse. I lost my curragh and a galley to suicide runs, and just haven't built any more yet.
-Arrian
__________________
grog want tank...Grog Want Tank... GROG WANT TANK!
The trick isn't to break some eggs to make an omelette, it's convincing the eggs to break themselves in order to aspire to omelettehood.
|
|
|
|
January 27, 2004, 07:13
|
#23
|
King
Local Time: 17:04
Local Date: November 2, 2010
Join Date: Feb 2003
Posts: 1,351
|
Alexman,
you might also look on my 'Emperor C3C' thread. I put a table with the difference between wasted shields before and after the FP. Is that helpful in any way?
__________________
The Mountain Sage of the Swiss Alps
|
|
|
|
January 27, 2004, 08:26
|
#24
|
Firaxis Games Software Engineer
Local Time: 13:04
Local Date: November 2, 2010
Join Date: Mar 1998
Posts: 5,360
|
Arrian, you have done a great job of placing your Forbidden Palace for the current state of your empire. You have almost no rank corruption problems, so the best location is much like it used to be in PTW, so that the distance corruption is minimized.
I think the key is to keep your FP core under the modified OCN. Your current OCN is 31 without a courthouse and 36 with a courthouse:
Nopt = 20*(0.85 + 0.25 + 0.1 + 3/8 + 0.25*Ni)
The rank of your Forbidden Palace city, Kawauka, is 22.
The rank of Vladivostock, a city in the FP core in the opposite direction of the Palace, is 28.
You might have afforded to place the FP a little farther away, and still be below Nopt with a courthouse in your FP area, and certainly afforded to place it farther away if you count on police stations. With a farther FP, when you would have expanded to conquer your continent, your distance corruption would not be as bad in the western areas.
What you have done is very good choice though. A FP closer to your palace will give some super-productive cities in its core. A FP farther away might increase the overall economy of your empire, but it would not have as strong individual cities.
MS, I'll look at your thread, but I'm not sure if I can add anything, unless you have any specific questions of why you are observing a certain behavior.
|
|
|
|
January 27, 2004, 09:03
|
#25
|
Warlord
Local Time: 18:04
Local Date: November 2, 2010
Join Date: Nov 2003
Posts: 177
|
alexman, u must be the spawn of sid,
to be so knowledgeble about CIV is amazing
/me tips hat to you
|
|
|
|
January 27, 2004, 10:48
|
#26
|
Deity
Local Time: 13:04
Local Date: November 2, 2010
Join Date: Jul 2001
Location: Kneel before Grog!
Posts: 17,978
|
Thanks, alexman. The number-crunching is a little beyond me. But it seems my choice, based on my basic understanding of the new system + gut instinct, appears to have been a good one. So now I know.
I ended up playing forward a bit after I posted the game, and suffice it to say that I now have a bunch more cities. But, as I understand it, so long as the newly acquired cities are farther from the Palace than the cities in the FP area, the FP area will be ok, right?
See, I went and conquered Germany (Pyramids, HG, wines. Couldn't resist). That gave me... let's see... 10-11 more cities. Russia is destroyed too (1 city). I built a city SW of the FP city, 6 of the gold mountain. Spain attacked me, and lost 1 city for their trouble (in the hills, west of the gold mountain).
So about 14 new cities have entered the empire. The German cities will always be corrupt, I figure, which is fine. They're mostly irrigated already (thanks, AI!) so they will be specialist cities.
-Arrian
p.s. Built those galleys & made contact, though the Dutch beat me to it. No matter, since the Dutch are horribly backward compared to the rest of my continent.
p.p.s Coracle would have had a stroke. I had German city flip on me, taking with it a 3x med inf army, an ancient cav, and at least one healing elite mounted warrior.
__________________
grog want tank...Grog Want Tank... GROG WANT TANK!
The trick isn't to break some eggs to make an omelette, it's convincing the eggs to break themselves in order to aspire to omelettehood.
Last edited by Arrian; January 27, 2004 at 12:04.
|
|
|
|
January 28, 2004, 00:06
|
#27
|
Emperor
Local Time: 13:04
Local Date: November 2, 2010
Join Date: Jan 2002
Posts: 7,017
|
So the distance Corruption for cities under Communism only varies with the number of Corruption improvements (assuming they're connected to the trade network)?
1. No Courthouse or Police Station: Cd = 25%
2. Either Courhouse or Police Station: Cd = 12.5%
3. Both Courthouse and Police Station: Cd = 6.25%
Right?
Dominae
__________________
And her eyes have all the seeming of a demon's that is dreaming...
|
|
|
|
January 28, 2004, 00:16
|
#28
|
Emperor
Local Time: 13:04
Local Date: November 2, 2010
Join Date: Jan 2002
Posts: 7,017
|
alexman, let me throw out a statement and you let me know if it's correct: building a Forbidden Palace in a remote location no longer produces a "second core", because typically most of the cities around that location will have high rank, and so their small distance Corruption will be overshadowed by their rank Corruption.
If true, it is no longer a good strategy to rush the FP in a recently-conquered empire, unless that empire is rather close to home.
Dominae
__________________
And her eyes have all the seeming of a demon's that is dreaming...
|
|
|
|
January 28, 2004, 07:42
|
#29
|
Firaxis Games Software Engineer
Local Time: 13:04
Local Date: November 2, 2010
Join Date: Mar 1998
Posts: 5,360
|
Quote:
|
Originally posted by Dominae
1. No Courthouse or Police Station: Cd = 25%
2. Either Courhouse or Police Station: Cd = 12.5%
3. Both Courthouse and Police Station: Cd = 6.25%
|
Unless the city is not connected to the trade network, that's absolutely right.
Quote:
|
building a Forbidden Palace in a remote location no longer produces a "second core", because typically most of the cities around that location will have high rank, and so their small distance Corruption will be overshadowed by their rank Corruption.
|
While this might be true in most cases, it's not necessarily always true. As you know, the amount of corruption in the FP core depends on the number of cities that are closer to the palace than a given city in the FP core. If you have a small core around your palace (because you're on an island, or because you don't want to attack your immediate neighbors, or whatever reason), then you can rush your FP on the moon and it would provide the same benefit as if you had rushed it at any other location (unless it overlaps with your Palace core).
A good way to check whether your FP core will be functional is to make sure that the ranks of the FP core cities are less than their modified OCN. For a standard map (OCN=20), in Republic, with a FP and a courthouse, the modified OCN is about 34. So, for example, as long as your Palace core is under the OCN (20), you can have 14 productive cities in your FP core.
|
|
|
|
January 28, 2004, 09:59
|
#30
|
Deity
Local Time: 13:04
Local Date: November 2, 2010
Join Date: Jul 2001
Location: Kneel before Grog!
Posts: 17,978
|
Quote:
|
A good way to check whether your FP core will be functional is to make sure that the ranks of the FP core cities are less than their modified OCN. For a standard map (OCN=20), in Republic, with a FP and a courthouse, the modified OCN is about 34. So, for example, as long as your Palace core is under the OCN (20), you can have 14 productive cities in your FP core.
|
Level of play influences this as well, right? My game was played on Monarch level, and my civ was commercial. It was a standard map. Commercial is +25% and Monarch level multiplies the OCN by .9, right?
I tried using the formula you set forth above, and I came up with a modified OCN of 37.5 for my Iroquois empire. Standard Map, Monarch, Commercial Civ, Republic*, courthouses.
Nopt = max(20*(.9+.25+.1+.375+.25), 1).
Am I right. Or at least close to right?
-Arrian
* - republic at the time of the save I posted above. The empire is now a democracy, and not all that far away from getting police stations. Is anyone interested in the industrial era save, to see how the FP area is doing when more built up?
__________________
grog want tank...Grog Want Tank... GROG WANT TANK!
The trick isn't to break some eggs to make an omelette, it's convincing the eggs to break themselves in order to aspire to omelettehood.
|
|
|
|
Posting Rules
|
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is On
|
|
|
All times are GMT -4. The time now is 13:04.
|
|