From 764f8a84469d4d63861035aa3aa78f0ecd50d0c2 Mon Sep 17 00:00:00 2001 From: 502647092 Date: Sun, 17 Jan 2016 08:39:10 +0800 Subject: [PATCH] =?UTF-8?q?=E8=87=AA=E5=8A=A8=E5=88=A4=E6=96=AD=E6=98=AF?= =?UTF-8?q?=E5=90=A6=E5=90=AF=E7=94=A8=E8=99=9A=E6=8B=9F=E6=82=AC=E6=B5=AE?= =?UTF-8?q?=E7=89=A9...?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: 502647092 --- .../org/maxgamer/QuickShop/Config/ConfigManager.java | 2 +- src/main/java/org/maxgamer/QuickShop/QuickShop.java | 9 --------- src/main/java/org/maxgamer/QuickShop/Shop/FakeItem.java | 5 ++--- 3 files changed, 3 insertions(+), 13 deletions(-) diff --git a/src/main/java/org/maxgamer/QuickShop/Config/ConfigManager.java b/src/main/java/org/maxgamer/QuickShop/Config/ConfigManager.java index 63f4cb1..7404a11 100644 --- a/src/main/java/org/maxgamer/QuickShop/Config/ConfigManager.java +++ b/src/main/java/org/maxgamer/QuickShop/Config/ConfigManager.java @@ -91,7 +91,7 @@ public class ConfigManager { fakeItem = true; } catch (final Error | Exception e) { plugin.getLogger().warning("+========================================="); - plugin.getLogger().warning("| 警告: 虚拟物品启动失败 使用原版悬浮物品..."); + plugin.getLogger().warning("| 警告: 启动虚拟物品失败 使用原版悬浮物品..."); plugin.getLogger().warning("+========================================="); } } diff --git a/src/main/java/org/maxgamer/QuickShop/QuickShop.java b/src/main/java/org/maxgamer/QuickShop/QuickShop.java index 71777da..05a5a4f 100644 --- a/src/main/java/org/maxgamer/QuickShop/QuickShop.java +++ b/src/main/java/org/maxgamer/QuickShop/QuickShop.java @@ -43,7 +43,6 @@ import org.maxgamer.QuickShop.Listeners.ProtectListener; import org.maxgamer.QuickShop.Listeners.WorldListener; import org.maxgamer.QuickShop.Listeners.WowSuchCleanerListener; import org.maxgamer.QuickShop.Shop.ContainerShop; -import org.maxgamer.QuickShop.Shop.FakeItem; import org.maxgamer.QuickShop.Shop.Shop; import org.maxgamer.QuickShop.Shop.ShopManager; import org.maxgamer.QuickShop.Shop.ShopType; @@ -296,14 +295,6 @@ public class QuickShop extends JavaPlugin { // Create the shop manager. configManager = new ConfigManager(this); shopManager = new ShopManager(this); - if (configManager.isFakeItem()) { - if (!FakeItem.isRegistered()) { - try { - FakeItem.register(this); - } catch (final Exception e) { - } - } - } if (configManager.isLogAction()) { // Logger Handler this.logWatcher = new LogWatcher(this, new File(this.getDataFolder(), "qs.log")); diff --git a/src/main/java/org/maxgamer/QuickShop/Shop/FakeItem.java b/src/main/java/org/maxgamer/QuickShop/Shop/FakeItem.java index a2f3d8d..48293d1 100644 --- a/src/main/java/org/maxgamer/QuickShop/Shop/FakeItem.java +++ b/src/main/java/org/maxgamer/QuickShop/Shop/FakeItem.java @@ -55,10 +55,10 @@ public class FakeItem implements DisplayItem { pm.enablePlugin(p); } if (!p.isEnabled()) { - throw new IllegalStateException("The ProtocolLib enable Failed."); + throw new IllegalStateException("前置插件ProtocolLib启动失败 请检查版本."); } } else { - throw new IllegalStateException("The Server Not Found ProtocolLib."); + throw new IllegalStateException("服务器未找到前置插件ProtocolLib."); } final PacketAdapter chunkPacketListener = new PacketAdapter(plugin, PacketType.Play.Server.MAP_CHUNK) { @Override @@ -102,7 +102,6 @@ public class FakeItem implements DisplayItem { } } }; - ProtocolLibrary.getProtocolManager().addPacketListener(chunkPacketListener); ProtocolLibrary.getProtocolManager().addPacketListener(chunkBulkPacketListener); registered = true;