Storage Overhaul

Storage Overhaul

2M Downloads

Storage barrel attempts to drop stacked unstackable items

ChloeDawn opened this issue ยท 1 comments

commented

Bug description
Internally, the storage barrel is forcibly stacking unstackable items rather than expanding the inventory size, and then when broken externally, attempts to pass this "illegal" item stack to InventoryHelper, which results in unreliable behaviour of 1-3 item stacks of varying counts of unstackable item types.

Steps to reproduce the issue

  1. Place unstackable items in barrel
  2. Destroy block externally (explosion, AoE tool, etc)
  3. Block will drop "illegal" item stacks

Expected behavior
The block should drop each individual unstackable item, with no "illegal" counts merging them

Versions

  • Minecraft version: 1.16.5
  • Forge version: 36.0.22
  • Mod version: 1.16.5-1.0.0

Relevant code

InventoryHelper.spawnItemStack(worldIn, pos.getX(), pos.getY(), pos.getZ(), ((StorageBarrelTileEntity) tileentity).getBarrelContent());

Screenshots
Action performed with Thermal's Fluxsaw performing an AoE
Screenshot of items in barrel
Screenshot of items in inventory

commented

Thank you for reporting this issue. It should be fixed in the latest version.