Change the method used to check for Paper

This commit is contained in:
libraryaddict 2019-11-10 22:54:32 +13:00
parent b591bb96f0
commit 5bb9eeac84

View File

@ -859,7 +859,12 @@ public class DisguiseUtilities {
}
public static void init(LibsDisguises disguises) {
runningPaper = Bukkit.getServer().getBukkitVersion().contains("Paper");
try {
runningPaper = Class.forName("com.destroystokyo.paper.VersionHistoryManager$VersionData") != null;
}
catch (Exception ex) {
}
GsonBuilder gsonBuilder = new GsonBuilder();
gsonBuilder.registerTypeAdapter(MetaIndex.class, new SerializerMetaIndex());