ssquadteam / Geyser-Anvil-Fix

This Plugin Aims to Fix issues with Custom Enchantments on GeyserMC
GNU General Public License v3.0
10 stars 0 forks source link

Request | Velocity Support #1

Closed gaRt3n closed 2 weeks ago

gaRt3n commented 2 months ago

Hey there, I've seen this plugin and thought it would be a great Idea to use it on my network too since i wanted to support bedrock players. Unfortunately it doesn't support Velocity :(

Velocity 3.3.0-SNAPSHOT

[12:18:43 ERROR]: Unable to load plugin plugins/Geyser-Anvil-Fix-1.0.0.jar
com.velocitypowered.api.plugin.InvalidPluginException: The plugin file Geyser-Anvil-Fix-1.0.0.jar appears to be a Bukkit or BungeeCord plugin. Velocity does not support Bukkit or BungeeCord plugins.
    at com.velocitypowered.proxy.plugin.loader.java.JavaPluginLoader.getSerializedPluginInfo(JavaPluginLoader.java:161) ~[velocity.jar:3.3.0-SNAPSHOT (git-4eb02c8d-b434)]
    at com.velocitypowered.proxy.plugin.loader.java.JavaPluginLoader.loadCandidate(JavaPluginLoader.java:62) ~[velocity.jar:3.3.0-SNAPSHOT (git-4eb02c8d-b434)]
    at com.velocitypowered.proxy.plugin.VelocityPluginManager.loadPlugins(VelocityPluginManager.java:96) ~[velocity.jar:3.3.0-SNAPSHOT (git-4eb02c8d-b434)]
    at com.velocitypowered.proxy.VelocityServer.loadPlugins(VelocityServer.java:369) ~[velocity.jar:3.3.0-SNAPSHOT (git-4eb02c8d-b434)]
    at com.velocitypowered.proxy.VelocityServer.start(VelocityServer.java:240) ~[velocity.jar:3.3.0-SNAPSHOT (git-4eb02c8d-b434)]
    at com.velocitypowered.proxy.Velocity.main(Velocity.java:71) ~[velocity.jar:3.3.0-SNAPSHOT (git-4eb02c8d-b434)]

With snap it can't work since snap Plugins will boot seperately

[12:23:47 WARN] [Snap]: Error loading plugin Geyser-Anvil-Fix
java.lang.NoClassDefFoundError: org/bukkit/event/Listener
    at java.base/java.lang.ClassLoader.defineClass1(Native Method) ~[?:?]
    at java.base/java.lang.ClassLoader.defineClass(ClassLoader.java:1027) ~[?:?]
    at java.base/java.security.SecureClassLoader.defineClass(SecureClassLoader.java:150) ~[?:?]
    at net.md_5.bungee.api.plugin.PluginClassloader.findClass(PluginClassloader.java:167) ~[?:?]
    at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:593) ~[?:?]
    at net.md_5.bungee.api.plugin.PluginClassloader.loadClass0(PluginClassloader.java:83) ~[?:?]
    at net.md_5.bungee.api.plugin.PluginClassloader.loadClass(PluginClassloader.java:78) ~[?:?]
    at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:526) ~[?:?]
    at net.md_5.bungee.api.plugin.PluginManager.enablePlugin(PluginManager.java:395) ~[?:?]
    at net.md_5.bungee.api.plugin.PluginManager.loadPlugins(PluginManager.java:301) ~[?:?]
    at de.themoep.snap.SnapBungeeAdapter.loadPlugins(SnapBungeeAdapter.java:143) ~[?:?]
    at de.themoep.snap.Snap.onProxyInitialization(Snap.java:73) ~[?:?]
    at de.themoep.snap.Lmbda$35.execute(Unknown Source) ~[?:?]
    at com.velocitypowered.proxy.event.UntargetedEventHandler$VoidHandler.lambda$buildHandler$0(UntargetedEventHandler.java:56) ~[velocity.jar:3.3.0-SNAPSHOT (git-4eb02c8d-b434)]
    at com.velocitypowered.proxy.event.VelocityEventManager.fire(VelocityEventManager.java:598) ~[velocity.jar:3.3.0-SNAPSHOT (git-4eb02c8d-b434)]
    at com.velocitypowered.proxy.event.VelocityEventManager.lambda$fire$5(VelocityEventManager.java:479) ~[velocity.jar:3.3.0-SNAPSHOT (git-4eb02c8d-b434)]
    at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1144) ~[?:?]
    at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:642) ~[?:?]
    at java.base/java.lang.Thread.run(Thread.java:1583) [?:?]
Caused by: java.lang.ClassNotFoundException: org.bukkit.event.Listener
    at net.md_5.bungee.api.plugin.PluginClassloader.loadClass0(PluginClassloader.java:100) ~[?:?]
    at net.md_5.bungee.api.plugin.PluginClassloader.loadClass(PluginClassloader.java:78) ~[?:?]
    at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:526) ~[?:?]
    ... 19 more
ssquadteam commented 2 months ago

Use the Plugin only on the Backend / Spigot server. And then follow these steps-

  1. Install Geyser on BungeeCord / Velocity
  2. Install floodgate on servers behind spigot and bungeecord or velocity.
  3. Install this plugin on the Spigot Servers behind the Proxy alongside ProtocolLib
  4. Run servers to generate files/directories
  5. Move "GeyserAnvilFix-Mapping.json" (Located in this plugin's folder) to Geyser's "custom-mappings" folder
  6. Move "GeyserAnvilFix-Pack.mcpack" (same place) to Geyser's "packs" folder

Note- Make sure the "key.pem" generated in floodgate plugin directory is the EXACT same on both the Spigot & Bungeecord Servers.