Food stacking

Discussion in 'Gear and Items' started by drafu, Jul 31, 2016.

Tags:
  1. drafu

    drafu Orbital Explorer

    I know that this may have been discussed a lot of times, but still there is a suggestion to stack food.

    Currently it does not stack because of different rot-time, but my idea is to stack them bad-to-good, the first used items from stack is the nearest to its rot.

    The stack of 5 Canned food for example would look like that:
    1 - Canned Food - 5 mins to rot - Will be used first if stack is used
    2 - Canned Food - 50 mins to rot
    3 - Canned Food - 158 mins to rot
    4 - Canned Food - 235 mins to rot
    5 - Canned Food - 425 mins to rot - Last in stack
     
  2. sagenth

    sagenth Pangalactic Porcupine

    What are the stack size limits?
    What happens to the items when they start to actually rot? (assume your inventory is full)
    What happens when a friend gives you their food?

    -- These last three are rhetorical, since we would need to see the source code to know the answers. However they give an idea of *possible* reasons as to why food stacking has not been examined made possible.
    What is the performance cost of sorted inserts? (when you pick up an item it's rot time has to be examined, of course most of the time the item could be pushed to the back of the list; avoiding the word stack for a reason here)
    What is the performance cost of keeping track of ALL of these individual items? (since they each have a unique length of time left til they rot)
    What is the memory cost of allowing all these unique, time sensitive objects to be stacked?
     
  3. drafu

    drafu Orbital Explorer

    Assuming there is no need to carry thousands of food (that is just very unreasonable) stack limit of about 10 will be fair for both gameplay and performance cost.

    The full inventory can behave much like when you buy items with full inventory: it drops out.

    Last one is quite questionable because dropping out items with all their stack-info can be rather hard to code. But since it already works with one item, there must be a solution to carry info about multiple items.

    Food Stacker mod already stacks food and counts all the rot-times for food stacks, so it shouldn't be much a hit for the performance as well.
     
  4. Shydragon

    Shydragon Subatomic Cosmonaut

    I think that non stackable food is fine... for prepared food. When it comes to produce, it's really annoying to have half your inventory fill up when you harvest a single field of 9 pearlpeas to see if you can get that last seed for a nice round 10.

    I think that all produce should be filed under stackable cooking ingredients like wheat instead of non stackable food. That way you won't fill your whole inventory while farming, and it would also add more fair challenge since you wouldn't fill your hunger bar just by picking the naturally generated plants on a planet. Who eats raw potatoes and corn anyway?
     

Share This Page