Reverted fix for issue where the player could be given stacks of 0 items as it causes other regressions

This commit is contained in:
Ceikry 2024-08-17 01:41:17 +00:00 committed by Ryan
parent 317b4e9b5c
commit 80cb2d9ba4

View file

@ -221,7 +221,7 @@ public class Container {
public boolean add(Item item, boolean fireListener, int preferredSlot) {
item = item.copy();
int maximum = getMaximumAdd(item);
if (maximum == 0 || (item.getDefinition().isStackable() && item.getAmount() == 0)) {
if (maximum == 0) {
return false;
}
if (preferredSlot > -1 && items[preferredSlot] != null) {