From d8bc645d5b85823bbe0569d4489769949cc03673 Mon Sep 17 00:00:00 2001 From: Ghost_chu <2908803755@qq.com> Date: Thu, 9 May 2019 22:38:38 +0800 Subject: [PATCH] Flush sign text when finished trading. Former-commit-id: 50045472194d236dfb082750094a48e9934fafdc [formerly 04c87dcb5432bf8152869d7c5ba6602549a172bf] Former-commit-id: 70c7ae76ce03c61df1ea782263baf469d86eda58 --- src/main/java/org/maxgamer/quickshop/Shop/ContainerShop.java | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/main/java/org/maxgamer/quickshop/Shop/ContainerShop.java b/src/main/java/org/maxgamer/quickshop/Shop/ContainerShop.java index 95d84cd26..f714d2148 100644 --- a/src/main/java/org/maxgamer/quickshop/Shop/ContainerShop.java +++ b/src/main/java/org/maxgamer/quickshop/Shop/ContainerShop.java @@ -382,6 +382,7 @@ public class ContainerShop implements Shop { } // We now have to update the chests inventory manually. this.getInventory().setContents(chestContents); + this.setSignText(); } for (int i = 0; i < floor.size(); i++) { p.getWorld().dropItem(p.getLocation(), floor.get(i)); @@ -416,6 +417,7 @@ public class ContainerShop implements Shop { } // Send the players new inventory to them p.getInventory().setContents(contents); + this.setSignText(); // This should not happen. if (amount > 0) { plugin.getLogger().log(Level.WARNING, "Could not take all items from a players inventory on purchase! " + p.getName() + ", missing: " + amount + ", item: " + this.getDataName() + "!"); @@ -444,6 +446,7 @@ public class ContainerShop implements Shop { } // Now update the players inventory. p.getInventory().setContents(playerContents); + this.setSignText(); } }