From b597615a662a8939a2f1177bc0f57dd070679b87 Mon Sep 17 00:00:00 2001 From: Ghost_chu <2908803755@qq.com> Date: Fri, 17 Jan 2020 21:49:56 +0800 Subject: [PATCH] Push to build Former-commit-id: 9c14b01474e1aec2d43201bc1a72f831a8e09c1e --- .../java/org/maxgamer/quickshop/Shop/ShopManager.java | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/src/main/java/org/maxgamer/quickshop/Shop/ShopManager.java b/src/main/java/org/maxgamer/quickshop/Shop/ShopManager.java index c815981f8..db0f64652 100644 --- a/src/main/java/org/maxgamer/quickshop/Shop/ShopManager.java +++ b/src/main/java/org/maxgamer/quickshop/Shop/ShopManager.java @@ -447,6 +447,10 @@ public class ShopManager { p.sendMessage("Error: Economy system not loaded, type /qs main command to get details."); return; } + if(!plugin.getIntegrationHelper().callIntegrationsCanTrade(p,info.getLocation())){ + Util.debugLog("Cancel by integrations."); + return; + } Economy eco = plugin.getEconomy(); // Get the shop they interacted with @@ -679,6 +683,11 @@ public class ShopManager { } ShopCreateEvent ssShopCreateEvent = new ShopCreateEvent(shop, player); if (Util.fireCancellableEvent(ssShopCreateEvent)) { + Util.debugLog("Cancelled by plugin"); + return; + } + if(!plugin.getIntegrationHelper().callIntegrationsCanCreate(player,info.getLocation())){ + Util.debugLog("Cancelled by integrations"); return; } Location loc = shop.getLocation();