Don't sync stack greater than 1 for locked item stack (byte overflow)

This commit is contained in:
Justin Vitale 2020-07-09 17:17:14 +10:00
parent da8875de59
commit f7f2903e39

View file

@ -432,7 +432,9 @@ public class StorageUnitBaseBlockEntity extends MachineBaseBlockEntity implement
}
// Only set lockedItem in response to user input
lockedItemStack = value ? getStoredStack().copy() : ItemStack.EMPTY;
ItemStack stack = getStoredStack().copy();
stack.setCount(1);
lockedItemStack = value ? stack : ItemStack.EMPTY;
syncWithAll();
}