1
0
mirror of https://e.coding.net/circlecloud/YumCore.git synced 2024-11-24 02:08:48 +00:00

feat: 包工具 非必须ProtocolLib

Signed-off-by: 502647092 <admin@yumc.pw>
This commit is contained in:
502647092 2017-01-19 21:23:55 +08:00
parent f7212b3767
commit 12b9192aa3
2 changed files with 7 additions and 6 deletions

View File

@ -52,7 +52,6 @@
<properties> <properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding> <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding> <project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
<env.GIT_COMMIT>开发版本</env.GIT_COMMIT>
<maven.compiler.source>1.7</maven.compiler.source> <maven.compiler.source>1.7</maven.compiler.source>
<maven.compiler.target>1.7</maven.compiler.target> <maven.compiler.target>1.7</maven.compiler.target>
</properties> </properties>

View File

@ -1,14 +1,16 @@
package pw.yumc.YumCore.plugin.protocollib; package pw.yumc.YumCore.plugin.protocollib;
import java.lang.reflect.InvocationTargetException;
import org.bukkit.Bukkit;
import org.bukkit.entity.Player;
import com.comphenix.protocol.PacketType; import com.comphenix.protocol.PacketType;
import com.comphenix.protocol.ProtocolLibrary; import com.comphenix.protocol.ProtocolLibrary;
import com.comphenix.protocol.ProtocolManager; import com.comphenix.protocol.ProtocolManager;
import com.comphenix.protocol.events.PacketContainer; import com.comphenix.protocol.events.PacketContainer;
import org.bukkit.Bukkit;
import org.bukkit.entity.Player;
import pw.yumc.YumCore.kit.PKit;
import java.lang.reflect.InvocationTargetException; import pw.yumc.YumCore.bukkit.Log;
/** /**
* ProtocolLib发包工具 * ProtocolLib发包工具
@ -22,7 +24,7 @@ public class PacketKit {
static { static {
if (!Bukkit.getPluginManager().isPluginEnabled("ProtocolLib")) { if (!Bukkit.getPluginManager().isPluginEnabled("ProtocolLib")) {
PKit.disable("未找到 ProtocolLib 插件 部分功能不可用..."); Log.w("未找到 ProtocolLib 插件 部分功能不可用...");
} else { } else {
ENABLE = true; ENABLE = true;
manager = ProtocolLibrary.getProtocolManager(); manager = ProtocolLibrary.getProtocolManager();