-
Notifications
You must be signed in to change notification settings - Fork 4.1k
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
Fix Codeblocks compilation and contained food #15190
Fix Codeblocks compilation and contained food #15190
Conversation
Could you add the consumption files to the src/CMakeLists.txt as well? |
Any idea on what the cause of the container-coloration bug was? I'm not sure what obscure change could've caused it. |
@@ -1870,9 +1871,11 @@ nc_color item::color_in_inventory() const | |||
switch( rating ) { | |||
case EDIBLE: | |||
case TOO_FULL: | |||
if( is_going_bad() ) { | |||
if( preserves ) { | |||
// Nothing, canned food won't rot |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Won't this prevent cans from showing perishable contents in their correct color?
If so, maybe we should add a new color for sealed perishables?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think it's acceptable for the color to not display if the container will prevent rot entirely. I've always disliked not being able to sort out my canned food from my genuine perishables at a glance.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Canned food only really becomes perishable when removed from the can.
In most cases there is no good reason to un-can anything except during eating.
The old coloring was misleading - it hid the fact that cans prevent rot.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm fine with that then.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Which sounds like what I first assumed the bug was, I assumed it was a positive change before realizing that it also applied to containers that didn't preserve rot.
Then again, if we made cans need a can opener and made open cans no longer preserve food, I guess that technically would render it a moot point. XP
Fix Codeblocks compilation and contained food
Closes #15173
Closes #15182
I didn't check the compilation part because I don't have a set up codeblocks installation, but so far just adding the new files to the file always worked.
Added missing perishable coloration to contained food.
Added a special case for canned food, since it doesn't rot even though its perishable.