mirror of
https://github.com/Minestom/Minestom.git
synced 2024-11-05 18:32:28 +01:00
Give InventoryClickEvent the proper inventory for drag clicks
Signed-off-by: TheMode <themode@outlook.fr>
This commit is contained in:
parent
e71c420fa8
commit
b9746a0574
@ -239,7 +239,7 @@ public final class InventoryClickProcessor {
|
||||
finalCursorAmount -= slotSize;
|
||||
}
|
||||
inv.setItemStack(s, slotItem);
|
||||
callClickEvent(player, inventory, s, ClickType.LEFT_DRAGGING, slotItem, cursor);
|
||||
callClickEvent(player, inv, s, ClickType.LEFT_DRAGGING, slotItem, cursor);
|
||||
}
|
||||
// Update the cursor
|
||||
clickResult.setCursor(stackingRule.apply(cursor, finalCursorAmount));
|
||||
@ -284,7 +284,7 @@ public final class InventoryClickProcessor {
|
||||
finalCursorAmount -= 1;
|
||||
}
|
||||
inv.setItemStack(s, slotItem);
|
||||
callClickEvent(player, inventory, s, ClickType.RIGHT_DRAGGING, slotItem, cursor);
|
||||
callClickEvent(player, inv, s, ClickType.RIGHT_DRAGGING, slotItem, cursor);
|
||||
}
|
||||
// Update the cursor
|
||||
clickResult.setCursor(stackingRule.apply(cursor, finalCursorAmount));
|
||||
|
Loading…
Reference in New Issue
Block a user