2013-03-20 22:54:12 +01:00
|
|
|
From 3c8e332b0453faec191720e8a005918d5e6d3b33 Mon Sep 17 00:00:00 2001
|
2013-03-01 23:25:48 +01:00
|
|
|
From: EdGruberman <ed@rjump.com>
|
|
|
|
Date: Thu, 21 Feb 2013 14:22:09 -0700
|
|
|
|
Subject: [PATCH] Identify outside slot independent of inventory type; Fixes
|
|
|
|
BUKKIT-2768
|
|
|
|
|
|
|
|
---
|
|
|
|
src/main/java/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 6ffc73d..1c7934d 100644
|
|
|
|
--- a/src/main/java/org/bukkit/craftbukkit/inventory/CraftInventoryView.java
|
|
|
|
+++ b/src/main/java/org/bukkit/craftbukkit/inventory/CraftInventoryView.java
|
|
|
|
@@ -75,7 +75,7 @@ public class CraftInventoryView extends InventoryView {
|
|
|
|
|
|
|
|
public static SlotType getSlotType(InventoryView inventory, int slot) {
|
|
|
|
SlotType type = SlotType.CONTAINER;
|
|
|
|
- if (slot < inventory.getTopInventory().getSize()) {
|
|
|
|
+ if (slot >= 0 && slot < inventory.getTopInventory().getSize()) {
|
|
|
|
switch(inventory.getType()) {
|
|
|
|
case FURNACE:
|
|
|
|
if (slot == 2) {
|
|
|
|
--
|
2013-03-20 22:54:12 +01:00
|
|
|
1.8.2
|
2013-03-01 23:25:48 +01:00
|
|
|
|