Item bundling

A place where new features are announced and discussed. (Feature suggestions go in the suggestions topic.)
Post Reply
User avatar
Rias
DEV
Posts: 2024
Joined: Sun Sep 03, 2017 4:06 pm
Location: Wandering Temicotli

Item bundling

Post by Rias »

I'm pushing some changes live that will implement item bundling. This will go a long way to handling the clutter problem, as it will allow for identical items to be merged into a single item with a quantity counter, rather than tracking each item individually. It might be a little finicky at first.

Bundled items will show as, for example, (bundled:5) instead of (x5). Crafting, selling, burning fuel, etc. should all handle bundles just like regular items.

Bundle-able items placed on the ground or in a container will automatically bundle together with others if possible. Wen you GET a bundle of items, you get the entire bundle at once and hold it all in hand. If you're holding two bundle-able items (or two bundles) in each hand, use the BUNDLE command to combine them. The SPLIT command can be used to split a desired number off a bundle into a second bundle (or single item, if you SPLIT 1).

I've tried to consider every case, but there may be some issues where an entire "stack" of items is used up instead of just decrementing it by one. If this happens, please don't panic. Use the BUG command to report it and I'll handle it, including item replacement.

I'm going to start off by applying this to only some of the most populous item types, namely cloth, thread, and branches.
<Rias> PUT ON PANTS
<Fellborn> NO
User avatar
nobody
Posts: 501
Joined: Wed Jun 17, 2020 7:43 am
Contact:

Re: Item bundling

Post by nobody »

Could I request this for forage-able food items. I have so, so many berries.
User avatar
Rias
DEV
Posts: 2024
Joined: Sun Sep 03, 2017 4:06 pm
Location: Wandering Temicotli

Re: Item bundling

Post by Rias »

nobody wrote: Wed Jun 17, 2020 7:44 am Could I request this for forage-able food items. I have so, so many berries.
Food items aren't bundle-able because each individual one has to keep track of its number of bites and its freshness. Not to say it isn't possible with an update at some future point, it just won't work with the current implementation.
<Rias> PUT ON PANTS
<Fellborn> NO
User avatar
nobody
Posts: 501
Joined: Wed Jun 17, 2020 7:43 am
Contact:

Re: Item bundling

Post by nobody »

I have found that bundled thread doesn't function properly for suturing with one's own medical supplies (a skein of thread can be used to suture and produces a leftover thread item good for 4 additional uses, while a skin of thread (bundled: N) used to suture produces a leftover thread item that is bundled with the same number and good for 4 uses. After the four uses, the bundled leftover thread ceases to exist. I reported this in bug 2268 but wanted to add more detail).

Additionally, I have not tested (and do not particularly have any desire to test) whether steal functions correctly with bundled items (IE does it steal a skein of thread, or all the thread), but it may be worth checking if anyone has the inclination.
User avatar
Rias
DEV
Posts: 2024
Joined: Sun Sep 03, 2017 4:06 pm
Location: Wandering Temicotli

Re: Item bundling

Post by Rias »

Good call on both of those, Nobody. Both have been addressed.
<Rias> PUT ON PANTS
<Fellborn> NO
User avatar
Rias
DEV
Posts: 2024
Joined: Sun Sep 03, 2017 4:06 pm
Location: Wandering Temicotli

Re: Item bundling

Post by Rias »

Additionaly, the SPLIT command has been updated so you now have to specify a target. The point being that you can now split bundles of items that aren't in your hands. So split that ginormous bundle on the ground or in your shed or wherever that was previously too heavy to lift. Be free!

Type SPLIT on its own for the new syntax.
<Rias> PUT ON PANTS
<Fellborn> NO
User avatar
Irylia
Posts: 274
Joined: Tue Apr 30, 2019 5:20 pm

Re: Item bundling

Post by Irylia »

Can cordage and fibers get added to bundling?
User avatar
nobody
Posts: 501
Joined: Wed Jun 17, 2020 7:43 am
Contact:

Re: Item bundling

Post by nobody »

Arbitrary and lowest possible priority request: could we have dice bundle so that when you've a bundle of dice and toss them it rolls all the dice in the bundle?
User avatar
nobody
Posts: 501
Joined: Wed Jun 17, 2020 7:43 am
Contact:

Re: Item bundling

Post by nobody »

I've discovered a few more quirks of bundling that I thought would be worth mentioning here:
  • Damaged branches, when bundled, retain only the damage tag of whichever branch is used as the base (I think). So bundling a heavily damaged medium pine branch with a well-worn medium pine branch will produce a bundle of two medium pine branches that are either well-worn or heavily damaged, splitting reveals the other tag was lost. There probably isn't a lot of merit in the branch restoration business though, so it's probably a non-issue.
  • Bundled branches when chopped without unbundling only produce 2 branches rather than splitting 1 off the bundle and splitting that branch into 2. IE chopping a medium pine branch (bundled: 40) destroys the medium branch bundle and produces a small pine branch (bundled: 2).
  • Building with bundled nails correctly identifies the counts of bundles, but will tend toward consuming whole bundles. IE If you build something that requires 8 nails, a single bundle of 8 nails will suffice and be used up, but a single bundle of 9+ will also get used up instead of just splitting 8 off the bundle and using those. Similarly if you have two bundles of 4 nails, it will correctly determine that you have enough and consume both of them. But if you have a bundle of 4 nails and a bundle of 5 nails, it will completely consume both.
Edit to add: Nix that middle one, it isn't destroying the whole bundles. Sorry!

Edit to add again: Annnnd I'm wrong about the last one too. The correct number of items are subtracted from the bundle. The constructed object merely mis-reports it's components as having been made from the whole bundle. e.g. It has the following minor components:
a skein of white sheep wool thread (bundled:3)
a handful of dry leaves (x3)
a small straight pine branch (bundled:186)
some deadwood kindling (x4)
Post Reply