From 70be90e1686ca510c4bba0fa9d4d368f753f7a8a Mon Sep 17 00:00:00 2001 From: md_5 Date: Sun, 16 Jul 2017 11:03:19 +1000 Subject: [PATCH] SPIGOT-3425: Correct slot type calculation --- .../org/bukkit/craftbukkit/inventory/CraftInventoryView.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main/java/org/bukkit/craftbukkit/inventory/CraftInventoryView.java b/src/main/java/org/bukkit/craftbukkit/inventory/CraftInventoryView.java index 8ca0ccc5f8..dadfce6e6e 100644 --- a/src/main/java/org/bukkit/craftbukkit/inventory/CraftInventoryView.java +++ b/src/main/java/org/bukkit/craftbukkit/inventory/CraftInventoryView.java @@ -133,7 +133,7 @@ public class CraftInventoryView extends InventoryView { } else if (slot > 35) { type = SlotType.QUICKBAR; } - } else if (slot >= (inventory.countSlots() - 9)) { + } else if (slot >= (inventory.countSlots() - (9 + 4 + 1))) { // Quickbar, Armor, Offhand type = SlotType.QUICKBAR; } }