-
Notifications
You must be signed in to change notification settings - Fork 4.3k
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
move has_rotten_away from map to item #38022
Conversation
035d510
to
a8964cf
Compare
Also now that I look at this. The reason why items in freezer sometimes rot away may be due to the |
Acutally I now think that Just check The original idea was probably to process food items once when they are loaded and after that limit how often they are processed with |
right, that's why i removed it from map and moved it to item... i'm having a hard time following what you're saying though. maybe you could follow up this pr to do what you said? |
Currently this seems to happen:
Then on the next turn the item is procesed normally and So we could just remove that part and do:
|
a8964cf
to
50ea6e9
Compare
Summary
SUMMARY: Infrastructure "move has_rotten_away() from map to item"
Purpose of change
This function really shouldn't have been in map. there was literally no reason for it. when i moved it to item, it didn't use any functions or variables from map at all! The main reason i'm moving it is because of the item contents refactor i'm working on. map really shouldn't be accessing item contents directly.
Describe the solution
move the function to the item scope. this changes the parameter to just
const tripoint &pos
moved to item.cpp. it was only used in one place so there wasn't any extra cleanup.Testing
compiled.