diff options
author | Juuxel <6596629+Juuxel@users.noreply.github.com> | 2020-10-18 16:31:47 +0300 |
---|---|---|
committer | Juuxel <6596629+Juuxel@users.noreply.github.com> | 2020-10-18 16:35:42 +0300 |
commit | 7a0800c8a9201304583fed6ed0b5a4fd5e25e9f4 (patch) | |
tree | 6ccb877e8f96db7807c02d2f3c868e0c1490df9e | |
parent | da332633984ba3e3872c61a2d407cccd0fa08a56 (diff) | |
download | LibGui-7a0800c8a9201304583fed6ed0b5a4fd5e25e9f4.tar.gz LibGui-7a0800c8a9201304583fed6ed0b5a4fd5e25e9f4.tar.bz2 LibGui-7a0800c8a9201304583fed6ed0b5a4fd5e25e9f4.zip |
Fix #87
-rw-r--r-- | src/main/java/io/github/cottonmc/cotton/gui/SyncedGuiDescription.java | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/main/java/io/github/cottonmc/cotton/gui/SyncedGuiDescription.java b/src/main/java/io/github/cottonmc/cotton/gui/SyncedGuiDescription.java index fee04f1..4500d80 100644 --- a/src/main/java/io/github/cottonmc/cotton/gui/SyncedGuiDescription.java +++ b/src/main/java/io/github/cottonmc/cotton/gui/SyncedGuiDescription.java @@ -150,7 +150,7 @@ public class SyncedGuiDescription extends ScreenHandler implements GuiDescriptio /** WILL MODIFY toInsert! Returns true if anything was inserted. */ private boolean insertIntoExisting(ItemStack toInsert, Slot slot, PlayerEntity player) { ItemStack curSlotStack = slot.getStack(); - if (!curSlotStack.isEmpty() && canStacksCombine(toInsert, curSlotStack) && slot.canTakeItems(player)) { + if (!curSlotStack.isEmpty() && canStacksCombine(toInsert, curSlotStack) && slot.canInsert(toInsert)) { int combinedAmount = curSlotStack.getCount() + toInsert.getCount(); int maxAmount = Math.min(toInsert.getMaxCount(), slot.getMaxItemCount()); if (combinedAmount <= maxAmount) { |