Skip to content

sealing containers that aren't 100% full #81781

Open
@dynst

Description

@dynst

Is your feature request related to a problem? Please describe.

Cataclysm-DDA/src/item.cpp

Lines 10212 to 10219 in c224235

bool item::seal()
{
if( is_container_full() ) {
return contents.seal_all_pockets();
} else {
return false;
}
}

This if statement added in #46359 means even if there's 480 ml of food in a 500 ml bag_plastic_small, it can't spawn sealed.

Solution you would like.

Allow containers to be sealed, but without reintroducing sealed nearly-empty bottles of bleach (when the number of charges is randomized). #45650 (comment)

Maybe sealing could be enabled for containers whose contents were determined nonrandomly, or if adding 1 more charge/item of the same type would overflow.

Describe alternatives you have considered.

No response

Additional context

#80955 (comment)

#81352

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions