From 6fc06a620ff3094601b15ed7474f1f477e6aaf66 Mon Sep 17 00:00:00 2001 From: DBotThePony Date: Mon, 21 Aug 2023 11:08:39 +0700 Subject: [PATCH] Call setByPlayer instead of set on slots when quickmoving --- src/main/kotlin/ru/dbotthepony/mc/otm/menu/MatteryMenu.kt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/main/kotlin/ru/dbotthepony/mc/otm/menu/MatteryMenu.kt b/src/main/kotlin/ru/dbotthepony/mc/otm/menu/MatteryMenu.kt index 66f71ec48..e3299f78e 100644 --- a/src/main/kotlin/ru/dbotthepony/mc/otm/menu/MatteryMenu.kt +++ b/src/main/kotlin/ru/dbotthepony/mc/otm/menu/MatteryMenu.kt @@ -606,7 +606,7 @@ abstract class MatteryMenu( val copy = source.item.copy() if (remainder.isEmpty) { - source.set(ItemStack.EMPTY) + source.setByPlayer(ItemStack.EMPTY) source.onTake(player, copy) } else { copy.count = source.item.count - remainder.count @@ -666,7 +666,7 @@ abstract class MatteryMenu( val newCount = copy.count.coerceAtMost(limit) if (!simulate) { - slot.set(copy.copy().also { it.count = newCount }) + slot.setByPlayer(copy.copy().also { it.count = newCount }) slot.setChanged() }