I like this, Wodhann. Genuinely. The functions will be pretty simple to write and, hopefully, the AI will be able to handle this without having to alter their existing behavior. Honestly, it reminds me a bit of how Civ Rev handled culture, where too much pop without culture led to your culture being 'disgusting,' and thus the possibility of city-culture-flipping. Seems similar (minus the last bit, which would be a factor of unhappiness in civ 5). It also has the knock-on benefit of forcing wide players (really, all players) to build less-used structures like walls, castles, etc.
Critiques:
I'd get rid of the 'enemies in borders,' one and do '# of pillaged tiles' or 'factor of city damage.' The AI doesn't really prioritize clearing out enemy units unless they're in a high-priority spot (it could be abused, in other words). The AI is, however, obsessed with fixing pillaged tiles, and city damage is a better metric of losing a war.
Not sure if you mentioned these possibilities earlier, but I think these should be considered as well:
- # of Unhappiness per # of minority religion followers or non-followers in a city (taking it away in the piety tree, in an ideology/wonder or as a tenet/belief/reformation belief). This makes religion matter more as a factor of preventing unhappiness, rather than simply gaining more happiness.
- # of Unhappiness per # of trade routes coming from/to the same city (eww foreigners gross). This could be reduced by a policy (commerce tree needs some love), or a civ trait (carthage, venice, morocco, etc.).
- Also unhappiness per # of citizens in each city should be increased, with the addition of the courthouse as a building for all cities (acting as a mini-forbidden palace for each city), and the constabulary/police station reducing this further. We could simply create a new 'takeover city' building (or process) for puppeted cities, taking the place of the courthouse. This makes these spy-related buildings way more useful and necessary for all players.
With these changes, I'd also remove the flat % penalties from # of cities (science, culture, etc.) and fold those penalties into a scaled unhappiness modifier. In other words, take away 'always-on penalties,' even if you are doing well, and add in scaled penalties for most yields as you gain more and more unhappiness. Some of these things may have been mentioned if so, consider my points above as affirmations of liking those points.
Other Thoughts
If we go with this, and I'm truly happy to do so, I do think it requires a re-think of how national wonders work. Going back to an earlier post I made, the best way to handle national wonders would be as a factor of national population. So, for example, to build the national epic, you need 15 total national population. 20 for national college, 50 for oxford, and so on...you get the idea. I'd also have each national wonder in a city increase this base population requirement by a set amount (so building more than one national wonder in a city would require more population overall, encouraging players to spread them out) OR increase production cost by this factor (instead of # of cities).
This change would allow wide players (if wide enough) to get them, and also tall players (if tall enough) to get them. Currently, wide is hurt badly (and unfairly), especially when considering late-game national wonders. This also allows national wonders to work as imperial milestones of success, rather than gameplay-restricting roadblocks.
Lastly, I also want to scale luxuries based on population. If population is the ultimate factor of the game (it is, regardless of tall or wide, the single most important metric of performance), it makes sense that the most necessary means of combatting unhappiness should scale with population. This will make wide civs need more a more diverse amount of luxs than tall civs, which seems a fair trade-off.
G