-
Notifications
You must be signed in to change notification settings - Fork 4.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
NPCs remain permanantly hungry when eating out of faction camp stores #47663
Comments
Hmm... looking through the character code more, I'm starting to think the issue is with the stomach simulation. Testing seems to confirm my findings. If you update the NPC's hunger rating in the needs menu then wait 5 minutes, it goes back to what it was before. |
are you using the npc no needs mod by any chance? asking because mod_hunger() & mod_stored_kcal() should indeed not update with it enabled. |
I think the problem is that the code is directly putting calories in their stored kcal, not into their stomachs. |
I am not using that mod, no
Yeah, that's again what I meant but didn't say clearly :/ I think it would be fairly straightforward to just make a fake food_summary object to feed to the stomach, but I'm not sure if it would be preferable to do that or to try and keep more detailed track of the kinds of foods stuffed into the faction camp. Notably, at the moment I don't think NPCs are getting any vitamins from faction camp food, so a more detailed simulation may be warranted before vitamin deficiencies get changed to actually do something |
Describe the bug
NPCs remain perpetually hungry when being fed through faction camp stores. Their stored calories are correctly being updated so they don't actually starve, but their hunger meter remains maxed out, which causes them to complain of hunger and refuse to train you.
Steps To Reproduce
Expected behavior
Feeding NPCs through faction camps fills their stomachs properly so they don't complain of hunger or refuse to train you
Versions and configuration
Dark Days Ahead [dda],
Blaze Industries [blazeindustries],
Magiclysm [magiclysm],
Stats Through Skills [StatsThroughSkills]
]
Additional context
Second half of #47596
The relevant code:
Cataclysm-DDA/src/npcmove.cpp
Lines 3818 to 3826 in 0731d85
While testing this again on the latest version, I've noticed something interesting -- sometimes the hunger does seem to get updated and sometimes it does not. It seems like larger calorie deficits more reliably cause their hunger to go down, while a deficit of only 50 kcal usually causes hunger to remain at maximum. I'm not sure why.
The text was updated successfully, but these errors were encountered: