Food Surplus 50% lower

Delekhan

Prince
Joined
Jul 22, 2013
Messages
539
Location
Dallas, Texas
I'm finding that most of my cities have their total food surplus cut by 50%. Attached is a screenshot.

Does anyone know what causes this? The tooltips are not helping very much.

Also the landed elite policy in the tradition tree, which is supposed to grant +25% surplus food in every city, is not showing up in any city's tooltip.

EDIT: I figured out the cause. It looks like when happiness is below 12, the 75% surplus food penalty for unhappiness is applied, which with Landed Elite's +25% means a net -50%. I'm sure that is not intended. The Golden Age Counter also loses points based on how many below 12 the happiness level is.

Also, some strange things happen to the production % modifier when happiness goes below 12. In one example, it's 37% when happiness is at 9 and the correct 30% once happiness goes to 12 or above.

I am using the latest release, no other mods, and the Hagia Sophia and Specialist Yield fixes stackpointer created.
 

Attachments

  • 1.jpg
    1.jpg
    231.5 KB · Views: 109
It looks like when happiness is below 12, the 75% surplus food penalty for unhappiness is applied, which with Landed Elite's +25% means a net -50%. I'm sure that is not intended

I dunno.... what should be the intended design here? That the -75% comes after all other % modifiers?
 
Save Game is attached.

I'm currently in a Golden Age and most cities are in WLtK Day. Warwick isn't in WLtK so look at its food surplus. Also once you get out of the Golden Age notice how much gets added to the counter: Anything over 12 happiness. Anything under 12 happiness gets subtracted.

Apparently the game acts as though 12 happiness = 0 happiness for the purposes of surplus food and golden age counters.
 

Attachments

  • Game1.Civ5Save
    1.3 MB · Views: 42
Oh, I was misunderstanding, I thought you were saying at -12 happiness. There are food penalties at positive happiness levels??

That doesn't sound right; then the -75% penalty would kick in from turn 1, and it would take forever to even grow to size 2.

I'll look for this in my games.

I certainly noticed combat penalties starting to kick in at less than -10 happiness, which IIRC is different from vanilla.

Could the problem be in displayed happiness, not in the penalties code?
 
That's what I thought too. Landed Elite takes a lot of the bite off of the growth penalty, but it's there in every game I start. It's pretty sneaky since only food is affected and there's no tooltip to tell you it's happening.

Combat strength is unaffected, and production actually goes UP a bit (the happiness penalty kicks in under 12, but since happiness is still positive it's adding 2% per happiness point to production instead of subtracting). Golden age points are also affected.
 
but it's there in every game I start
Huh. This would explain why Tradition games seem to go so much easier than others. I'll take a look and watch closely at food accumulation. This seems very serious.

There are combat/gold/production penalties that scale at -2%/unhappiness in BNW.
Thanks, I'd forgotten, I think those are fine as an intended design. But there should be no bonuses or penalties at positive happiness, except for golden age accumulation.
 
The more I look into this and other related display problems I am beginning to ask 'why are we giving different display formats in our code when the end result is nothing?'

By that I mean we have extensively modified the core files to show these yields in a different manner but as for providing a better/clearer/easier snapshot of the empire's standing I think we have missed the mark.

The biggest and best reason for making change to these files is to add support for the modified yields. This is fine, the YieldLibrary.lua is being incorporated into the game's calculations and is constantly being checked to make sure it does the correct job. (mostly by stackpointer who is doing a stellar job)

As for the way the information is presented. Well, I am running two games concurrently to compare the information from vanilla to CEP and, sad to say, vanilla is clearer in most things.

Perhaps someone else can also make a comparison and highlight just what places need the most attention. I am particularly focusing on the InfoTooltipInclude.lua, which I believe handles the tooltips that show when mousing over the figures in both the CityView and the TopPanel. (could be wrong about that :mischief:)

The tooltips such as the one discussed in this thread and in the one on Railroads.
 
This isn't just a display problem, though it would have helped if the tooltips actually worked to detect this sooner.

I have noticed from running a test playthrough that this doesn't happen from the very start. The happiness discrepancy starts small at some point and then grows over time for some reason. At one point it was 8, then 10, and then 12. I have no idea what is causing it.
 
This isn't just a display problem, though it would have helped if the tooltips actually worked to detect this sooner.

I have noticed from running a test playthrough that this doesn't happen from the very start. The happiness discrepancy starts small at some point and then grows over time for some reason. At one point it was 8, then 10, and then 12. I have no idea what is causing it.

Could it be something about how the mod changes some buildings to give a mix of national and local happiness? Maybe the local happiness shows up for the purpose of the display, but not for the purpose of penalty calculations?
 
I think the problem is linked to food, production, and golden age points. Otherwise the combat penalty would also appear, and that doesn't happen until the display reads -1 or below, so at least that part is working properly.
 
Save Game is attached.

I'm currently in a Golden Age and most cities are in WLtK Day. Warwick isn't in WLtK so look at its food surplus. Also once you get out of the Golden Age notice how much gets added to the counter: Anything over 12 happiness. Anything under 12 happiness gets subtracted.

Apparently the game acts as though 12 happiness = 0 happiness for the purposes of surplus food and golden age counters.

Unfortunately I don't have all the mods you have active in this saved game.
Empire Wonder Mod specifically.
What exactly does this mod do? Is it related to this issue? Where can I find it?

I dislike using Steam to access mods so if it is only on that platform I doubt I will get it.
I will look elsewhere in the hope of seeing it.
 
It's not caused by that mod, I've had the same bug (sorry no saved game) when just running Communitas and IGE.
 
That mod just adds the Empire State Building wonder at Electricity, it doesn't change anything other than add the building. That's the only one active.

It's worth noting I've played test games with no mods other than the latest CEP release and the same thing happens.
 
I have found part of the problem, I think.

Our YieldLibrary.lua and the modified InfoTooltipInclude.lua make use of a new value stored in the modified Yields table.

This table has had some extra columns added to it to deal with extra functionality brought on by the YieldLibrary. One such column is called: GoldenAgeSurplusYieldMod.
This may be the cause of the problems if the YieldLibrary and InfoTooltipInclude functions are not working together properly. Likely.

This specific column in the table is dealing with how food is stored whilst in a GA. The other yields likewise now have different modifiers on them when in GAs, using the vanilla column GoldenAgeYieldMod.

It is quite possible that things are not yet running smoothly. With the increasing absence of Thalassicus and stackpointer having to firstly make sense of someone else's code, coupled with the fact that we are desperately short of skilled coders, this may take some time.
As has been made evident here many times my programming skill is at best, rudimentary, likewise most of the rest of the team. We are relying on the skills of the original coder, Thalassicus, and stackpointer to bring this beast up to scratch.

[my comments are not to be taken as evidence of Thal leaving this mod, he is on extended sabbatical until further notice.]
 
That's probably it. It looks like the problem starts in earnest after the first golden age. It seems that after exiting that first golden age problems start to really occur.
 
I have tested and re-tested your fix, and I am happy to report that it works perfectly and completely! Problem solved.

You are amazing. I had been scouring the Yield Library and tooltip code for 2 hours trying to find a cause. +10 to you.
 
Top Bottom