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

Combine last_rot_check and last_temp_check variables #38370

Closed
wants to merge 25 commits into from

Conversation

Hirmuolio
Copy link
Contributor

@Hirmuolio Hirmuolio commented Feb 26, 2020

Summary

SUMMARY: Infrastructure "Combine last_rot_check and last_temp_check variables"

Purpose of change

last_rot_check and last_temp_check are almost alway identical. And the situations where they are different can be changed so that they are same.

So there is no need for them to be separate.

Describe the solution

The time at which temperature and rot was last checked is now tracked by last_temp_check.

Other code changes that came with it:

  • Check for preserving container moved from process to process_temperature_rot.
  • Check for smallest temp/rot calc interval moved rom process_temperature_rot to process.
  • All things that rot have temperature. Moved some rot checks inside temperature checks in butchering and cooking.
  • set_item_temperature no longer resets last_temp_check. Process the item before setting temperature or use reset_temp_check if rot doesn't need calculating.

When food is heated up it will skip one rot calculation cycle (up to 10 minutes).
When liguids are combined in container they will skip one rot calculation cyle (up to 10 minutes).

I do not think these are enough of an issue to warrant workaround. It is also not easy to process items directly because the item does not know where it is (in something like freezer?).

Testing

Items rot at same rate as before.

Cooked items have same rot as in current version. Tested recipes without heating, with heating and multiple input materials.

Additional context

@Hirmuolio Hirmuolio changed the title Temp rot Combine last_rot_check and last_temp_check variables Feb 26, 2020
@sharkfinsouperman
Copy link

sharkfinsouperman commented Feb 26, 2020

Would these changes affect or resolve issue #38353 in any way?

@Hirmuolio
Copy link
Contributor Author

Most likely not.

@stale
Copy link

stale bot commented Mar 29, 2020

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.

@stale stale bot added the stale Closed for lack of activity, but still valid. label Mar 29, 2020
@stale stale bot removed the stale Closed for lack of activity, but still valid. label Apr 3, 2020
@Hirmuolio Hirmuolio closed this Apr 9, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants