GabrielOlvH / Industrial-Revolution

An Industrial mod made for Fabric.
Apache License 2.0
196 stars 58 forks source link

[BUG] Full energy items of different counts cannot be combined #430

Open NiChrosia opened 2 years ago

NiChrosia commented 2 years ago

Description:

Two stacks of items full of energy cannot be combined if they have differing quantities, because a stack with 2 items has double the energy in the NBT, forcing the user to combine them in powers of 2.

Steps to Reproduce:

  1. Take 3 batteries from the creative menu.
  2. Charge them all to max one by one
  3. Combine two into a stack
  4. Attempt to add the individual item to the stack of two
  5. Observe the bug

Solution:

Mixin to the method that handles stack combination to allow combining energy items with different energy values.

Technical Information: