CleverRaven / Cataclysm-DDA

Cataclysm - Dark Days Ahead. A turn-based survival game set in a post-apocalyptic world.
http://cataclysmdda.org
Other
10.34k stars 4.14k forks source link

[CR] Adjusting the new CAL/kg row on the (E)at menu to be CAL/L instead. #44365

Closed gkarfakis19 closed 4 years ago

gkarfakis19 commented 4 years ago

After I implemented the new CAL/kg row on the (E)at menu, worthwhile concerns were brought up that this does not effectively describe how filling a certain food is. It does, however, describe how energy dense a food is, which helps when hauling large amounts of food. This might be misleading, especially for new players, and is arguably less useful than a CAL/L row.

Do you think the CAL/kg row should be changed to CAL/L?

cosmo-naut commented 4 years ago

What determines how filling food is? I was under the impression it was L but your pull request lead me to believe it may actually be kg. It is based on volume, correct? If so then I would say that cal/kg is more useful.

Is it possible to include cal/kg in an item's nutritional information?

Maddremor commented 4 years ago

kcal/100g is the standard measure IRL, so it seems a reasonable default.

mqrause commented 4 years ago

If stomach fullness is determined by the volume of the item eaten, then something is wrong if you ask me. I doubt most food items have a volume defined by their actual density, so they should become smaller when you chew them. I don't really know about the actual specifics, but I would assume most foods have a pretty similar density once eaten, so calories per mass should be a much better indicator.

DoctorVanGogh commented 4 years ago

I was the person who pointed out to @gkarfakis19 that [energy]/[/mass] (while the perfect real world unit) was of rather limited use and was about to point out how irrelevant mass was for consumption. Turns out I was partially wrong and things are utterly weird (did a dive into the actual game code).

Explanation

  1. Food has volume (visible at the eating screen) That volume can internally be "wet" and/or "solid" volume. Wet volume will simply be added as "water consumed".
  2. The solid part of that volume gets special treatment and is turned into an "effective" volume to be added to the stomach . This varies by the actual energy density in CAL/g of the consumed food (So yay - good column!)
  3. That "effective" solid volume is then added to the stomach (which is capped at 2.5 Liters)[1].

Source

https://github.com/CleverRaven/Cataclysm-DDA/blob/f5505090839ed3f750d90b0d80dad567e7d5a75a/src/consumption.cpp#L1381-L1393

Examples

Energy density < 1000 1000-3000 3000+
Effective Volume same as solid volume solid volume times the energy density solid volume times the square root of the triple density
before eating image image image
eaten food image image image
after eating image (250ml - same as eaten food) image (656 mL - or 250ml x 2.7) image (1082ml or 250ml x 4.3 or 250ml x sqrt(3 x 6.25) )

So yeah.... That consumption system is weird. Presumably the "up-voluming" of the food is the "disincentivize eating pure fat" logic at play. Except now with the hunger & activity systems, the player is actually incentivized to eat calorie dense food.... which would be fat.

Suggestion

With the current system an ideal column (from a min/max perspective) would be something like "calories per effective volume".


[1] Those 2.5 liters are digested to the guts (which have no volume limits) over 3 hours. So over 24 hours a character can consume a maximum of 8 x 2.5L or 20L of effective volume of food. Sleep will obviously remove some fraction, as will consumption of water (although water gets "digested" within 5 minutes, so the calorie blocking impact is minimal).

anothersimulacrum commented 4 years ago

zIt's more of a 'sausages aren't filling enough' adjustment, it's not really effective enough to disincentivize eating pure fat.

gkarfakis19 commented 4 years ago

I could certainly change the row to display "calories per effective volume". Thing is, I don't know how intuitive such a nebulous number would be, especially to new players, or basically anybody that hasn't read the source code.

DoctorVanGogh commented 4 years ago

With the current system an ideal column (from a min/max perspective) would be something like "calories per effective volume".

Additional remark: I would certainly welcome that column (from a player perspective). Alas that should not be visible from the get go to the ingame character. Only something like the bionic bio_digestion or the SELFAWARE character trait that shows actual health numbers instead of of mere bars should give pure concrete numbers. I would would suggest some sort of dot/minus/plus system for "regular" characters. Basically everyone can judge "yeah, this is pretty filling" or "me, that was nice but I'm still hungry" but specific numbers are not obvious.

So maybe a column for those values, but with ++, +o, oo, -o, -- as some sort of "nutri-scrore"? And only certain traits and equipment give actual real numbers?

gkarfakis19 commented 4 years ago

Sounds like a better way of doing things. I will make a draft PR that incorporates a part of the solution, as I am a relatively new contributor and it's a great excuse for me to learn how to create a new bionic in the game, supported with c++ code.

DoctorVanGogh commented 4 years ago

bio_digestion already exists - but if you are bent on adding a new thing... There's no reason why a significantly watered down version like a "calorie analyzer" could not also exist.

gkarfakis19 commented 4 years ago

Yeah, but would an expanded digestive system reaally give you insight on exactly how filling a food is before you even eat it? I think it makes sense with a trait like "nutrition expert" (inspired by Zomboid), and perhaps a bionic like a food analyzer.

DoctorVanGogh commented 4 years ago

Well the bionic digestion is a blanket +50% in calorie absorption. So presumably the system does "something" with the food you ingest, presumably by doing just the "right thing" to squeeze more calories out of them. Arguably one way for that would be some sort of "analyze and add stuff to break down better". And the analyze part then seems almost tailor made for this. Plus it would add the full functionality on more existing systems than "just" self-aware.

I would always argue that systems which are coupled more strongly produce a more cohesive whole. So if there is a new feature foo it might feel merely bolted on if there is just a special_foo_hook to integrate with other existing things. But if you couple it into systems bar & baz it can almost get to a "well, wasn't this always like this?" impression.

gkarfakis19 commented 4 years ago

I agree with you. No need for a new, minor and almost worthless bionic that will probably get wiped once that bionic rework happens anyway. I'll try to bolt the functionality on to bio_digestion.

Zireael07 commented 4 years ago

@gkarfakis19: Could also get tacked onto the Self-Aware trait, that currently IIRC only shows your exact health values.

lcy03406 commented 4 years ago

The consumption system is weird.

Popcorn is light, because it is exploded corns. it should not explode again in stomach.

Its stomach size should not be 4 times to its size in shelf. It should be 4 times to its size in mouth.

Zireael07 commented 4 years ago

Popcorn issue sounds like https://github.com/CleverRaven/Cataclysm-DDA/issues/42425