MestreLion said:
Wow, thats surprising, really surprising! Because thats one thing i observate in every war i go into: after 4-5 turns WW becomes a major issue, and after 10 or so turns its usually huge enough for me to stop war.
And, as we discussed earlier, although my tests are surely biased by my gameplay style, usually when i go to war its a sure win... i never lose cities or get pillaged, and i rarely lose troops (except suicide seiges), and i capture cities in a fairly constant rate (a city every 3-4 turns).
So, if only actions were relevant, mine should keep WW really low, but thats not what i see: it grows quite steadly.
Your strategy would lead to a Rapid rise in WW
You don't get WW for Losing you get it for Winning AND Losing.
(I poked around a Lot more... looks like I am wrong about a time factor, but not what you would think, time actually Decreases WW)
From the XML
WW_UNIT_KILLED_ATTACKING=3 (your unit is killed while attacking)
WW_KILLED_UNIT_DEFENDING=1 (you killed a unit that was defending)
WW_UNIT_KILLED_DEFENDING=2 (your unit was killed while defending)
WW_KILLED_UNIT_ATTACKING=2 (you killed a unit that was attacking)
WW_UNIT_CAPTURED=2 (your unit was captured)
WW_CAPTURED_UNIT=1 (you captured a unit)
WW_CAPTURED_CITY=6 (you captured a city)
WW_HIT_BY_NUKE=3 (you were hit by a nuke)
WW_ATTACKED_WITH_NUKE=12 (you attacked with a Nuke)
WW_DECAY_RATE=-1 (This is the time term, -1)
WW_DECAY_PEACE_PERCENT=99 (if you are at peace apparently 1% of WW leaves each turn)
Things to note... When dealing with units, Winning is better than losing for WW
When dealing with Cities+Nukes, Winning is WORSE than Losing for WW... capturing cities leads to WW, Losing them does not.
BASE_WAR_WEARINESS_MULTIPLIER=5
FORCED_WAR_WAR_WEARINESS_MODIFIER=-50
MULTIPLAYER_WAR_WEARINESS_MODIFIER=-50
The last two seem to be entered into %es... Forced War means the game is in Always War status
Here seems to be one of the places it is added in...this is in the Unit part of the SDK, in a section dealing with combat... I've cut it down a bit
if (pPlot->findHighestCultureTeam() != getTeam())
{
GET_TEAM(getTeam()).changeWarWeariness(pDefender->getTeam(), GC.getDefineINT("WW_UNIT_KILLED_ATTACKING"));
}
if (pPlot->findHighestCultureTeam() != pDefender->getTeam())
{
GET_TEAM(pDefender->getTeam()).changeWarWeariness(getTeam(), GC.getDefineINT("WW_KILLED_UNIT_DEFENDING"));
}
The thing to note is those pPlot->findHighest culture team
Which seem to say that if the combat action takes place on Your soil (where you have the Highest culture) then it doesn't add to War Weariness.
Another section of the SDK
void CvTeam::doWarWeariness()
{
int iI;
for (iI = 0; iI < MAX_TEAMS; iI++)
{
if (getWarWeariness((TeamTypes)iI) > 0)
{
changeWarWeariness(((TeamTypes)iI), GC.getDefineINT("WW_DECAY_RATE"));
if (!(GET_TEAM((TeamTypes)iI).isAlive()) || !isAtWar((TeamTypes)iI))
{
setWarWeariness(((TeamTypes)iI), ((getWarWeariness((TeamTypes)iI) * GC.getDefineINT("WW_DECAY_PEACE_PERCENT")) / 100));
So each turn WW goes down by -1 (the Decay rate) and if you are at Peace an additional 1% is removed
Also it seems that Each Team is stored Seperately for WW purposes (ie When England Does WW it checks its German WW, American WW, Aztec WW, in a Scenario or with PAs, it may also check its Russian-Chinese Alliance WW)
For the Actual Anger (From the City Area)
int CvCity::getWarWearinessPercentAnger()
{
int iAnger;
iAnger = GET_PLAYER(getOwnerINLIN()).getWarWearinessPercentAnger();
iAnger *= max(0, (getWarWearinessModifier() + GET_PLAYERgetOwnerINLINE()).getWarWearinessModifier() + 100));
iAnger /= 100;
return iAnger;
}
So it looks like the Jail (city Modifier) does add to Rushmore and Police State (Player Modifiers)
Elsewhere in the City file
iUnhappiness = ((iAngerPercent * (getPopulation() + iExtra)) / GC.getDefineINT("PERCENT_ANGER_DIVISOR"));
So it is proportional to population.