From 0284355c87385bd4e73537704abc23726220e870 Mon Sep 17 00:00:00 2001 From: 502647092 Date: Fri, 15 Jan 2016 00:30:34 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E6=82=AC=E6=B5=AE=E7=89=A9?= =?UTF-8?q?=E6=B6=88=E5=A4=B1=E7=9A=84=E9=97=AE=E9=A2=98...?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: 502647092 --- src/main/java/org/maxgamer/QuickShop/Shop/ContainerShop.java | 5 ++++- src/main/java/org/maxgamer/QuickShop/Shop/FakeItem.java | 2 +- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/src/main/java/org/maxgamer/QuickShop/Shop/ContainerShop.java b/src/main/java/org/maxgamer/QuickShop/Shop/ContainerShop.java index 0055e03..b46fd27 100644 --- a/src/main/java/org/maxgamer/QuickShop/Shop/ContainerShop.java +++ b/src/main/java/org/maxgamer/QuickShop/Shop/ContainerShop.java @@ -689,7 +689,7 @@ public class ContainerShop implements Shop { this.getDisplayItem().spawn(); return; } - if (this.getDisplayItem() != null && displayItem instanceof NormalItem) { + if (this.getDisplayItem() != null) { if (!trans) { // We have a display item in a block... delete it this.getDisplayItem().remove(); this.displayItem = null; @@ -702,6 +702,9 @@ public class ContainerShop implements Shop { disItem.remove(); return; } + if (disItem instanceof FakeItem) { + return; + } if (disItem.getItem() == null) { disItem.removeDupe(); disItem.spawn(); diff --git a/src/main/java/org/maxgamer/QuickShop/Shop/FakeItem.java b/src/main/java/org/maxgamer/QuickShop/Shop/FakeItem.java index f8ae202..33c0c75 100644 --- a/src/main/java/org/maxgamer/QuickShop/Shop/FakeItem.java +++ b/src/main/java/org/maxgamer/QuickShop/Shop/FakeItem.java @@ -122,7 +122,7 @@ public class FakeItem implements DisplayItem { public FakeItem(final ContainerShop containerShop, final ItemStack item) { this.itemStack = item; - this.location = containerShop.getLocation().clone().add(0.5, 1, 0.5); + this.location = containerShop.getLocation().clone().add(0.5, 1.2, 0.5); this.eid = getFakeEntityId(); }