diff --git a/proxy/src/main/java/com/glyart/authmevelocity/proxy/AuthMeVelocityPlugin.java b/proxy/src/main/java/com/glyart/authmevelocity/proxy/AuthMeVelocityPlugin.java index 8841c20..4438b55 100644 --- a/proxy/src/main/java/com/glyart/authmevelocity/proxy/AuthMeVelocityPlugin.java +++ b/proxy/src/main/java/com/glyart/authmevelocity/proxy/AuthMeVelocityPlugin.java @@ -37,7 +37,9 @@ public class AuthMeVelocityPlugin { new LegacyChannelIdentifier("authmevelocity:main"), MinecraftChannelIdentifier.create("authmevelocity", "main")); proxy.getEventManager().register(this, new ProxyListener(proxy, logger)); - proxy.getEventManager().register(this, new FastLoginListener(proxy)); + if(proxy.getPluginManager().getPlugin("fastlogin").isPresent()){ + proxy.getEventManager().register(this, new FastLoginListener(proxy)); + } AuthMeConfig.defaultConfig(); logger.info("-- AuthMeVelocity enabled --"); logger.info("AuthServers: " + config.getList("authservers")); diff --git a/proxy/src/main/resources/velocity-plugin.json b/proxy/src/main/resources/velocity-plugin.json index 7930227..a537d3e 100644 --- a/proxy/src/main/resources/velocity-plugin.json +++ b/proxy/src/main/resources/velocity-plugin.json @@ -5,6 +5,11 @@ "url":"https://github.com/4drian3d/AuthMeVelocity", "description":"This plugin adds the support for AuthMeReloaded to Velocity.", "authors":["xQuickGlare"], - "dependencies":[], + "dependencies":[ + { + "id":"fastlogin", + "optional":true + } + ], "main":"com.glyart.authmevelocity.proxy.AuthMeVelocityPlugin" }