MyPet v3.12 cannot work on 1.20.1
shuiqing2046 opened this issue · 4 comments
[01:12:05 ERROR]: Error occurred while enabling MyPet v3.12 (Is it up to date?) java.lang.RuntimeException: failed to load a class at de.Keyle.MyPet.api.util.ReflectionUtil.getClass(ReflectionUtil.java:47) ~[MyPet-3.12-SNAPSHOT-B1743.jar:?] at de.Keyle.MyPet.compat.v1_20_R1.entity.EntityRegistry.registerEntity(EntityRegistry.java:83) ~[MyPet-3.12-SNAPSHOT-B1743.jar:?] at de.Keyle.MyPet.compat.v1_20_R1.entity.EntityRegistry.registerEntityTypes(EntityRegistry.java:143) ~[MyPet-3.12-SNAPSHOT-B1743.jar:?] at de.Keyle.MyPet.MyPetPlugin.onEnable(MyPetPlugin.java:195) ~[MyPet-3.12-SNAPSHOT-B1743.jar:?] at org.bukkit.plugin.java.JavaPlugin.setEnabled(JavaPlugin.java:281) ~[purpur-api-1.20.1-R0.1-SNAPSHOT.jar:?] at io.papermc.paper.plugin.manager.PaperPluginInstanceManager.enablePlugin(PaperPluginInstanceManager.java:189) ~[purpur-1.20.1.jar:git-Purpur-2035] at io.papermc.paper.plugin.manager.PaperPluginManagerImpl.enablePlugin(PaperPluginManagerImpl.java:104) ~[purpur-1.20.1.jar:git-Purpur-2035] at org.bukkit.plugin.SimplePluginManager.enablePlugin(SimplePluginManager.java:507) ~[purpur-api-1.20.1-R0.1-SNAPSHOT.jar:?] at org.bukkit.craftbukkit.v1_20_R1.CraftServer.enablePlugin(CraftServer.java:654) ~[purpur-1.20.1.jar:git-Purpur-2035] at org.bukkit.craftbukkit.v1_20_R1.CraftServer.enablePlugins(CraftServer.java:565) ~[purpur-1.20.1.jar:git-Purpur-2035] at net.minecraft.server.MinecraftServer.loadWorld0(MinecraftServer.java:641) ~[purpur-1.20.1.jar:git-Purpur-2035] at net.minecraft.server.MinecraftServer.loadLevel(MinecraftServer.java:440) ~[purpur-1.20.1.jar:git-Purpur-2035] at net.minecraft.server.dedicated.DedicatedServer.initServer(DedicatedServer.java:345) ~[purpur-1.20.1.jar:git-Purpur-2035] at net.minecraft.server.MinecraftServer.runServer(MinecraftServer.java:1117) ~[purpur-1.20.1.jar:git-Purpur-2035] at net.minecraft.server.MinecraftServer.lambda$spin$0(MinecraftServer.java:323) ~[purpur-1.20.1.jar:git-Purpur-2035] at java.lang.Thread.run(Thread.java:1623) ~[?:?] Caused by: java.lang.IncompatibleClassChangeError: class de.Keyle.MyPet.compat.v1_20_R1.entity.CraftMyPet overrides final method org.bukkit.craftbukkit.v1_20_R1.entity.CraftEntity.getType()Lorg/bukkit/entity/EntityType; at java.lang.ClassLoader.defineClass1(Native Method) ~[?:?] at java.lang.ClassLoader.defineClass(ClassLoader.java:1013) ~[?:?] at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:150) ~[?:?] at org.bukkit.plugin.java.PluginClassLoader.findClass(PluginClassLoader.java:232) ~[purpur-api-1.20.1-R0.1-SNAPSHOT.jar:?] at java.lang.ClassLoader.loadClass(ClassLoader.java:588) ~[?:?] at org.bukkit.plugin.java.PluginClassLoader.loadClass0(PluginClassLoader.java:157) ~[purpur-api-1.20.1-R0.1-SNAPSHOT.jar:?] at org.bukkit.plugin.java.PluginClassLoader.loadClass(PluginClassLoader.java:152) ~[purpur-api-1.20.1-R0.1-SNAPSHOT.jar:?] at java.lang.ClassLoader.loadClass(ClassLoader.java:521) ~[?:?] at java.lang.Class.forName0(Native Method) ~[?:?] at java.lang.Class.forName(Class.java:391) ~[?:?] at java.lang.Class.forName(Class.java:382) ~[?:?] at de.Keyle.MyPet.api.util.ReflectionUtil.getClass(ReflectionUtil.java:45) ~[MyPet-3.12-SNAPSHOT-B1743.jar:?] ... 15 more [01:12:05 INFO]: [de.Keyle.MyPet.MyPetPlugin] [MyPet] Disabling MyPet v3.12
Known issue - Spigot decided to make a method final that hasn't been for YEARS and that (in my humble opinion) shouldn't be
I'm currently thinking about the best way to address this
Did something happen between yesterday and today? It was working on 1.20.1 yesterday, and now it's not...
Spigot updated a new version and it caused MyPet not to work. Maybe you can use the previous version of spigot/paper/purpur to solve this problem temporarily.