Skip to content

Commit 34ab8a1

Browse files
committed
修复一个样板供应器bug,在发配超过Integer.MAX_VALUE的物品切换新格子时,供应器会复制物品
1 parent 6e08553 commit 34ab8a1

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

src/main/java/github/kasuminova/mmce/common/util/InfItemFluidHandler.java

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -295,7 +295,9 @@ public synchronized void appendItem(@Nonnull final ItemStack stack) {
295295
}
296296

297297
if (toAppend > 0) {
298-
itemStackList.add(stack.copy());
298+
var item = stack.copy();
299+
item.setCount(toAppend);
300+
itemStackList.add(item);
299301
if (onItemChanged != null) {
300302
onItemChanged.accept(itemStackList.size() - 1);
301303
}

0 commit comments

Comments
 (0)