GregTechCEu / GregTech-Modern

GregTech CE Unofficial for modern versions
GNU Lesser General Public License v3.0
290 stars 172 forks source link

Crates and drums don't stack when mined #2310

Open SylviBlossom opened 3 days ago

SylviBlossom commented 3 days ago

Checked for existing issues

Tested latest version

GregTech CEu Version

v1.4.6

Minecraft Version

1.20.1

Recipe Viewer Installed

EMI

Environment

Singleplayer

Cross-Mod Interaction

No

Other Installed Mods

EMI

Expected Behavior

Empty crates and drums stack with eachother

Actual Behavior

When mined, both crates and drums drop with useless NBT which prevents their stacking.

Steps to Reproduce

  1. Get a stack of empty drums/crates from any source other than mining one (e.g. crafting, item giver, machine GUI interaction)
  2. Place one in the world
  3. Break it and pick up the item, no longer stacking

Additional Information

In the case of drums, the tag is a minecraft:empty fluid of size 0, visually displayed with a "Fluid Stored: Air, 0 mB" tooltip vs no "Fluid Stored" tooltip by default. This useless NBT is removed when the drum is emptied any other way (machine GUI interaction / emptying by crafting). image In crates, this is just an empty tag, and is as far as I can tell only resolvable by dropping a stackable and non-stackable crate on the ground and weird minecraft behaviour ignores the empty tag when combining dropped item stacks. image

SylviBlossom commented 3 days ago

I also didn't notice this applies to non-empty drums as well, because the fluid Amount tag is an int after machine GUI interaction (left-clicking a fluid slot with a drum) but a long when mined (not sure if this would be fixed with the in-dev fluid changes) image