From fc35d000e4176844ad3b9c2ed4fb2a901d2718ed Mon Sep 17 00:00:00 2001 From: feildmaster Date: Tue, 14 Aug 2012 18:28:00 -0500 Subject: [PATCH] Use correct SlotType's for merchants. Fixes BUKKIT-2257 --- .../bukkit/craftbukkit/inventory/CraftInventoryView.java | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/main/java/org/bukkit/craftbukkit/inventory/CraftInventoryView.java b/src/main/java/org/bukkit/craftbukkit/inventory/CraftInventoryView.java index 95eb616381..61e83a84d2 100644 --- a/src/main/java/org/bukkit/craftbukkit/inventory/CraftInventoryView.java +++ b/src/main/java/org/bukkit/craftbukkit/inventory/CraftInventoryView.java @@ -102,6 +102,13 @@ public class CraftInventoryView extends InventoryView { type = SlotType.CRAFTING; } break; + case MERCHANT: + if (slot == 2) { + type = SlotType.RESULT; + } else { + type = SlotType.CRAFTING; + } + break; default: // Nothing to do, it's a CONTAINER slot }