Cataclysm-DDA icon indicating copy to clipboard operation
Cataclysm-DDA copied to clipboard

No NPC food mod and the appearance of emaciated NPCs

Open IdleSol opened this issue 1 year ago • 5 comments

Describe the bug

I'm not sure if this is an error. A similar situation came up in the discussion of this thread: https://github.com/CleverRaven/Cataclysm-DDA/issues/73768#issuecomment-2116076057

So, I'm starting a new world with a mod to disable food requirements for NPCs. Starting with my best friend Liam. And here's what I see: 1 2

How correct is this? On the one hand, no one is immune to starvation in a cataclysmic event. On the other hand, it's day one. NPCs don't need to eat and the player has no way to help them gain weight and remedy the situation. (Does this affect NPCs?) Perhaps I don't know the way? The debug menu, doesn't count.

In sum, I see three problems:

  1. The appearance of the emaciated in the first days and/or weeks of the cataclysm.
  2. The appearance of the emaciated among unique characters, not just random NPCs.
  3. The appearance of emaciated when the No NPC food mod is enabled and there is no way to fix the emaciation.

Attach save file

Даттон-trimmed.tar.gz

Steps to reproduce

Start the game with the starting NPCs and check their status. Sooner or later the appropriate situation will appear.

Expected behavior

Hard to say, depends on how much is the norm. Minimum: feed NPCs with the mod on to get them back to normal. As far as I remember, if they are wounded, they will lose calories to recover, which could lead to the same situation, but mid-game.

Screenshots

No response

Versions and configuration

  • OS: Windows
    • OS Version: 10.0.19043 (21H1)
  • Game Version: cdda-experimental-2024-05-22-0335 5b4b49b [64-bit]
  • Graphics Version: Tiles
  • Game Language: Русский <color_dark_gray>(88,7%) [ru]
  • Mods loaded: [ Тёмные Дни Впереди [dda], Отключить потребности у НПС [no_npc_food], Портальные штормы игнорируют НПС [personal_portal_storms], Медленный рост фунгалоидов [no_fungal_growth], Характеристики за убийства [stats_through_kills] ]

Additional context

No response

IdleSol avatar May 22 '24 15:05 IdleSol

I vaguely recall a past issue where players migrating their saves from Stable suddenly had their characters turn emancipated despite no change in stored kcals, due to how the thresholds were changed. So I would guess that it's possible that the possible starting values for NPC stored calories need to be updated to match the new thresholds.

Found it #73033

XygenSS avatar May 22 '24 16:05 XygenSS

I thought that somewhere in the game files, there is a json describing the average NPC. The parameters of which are then randomly changed.

But it looks like that's not the case. If I understand correctly, we need these lines:

https://github.com/CleverRaven/Cataclysm-DDA/blob/5b4b49b71e8a5fdc6b655bfec81be6cca39af9f9/src/npc.cpp#L655-L659

My knowledge is not enough to say what is going on here. Luckily, I figured out to look at the notes. #64718

At day 0, with the distribution of χ^2(6), 81% of NPCs have BMI more than 3.0 (aka "Normal") , 54% of them have BMI more than 5.0 (aka "Overweight"), and 12% of them have BMI more than 10.0 ( aka "Obese" ).

Not that it's any clearer. But most likely the remaining 19% of NPCs are NPCs with BMI less than 3. Some of them may get BMI = 1 (0.2 * 5).

So we get a random NPC with BMI < 3. And on top of it we put a mask of a unique NPC. Or a template, in general traits, skills and bonuses to parameters are added. Assuming I understand the mechanics correctly.

This causes an NPC who is in a food warehouse to be starved. And an NPC with a history of starvation is at the obese stage.

IdleSol avatar May 22 '24 17:05 IdleSol

Yeah this has happened to me as well recently, npc skeletal and starving as well as on -100 health. Still the starvation condition didn't seem to take an effect..or that is the stats showed as normal, no penalties.

EternalLaughter avatar May 23 '24 13:05 EternalLaughter

i've seen this in my world hunger-trimmed.tar.gz

in this save, Elbert 'Grief' Teixeira, logger came from the nearby lumbermill. they are Skeletal and Severely Malnourished. npc needs are off.

mischief avatar May 29 '24 15:05 mischief

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. Please do not bump or comment on this issue unless you are actively working on it. Stale issues, and stale issues that are closed are still considered.

github-actions[bot] avatar Jun 28 '24 16:06 github-actions[bot]