Community Balance Patch - New Happiness System Explained

Hei G, dunno if its me, but im havin an issue with this happiness system.

I did do a clean install, cache and mod cache, across two computers, using the CP CBP CSD C4F and the decisions mod, along with more luxuries and a couple of Howard's mods, none of them related to happiness.

Thing is: unhappiness is way across the board. I see some AI's with -16 Happiness. The problem is, IMO that the system is balanced for faster plays (I play on Epic). In faster speeds you can get the buildings like colosseum, Library faster, but in slow speeds... GOSH.
Im sitting at -6Happiness. 4Luxury resources and two natural wonders. 2 Cities with military on both and improved stuff, positive gold.

Alexander is at -12. Athene is surrounded by barbarians, pillaged tiles and captured civilians, my score is already 3x the one of China, the second best ATM.

IMO, this should be tweaked: on the early days of cities, people aint worried about culture, gold or whatnot. They want two main things: Food and Safety, and I think that shifting the First or even the second Era happiness parameters for Food and Order would make for a game where the AI hasn't lost on turn 30 already.

Perhaps its just me with this issue?
 
I was actually having happiness problems at early game standard speed too. Not sure if that may be a fluke though.
 
I was actually having happiness problems at early game standard speed too. Not sure if that may be a fluke though.

Nah, I've just got the happiness threshold/increase tweaked to be a bit too intense. I can, and will, back that down in the next version, which I hope to release today.

G
 
"Similarly, over a certain amount of positive happiness, your empire gains a small % boost to all of its yields. Again, this makes expansion/unhappiness less binary, and allows players to be slightly unhappy without catastrophic problems."

Can you elaborate the exact boost values of positive happiness and at which thresholds? Thanks! :)
 
"Similarly, over a certain amount of positive happiness, your empire gains a small % boost to all of its yields. Again, this makes expansion/unhappiness less binary, and allows players to be slightly unhappy without catastrophic problems."

Can you elaborate the exact boost values of positive happiness and at which thresholds? Thanks! :)

I've got that feature disabled currently, as it is a bit wonky. Since there are golden ages in civ 5 (unlike BE), I think I'd rather simply buff those than give passive bonuses.

G
 
I've got that feature disabled currently, as it is a bit wonky. Since there are golden ages in civ 5 (unlike BE), I think I'd rather simply buff those than give passive bonuses.

G

The problem is that golden ages are too easy to obtain(Great artists) that it feels like an exploit, especially when you combine extra bonuses to golden ages from religion or etc...
It is almost 90% of the time more valuable to use the great artist for golden ages rather then art works!
 
I think the unhappiness is rather high early on (having some problems with disorder) and would like to tweak it.

Could you explain where the values for the different components are in CBP version 13? Can't seem to find anything related to disorder, boredom, ...

\Skodkim
 
The newer versions of the happiness system are much more simple than the previous ones – there are really only a few values that matter:

Code:
-- Base Modifier for Capital Thresholds. Offsets boost from Palace, helps make Capital a source of Unhappiness early on. 15% is default. Capital needs higher because it is the capital, silly.
		INSERT INTO Defines (
	Name, Value)
	SELECT 'BALANCE_HAPPINESS_CAPITAL_MODIFIER', '15'
	WHERE EXISTS (SELECT * FROM COMMUNITY WHERE Type='COMMUNITY_CORE_BALANCE_CITY_HAPPINESS' AND Value= 1 );

-- 	Base Value of Test - Modifier to tech % cost. 2.15 is default.
	INSERT INTO Defines (
	Name, Value)
	SELECT 'BALANCE_HAPPINESS_TECH_BASE_MODIFIER', '2.15'
	WHERE EXISTS (SELECT * FROM COMMUNITY WHERE Type='COMMUNITY_CORE_BALANCE_CITY_HAPPINESS' AND Value= 1 );

-- Base increase of threshold values based on # of techs (ignore 'City' part). Increases the Global Averages as you research techs. Higher values are more difficult. 0 is default.

	INSERT INTO Defines (
	Name, Value)
	SELECT 'BALANCE_HAPPINESS_TECH_BASE_CITY_COUNT', '0'
	WHERE EXISTS (SELECT * FROM COMMUNITY WHERE Type='COMMUNITY_CORE_BALANCE_CITY_HAPPINESS' AND Value= 1 );
	
-- Value by which yield/threshold difference is divded. 40 = 1 point of unhappiness for every 0.40 difference between city yield and global average.
	INSERT INTO Defines (
	Name, Value)
	SELECT 'BALANCE_UNHAPPY_CITY_BASE_VALUE', '40'
	WHERE EXISTS (SELECT * FROM COMMUNITY WHERE Type='COMMUNITY_CORE_BALANCE_CITY_HAPPINESS' AND Value= 1 );

These can all be found in the cityhappiness.sql file.

For your case, I'd bump BALANCE_UNHAPPY_CITY_BASE_VALUE to 45 or 50, as that'll make the amount of unhappiness from being below global averages a bit less unhappiness-producing (it'll require a greater amount of difference to produce more than 1 unhappiness from a yield). You might also consider making BALANCE_HAPPINESS_TECH_BASE_CITY_COUNT a negative value, as that'll make the early game thresholds a little lower than normal. If the problems are in the capital, changing the BALANCE_HAPPINESS_CAPITAL_MODIFIER value will help with that a bit.

G
 
Thanks for the explanation.

I tried changing BALANCE_UNHAPPY_CITY_BASE_VALUE to 50 and BALANCE_HAPPINESS_TECH_BASE_CITY_COUNT to -10 for a test.

This raised a couple of questions though.

1: I had a city that was 0.34 (produced 0, needed 0.34) below the global threshold from poverty resulting in 1 unhappiness. Shouldn't this be 0 unhappiness with the given unhappiness values?

2: I then completed a wonder with should decrease unhappiness from poverty in all cities (PovertyHappinessChangeGlobal = '2'). This lowered the global poverty threshold to 0.14 but the city still produced 1 unhappiness from poverty. Is this correct behavior?

Sorry for all the questions - I like the system and I'm able to play with it but I'm still not sure how it works in detail :)

Edit: Just checked the values a couple of turns later and now there's no unhappiness in the city...

\Skodkim
 
Which order should BALANCE_HAPPINESS_TECH_BASE_CITY_COUNT be in for a minor (somewhere around 3'ish) happiness boost in the early game? Not looking for an exact value but I have no idea if it should ne 0.5, 1, 5 , 20, ..?

\Skodkim
 
Hi G

Sorry for being pushy but do you have any comments on the question above?

Tweaked the values a bit in my current game and on the verge of the industrial age. Early game was fine but now I have about +50 happiness so maybe I overdid it.

\\Skodkim
 
This thread is wonderful for explanation--I couldn't imagine an overhaul mod without such transparency. However, I'm probably just dense, but I'm still pretty confused. I've been in negative happiness for almost an entire game now and I realized I don't truly know what to be doing to improve my happiness. I know I need overall more well-rounded cities but I don't know what actions will have what effect (it's not like the base game where you know building that Colosseum will net you +2 happiness).

I created an album to show a specific situation here. In this instance I have weak defenses as my troops are away fighting an offensive war, and it shows in my unhappiness.

I'd like to understand what exactly the tooltip is telling me for each category. If somebody could explain that, I'd be very much grateful. For some reason I'm not quite understanding exactly where the numbers for unhappiness are coming from.
 
This thread is wonderful for explanation--I couldn't imagine an overhaul mod without such transparency. However, I'm probably just dense, but I'm still pretty confused. I've been in negative happiness for almost an entire game now and I realized I don't truly know what to be doing to improve my happiness. I know I need overall more well-rounded cities but I don't know what actions will have what effect (it's not like the base game where you know building that Colosseum will net you +2 happiness).

I created an album to show a specific situation here. In this instance I have weak defenses as my troops are away fighting an offensive war, and it shows in my unhappiness.

I'd like to understand what exactly the tooltip is telling me for each category. If somebody could explain that, I'd be very much grateful. For some reason I'm not quite understanding exactly where the numbers for unhappiness are coming from.

The Shields are City Strength, which is affected by techs (slightly), buildings (like Walls), Garrisons, and buildings such as the Barracks/Armory/Constable/Police Station. The numbers you see in the tooltip is how much of any given yield you are making per citizen. So, for example, Athens is producing 1.5 shields per citizen (rounding of city defense makes it look like you are producing less than you are), but needs to be producing 3.2 per citizen (or 3.2 x 11, which is 35 shields total). Disorder is hard to tame, especially as your city grows.

Now, where are these numbers produced? By global averages. The game calculates the yield averages of every major civ-owned city and divides that by their populations. This value is considered the baseline for poverty/illiteracy/disorder/etc. - it is, essentially, the Global Quality of Life Index. If your city's per citizen yields are below this line, you'll produce unhappiness. If above it, you won't. The more you are below it, the more unhappiness you produce (1 unhappiness for every .4 points you are below, currently).

To correct these issues, you have to build or produce the corresponding yields - for disorder, work on a better garrison and/or more defensive buildings.

G
 
The Shields are City Strength, which is affected by techs (slightly), buildings (like Walls), Garrisons, and buildings such as the Barracks/Armory/Constable/Police Station. The numbers you see in the tooltip is how much of any given yield you are making per citizen. So, for example, Athens is producing 1.5 shields per citizen (rounding of city defense makes it look like you are producing less than you are), but needs to be producing 3.2 per citizen (or 3.2 x 11, which is 35 shields total). Disorder is hard to tame, especially as your city grows.

Now, where are these numbers produced? By global averages. The game calculates the yield averages of every major civ-owned city and divides that by their populations. This value is considered the baseline for poverty/illiteracy/disorder/etc. - it is, essentially, the Global Quality of Life Index. If your city's per citizen yields are below this line, you'll produce unhappiness. If above it, you won't. The more you are below it, the more unhappiness you produce (1 unhappiness for every .4 points you are below, currently).

To correct these issues, you have to build or produce the corresponding yields - for disorder, work on a better garrison and/or more defensive buildings.

G

You're explanation is pretty much how I thought it worked...which only confuses me more I'm afraid. Athens is not producing 1.5 shields per citizen...it is producing exactly one (11 shields, 11 citizens). Where is the 1.52 coming from?

I'm also pretty certain that a city with 35 shields would be the highest defense in the world at this point in the game, so how is this determined by the global average? A little later I also noticed my reasonably large capital city with a palace/library (nobody has universities yet) was receiving an illiteracy penalty. Sure, it could maybe have a citizen or two more or a National College, but is it really below the average? Unless the AI works science specialists everywhere almost immediately I find this a little hard to believe.

I didn't know it was 1 unhappiness per every .4 points behind the average you are, that's very helpful to know. Puts things in perspective a bit.
 
You're explanation is pretty much how I thought it worked...which only confuses me more I'm afraid. Athens is not producing 1.5 shields per citizen...it is producing exactly one (11 shields, 11 citizens). Where is the 1.52 coming from?

I'm also pretty certain that a city with 35 shields would be the highest defense in the world at this point in the game, so how is this determined by the global average? A little later I also noticed my reasonably large capital city with a palace/library (nobody has universities yet) was receiving an illiteracy penalty. Sure, it could maybe have a citizen or two more or a National College, but is it really below the average? Unless the AI works science specialists everywhere almost immediately I find this a little hard to believe.

I didn't know it was 1 unhappiness per every .4 points behind the average you are, that's very helpful to know. Puts things in perspective a bit.

The shield value is amplified by your garrison, policies, some buildings, etc. - these may not be reflected in the strength of the city discretely.

The global average is also affected by your tech level - as you tech up, the global average is inflated for your cities. Also, your capital has higher demands than all other cities by a factor of 20%.

G
 
The shield value is amplified by your garrison, policies, some buildings, etc. - these may not be reflected in the strength of the city discretely.

The global average is also affected by your tech level - as you tech up, the global average is inflated for your cities. Also, your capital has higher demands than all other cities by a factor of 20%.

G

Info is very much appreciated, but I still don't think it explains the discrepancy in the Athens example. There was no garrison or military buildings of any sort, nor any policies that would seem to boost the shield value (had filled out Might but that's it). I don't see where the .5 shields per citizen difference could be coming from.

Sorry if I'm being annoying, I just really like to know the numbers behind things when I play. I'm not quite a spreadsheet-oriented player, but I'm pretty close.
 
Info is very much appreciated, but I still don't think it explains the discrepancy in the Athens example. There was no garrison or military buildings of any sort, nor any policies that would seem to boost the shield value (had filled out Might but that's it). I don't see where the .5 shields per citizen difference could be coming from.

Sorry if I'm being annoying, I just really like to know the numbers behind things when I play. I'm not quite a spreadsheet-oriented player, but I'm pretty close.

Athens is your capital, thus the capital defenses are added in twice (the function is as follows):

Code:
int CvCity::getUnhappinessFromDefenseYield() const
{
	int iDefenseYield = getStrengthValue(false);
	iDefenseYield += (GetCityBuildings()->GetBuildingDefense());

	int iDamage = getDamage() * 4;

	if(iDamage > 0)
	{
		iDefenseYield -= iDamage;
	}

	//Per Pop Yield
	if(getPopulation() != 0)
	{
		iDefenseYield = (iDefenseYield / getPopulation());
	}
	
	return iDefenseYield;

So buildings are worth double their yield (this makes buildings affect your disorder value a bit more than normal).
G
 
Back
Top Bottom