Project Zomboid
Nested Containers
(Debug mode issues with) Nested Containers + Inventory Tetris
for some reason when you're using debug mode and launch the game with these 2 mods, you can't edit the stacksize of any particular items such as water bottle grid size, stack size, etc etc. You're still able to edit the container size from backpack and storage containers however.
< >
กำลังแสดง 1-5 จาก 5 ความเห็น
I looked into this and figured out why this is the case

"Nested Containers" completely hardcodes all the context menu entries and is with this probably somewhat incompatible with all other mods that interact with the context menu

There seems to be multiple ways to work around this

You are still able to edit the container size just because in "InventoryTetris" the container debug options are added after the call to `ItemGridUI.openItemContextMenu`
This is not done for the item debug options

It is possible to add the item debug options after the `ItemGridUI.openStackContextMenu`

File: `ItemGridUI_events.lua`
Line: 109

or just change `menu:addOptionOnTop` to `menu:addOption` in file `InventoryTetris_DevTool.lua`
Ok after futher investigation it does seem to be necessary to add
```
local item = ItemStack.getFrontItem(gridStack, self.grid.inventory)
TetrisDevTool.insertDebugOptions(menu, item)
```

to `ItemGridUI_events.lua` after line 109

effectively skipping whatever nested containers does to the context menu
Sioyth  [ผู้พัฒนา] 10 ก.ค. 2024 @ 7: 51am 
Sadly the way that PZ works I had to completely override the file ;_;
Sioyth  [ผู้พัฒนา] 10 ก.ค. 2024 @ 7: 51am 
โพสต์ดั้งเดิมโดย Tectin:
Ok after futher investigation it does seem to be necessary to add
```
local item = ItemStack.getFrontItem(gridStack, self.grid.inventory)
TetrisDevTool.insertDebugOptions(menu, item)
```

to `ItemGridUI_events.lua` after line 109

effectively skipping whatever nested containers does to the context menu

It seems this is on their end then ;/
im curious to the status of this: is this the workaround I should use or do i need to pick one or the other?
< >
กำลังแสดง 1-5 จาก 5 ความเห็น
ต่อหน้า: 1530 50