Skip to content
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

Cans don't preserve their contents. #3566

Closed
Rivet-the-Zombie opened this issue Oct 10, 2013 · 3 comments

Comments

Projects
None yet
3 participants
@Rivet-the-Zombie
Copy link
Member

commented Oct 10, 2013

Cans of broth or V8 which you find in stores are generally no good to eat, because their contents spoil at the usual rate without regard for the fact that its contained in a sealed vessel.

Short of doing something akin to the 'sealed jar of XXXXX' I'm not sure how to fix this.

@ianestrachan

This comment has been minimized.

Copy link
Contributor

commented Oct 10, 2013

Sort of related to #2643.

The root issue is that the food itself determines if it has spoiled, but it has no knowledge of whether it is in a container or not.

@ianestrachan

This comment has been minimized.

Copy link
Contributor

commented Nov 8, 2013

Okay, just throwing this out as an idea:

  • 'active' items (the ones with yellow names) are processed each turn by map::process_active_items_in_submap, so there won't be much extra work here if we handle food in this function, as...
  • This function already goes through every square, and looks at every item, to determine if corpses revive, use functions for active items (like chainsaws) get called, if food stops being hot, etc.
  • Let's rework food spoilage so that this function deducts from the time-until-spoiled if:
    • The item is food
    • The item is not in a sealed container (probably requires a "TIN" or "SEALED" flag to be added to containers, no big deal)
    • The item is not refrigerated (ambient temperature below 30F? Could eventually also have working vehicle minifridges)

That way, food only spoils if it's left out in the open. Perhaps it can even acquire the "(COLD)" flag, and served_cold items (most drinks, for instance) could give a bigger morale boost, just like served_hot. (Apocalypse in style: Keeping a minifridge full of cold beers)

The biggest problem with this is the 'reality bubble' would kick in, and food outside the bubble would never spoil. The best solution would be to 'catch up' on an area that is loaded back into the bubble, but that's a separate issue entirely.

@kevingranade

This comment has been minimized.

Copy link
Member

commented Nov 9, 2013

Works for me, that's what I've been proposing, specifically giving items a
half-life and a decay product that's run either every turn, or more
periodically if it becomes a load issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.