Project Zomboid

Project Zomboid

[B42] Nested Containers
168 Comments
Q 30 Oct @ 7:36pm 
Hi: im not able to put any of my bags in any of my subsequent bags. Im running your container mod and inventory tetris mod. Is there any way to make these work together?
TheStorySmith 30 Oct @ 1:10am 
Do the nested containers reduce the weight of their items? Or is it like vanilla where the weight reduction is only for items directly equipped?
I really want a mod where there is a good reason to utilize containers within other containers (like using bags in a trunk, or a First Aid Kit in a backpack)

Is it possible to do and if so would it also apply to modded containers (I got Unofficial Fools) or only vanilla?
I'm trying to steal every gold bar in the game but they are 16 weight each
Nikku Miru  [author] 27 Oct @ 7:19am 
@Viatorem Don't have to apologize for that xD
I don't mind adding options at all since it'll make it just better for everyone so they can configure it to their liking.
Viatorem 27 Oct @ 7:03am 
sorry for being confusing haha, yeah i didnt remember nested containers working inside equipped containers, not a bug just bad memory lol. love the mod, but dont code options just for me if its annoying lol
Nikku Miru  [author] 27 Oct @ 2:11am 
Yeah that's no problem since I added a few options already
PANZER 27 Oct @ 1:20am 
Yes trunks and seats work right now, just an idea for a "vehicle" setting
Nikku Miru  [author] 27 Oct @ 12:36am 
@PANZER But trunks and seats work rn or am I wrong? maybe did something wrong then
Yeah I can add that, there's a different tag for trunk and trailer, will take a look at that!

You're welcome! :)
PANZER 26 Oct @ 4:59pm 
If it is possible, I would like it if the trunks and seats (everything within a vehicle) had normal mod functionality. If I had a bag within a bag on a seat (my main use case) I would like to see the second bag within the first.

I'm not sure if possible, but I would prefer it disabled for trailers. I dont know if the base code differentiates trailers from a normal vehicle trunk though. Perhaps there is a "trailer" tag?

Again, thank you for the work you put into this Nikku!
Nikku Miru  [author] 26 Oct @ 1:09pm 
@PANZER Could you please tell me how the vehicles as a toggle option should work exactly?
Just so I have a clear image of what option I should add, so far I added options to toggle nesting for player inventory or loot inventory and also filters to both so you can switch between everything / only pockets / only equipped and same for loot inventory so it's either everything or vehicle only basically seats / glove box.

But still need to polish it a bit.
Nikku Miru  [author] 26 Oct @ 1:39am 
@PANZER Thanks for letting me know, I will add some more options so everyone can configure it to their liking! :)
PANZER 25 Oct @ 11:53pm 
I personally like the nested functionality for character and in vehicles only. I tend to keep all containers in a single storage area and mid run it damn near impossible to find what I want when there is 50+ container icons to scroll through to find the parent container. the workaround for this is to set depth to one and cram them into a bag and put it in another bag, but to me this seems stupid.

I dunno how they tag car storage in the base code, but maybe its possible to add vehicles as a toggle option
Nikku Miru  [author] 25 Oct @ 8:24am 
Because a depth of 0 would basically disable the mod xD
Nikku Miru  [author] 25 Oct @ 8:23am 
@Viatorem Hmm maybe it's because of the thing I wrote under "Known Issues" but it sounds like you also basically don't want the functionality for the equipped one?

Could maybe add options like "Exclude Equipped" or "Exclude Player Inventory" so people can configure it more to their liking.
Viatorem 25 Oct @ 7:46am 
i set nest depth 2 to 1 hoping to not see my 2nd bag inside my worn one, but i still can, do i just need a new character? or is this the intended function.
if intended a depth 0 so i can only see them in the cardboard box slot would be much loved.
Nikku Miru  [author] 21 Oct @ 11:06pm 
You're welcome! :)
Please let me know when any issues appear with the new update.
PANZER 21 Oct @ 5:21pm 
Thank you Nikku for your hard work!
Nikku Miru  [author] 21 Oct @ 1:54pm 
I think I was finally able to fix the scrolling issue and also added a parent icon so you can quickly see where the nested container is inside of, it can be disabled in the options.
Nikku Miru  [author] 20 Oct @ 12:03pm 
Will need some more time to fix the scrolling issue... got it working for the floor but then it broke for everything else :steamfacepalm: but i'm getting closer! I think... xD
Night Fox 20 Oct @ 3:12am 
This mod allows you to overfill bags by filling the nested bags within them
Nikku Miru  [author] 10 Oct @ 5:31pm 
@Karbantms Thanks for letting me know! :)
I also worked a bit on it before and removed the virtualDom.
Karbantms 10 Oct @ 4:51pm 
Discussion post is messing up the spacing - I've sent a link with correct formatting under the comments - and here https://sharetext.io/753ccb48
Karbantms 10 Oct @ 4:38pm 
@Nikku Miru - I hope I don't intrude, but I made some changes to your mod for my own use. I threw out the VirtualDom and added the new containers directly into the vanilla list. It fixed the scrolling issue. It works on controller, CleanUI, and respects the nesting depth settings. The only side effect is that the nested containers are now sorted at the bottom of the list beneath equipped items in the player inventory and floor in the world inventory - not beneath their parent container.

This is a quick and dirty fix from someone who just came back home after a 16-hour shift and can barely keep his eyes open. I haven't tested it very thoroughly, but everything seems to work as it should, but you never know. Anyway, do with it as you wish. I just didn't want to keep it for myself if it could help somebody else. (Posting to discussion to not spam here)
MXMS GoodCat 10 Oct @ 1:39pm 
It works, thx
Smiley Face Killer 10 Oct @ 2:31am 
Ah yea fair enough, hope you enjoy it

(but don't forget about us lol)
Nikku Miru  [author] 10 Oct @ 2:25am 
@Smiley Face Killer Thanks for letting me know! I will prioritize fixing the scrolling first, since it also seems to be important for controller players. But I can't guarantee today because of BF6 😂
Smiley Face Killer 10 Oct @ 1:28am 
The whole scrolling being out of order messed me up bad
Came here to tell you it was an issue, but glad to see you know about it already

Also the backpack thing hasn't annoyed me personally (granted I'm not that far in yet)
Nikku Miru  [author] 8 Oct @ 3:10pm 
Please let me know if the equipped backpack issue I mentioned in the description is annoying.
It kinda adds a depth of 1 there since it's equipped.
Nikku Miru  [author] 8 Oct @ 2:59pm 
@kittysmuggler I'll see what I can do about that :)
Will probably have that added tomorrow.
kittysmugglers 8 Oct @ 2:55pm 
maybe a context menu option that hides certain containers from displaying on the side menu like sacks
yayie 8 Oct @ 2:52pm 
Thank you for the update <3
Nikku Miru  [author] 8 Oct @ 2:50pm 
Just pushed out a update that adds a nesting depth option and fixes the keyring issue.
@kittysmuggler what exactly do you mean by hide certain containers, can you give me an example please? :)
kittysmugglers 8 Oct @ 2:25pm 
yeah an option to hide certain containers would be great!
housels77 8 Oct @ 2:13pm 
First of all, congratulations to the creator of the mod, for me an essential mod on my list, but I have to play without it because now it detects the sacks or bags that are inside a backpack and fills up the sidebar making it difficult to manage.
Wansin 8 Oct @ 12:18pm 
@Nikku Miru Awesome!! No rush needed, i just wanted to know! Thanks! :D
Nikku Miru  [author] 8 Oct @ 12:05pm 
@Wansin Yeah sorry xD
Was planning to add mod settings to change different settings, also the nesting depth.
Will work on that! :)
Wansin 8 Oct @ 12:00pm 
Hi! Thank you for your work!! Just a suggestion, it will be possible to get back, to the first layer of nesting?? Via mod options or something, because it's a little crazy when you loot a lot of garbage bag or similar containers ( I need to setup my rain collectors xD). Thank you!! :D
Nikku Miru  [author] 8 Oct @ 10:55am 
@Leo Awesome, thanks for letting me know!
Knew that line was gonna make problems... should have a fix out shortly! :D
Leo 8 Oct @ 10:52am 
@Nikku Miru Thanks for the update, the infinite nesting seems to be working, but Keyrings are not being recognised as containers now

Testing method

Only Nested Containers mod
New game - Debug mode - add blank keys - Put keys onto keyring and keyring into nearest container
MXMS GoodCat 7 Oct @ 5:31pm 
Thx a lot, I will check it tomorrow
Nikku Miru  [author] 7 Oct @ 11:44am 
I was able to do infinite nesting now, seems like the game devs changed something that caused crashes in the past, also fixed the backpack issue! :)

Please test to your hearts content and give me some feedback!
Nikku Miru  [author] 7 Oct @ 8:52am 
Good news everyone! :lunar2019piginablanket:
It seems i'm able to nest multiple levels now, game devs probably changed something.
Will just need to rewrite the mod a bit :)
MXMS GoodCat 7 Oct @ 4:13am 
Duffel and Military vanilla's
Nikku Miru  [author] 7 Oct @ 2:46am 
@MXMS GoodCat Could you please tell me what backpack you used?
(also from which mod if not vanilla)
Nikku Miru  [author] 7 Oct @ 2:38am 
@MXMS GoodCat Interesting... I think it should work for the backpack that's equipped and not just in your inventory, I will also take a look at that, thx!
MXMS GoodCat 7 Oct @ 1:25am 
For example I weared backpack and placed sewing kit in it and I can't manipulate with loot inside sewing kit in my inventory. But when I placed sewing kit in container or vehicle it worked good.
Trenkos 6 Oct @ 6:45pm 
@Nikku Miru I'm having this issue with a "Water (Hydration Pack)"
Nikku Miru  [author] 6 Oct @ 2:35pm 
@MXMS GoodCat What bags exactly? Is it a mod? I will then check it :)
MXMS GoodCat 6 Oct @ 1:06pm 
Hello, it does not work with bags. With containers and vehicles works good. Any idea how to fix it?
Nikku Miru  [author] 1 Oct @ 11:29pm 
@dennis.ho182 What you actually can try is the following:
1. Unsubscribe from this mod
2. Check that "X:\SteamLibrary\steamapps\workshop\content\108600\3410947298" is deleted
3. Subscribe again
dennis.ho182 1 Oct @ 7:36pm 
@Nikku miru. hmm that's strange. No, i do not have 2 mods activated that do the same thing. maybe I'll just uninstall the one with the fix and see if that makes any difference.