Plugin not working; NoSuchFieldError: COMMAND_BLOCK
JonnygamingTv opened this issue ยท 2 comments
It errors on load (start)
git-Paper-1618 (MC: 1.12.2)
so, could be that of course, but ye fyi, none of the versions work on it, and no config,
so probably because of it being paper, but yee who knows
[17:42:15] [Server thread/INFO]: [SerialKey] Enabling SerialKey v1.0.3[17:42:15] [Server thread/INFO]: [SerialKey] Enabling SerialKey v1.0.3[17:42:15] [Server thread/ERROR]: Error occurred while enabling SerialKey v1.0.3 (Is it up to date?)java.lang.NoSuchFieldError: COMMAND_BLOCK at fr.skyost.serialkey.bukkit.config.BukkitPluginConfig.<init>(BukkitPluginConfig.java:71) ~[?:?] at fr.skyost.serialkey.bukkit.SerialKey.onEnable(SerialKey.java:68) ~[?:?] at org.bukkit.plugin.java.JavaPlugin.setEnabled(JavaPlugin.java:264) ~[patched_1.12.2.jar:git-Paper-1618] at org.bukkit.plugin.java.JavaPluginLoader.enablePlugin(JavaPluginLoader.java:316) ~[patched_1.12.2.jar:git-Paper-1618] at org.bukkit.plugin.SimplePluginManager.enablePlugin(SimplePluginManager.java:405) ~[patched_1.12.2.jar:git-Paper-1618] at org.bukkit.craftbukkit.v1_12_R1.CraftServer.enablePlugin(CraftServer.java:395) ~[patched_1.12.2.jar:git-Paper-1618] at org.bukkit.craftbukkit.v1_12_R1.CraftServer.enablePlugins(CraftServer.java:344) ~[patched_1.12.2.jar:git-Paper-1618] at net.minecraft.server.v1_12_R1.MinecraftServer.t(MinecraftServer.java:442) ~[patched_1.12.2.jar:git-Paper-1618] at net.minecraft.server.v1_12_R1.MinecraftServer.l(MinecraftServer.java:403) ~[patched_1.12.2.jar:git-Paper-1618] at net.minecraft.server.v1_12_R1.MinecraftServer.a(MinecraftServer.java:341) ~[patched_1.12.2.jar:git-Paper-1618] at net.minecraft.server.v1_12_R1.DedicatedServer.init(DedicatedServer.java:289) ~[patched_1.12.2.jar:git-Paper-1618] at net.minecraft.server.v1_12_R1.MinecraftServer.run(MinecraftServer.java:616) ~[patched_1.12.2.jar:git-Paper-1618] at java.lang.Thread.run(Thread.java:748) [?:1.8.0_281][17:42:15] [Server thread/INFO]: [SerialKey] Disabling SerialKey v1.0.3[17:42:15] [Server thread/WARN]: java.lang.NullPointerException[17:42:15] [Server thread/WARN]: at fr.skyost.serialkey.bukkit.SerialKey.onDisable(SerialKey.java:128)[17:42:15] [Server thread/WARN]: at org.bukkit.plugin.java.JavaPlugin.setEnabled(JavaPlugin.java:266)[17:42:15] [Server thread/WARN]: at org.bukkit.plugin.java.JavaPluginLoader.disablePlugin(JavaPluginLoader.java:350)[17:42:15] [Server thread/WARN]: at org.bukkit.plugin.SimplePluginManager.disablePlugin(SimplePluginManager.java:437)[17:42:15] [Server thread/WARN]: at org.bukkit.plugin.java.JavaPluginLoader.enablePlugin(JavaPluginLoader.java:320)[17:42:15] [Server thread/WARN]: at org.bukkit.plugin.SimplePluginManager.enablePlugin(SimplePluginManager.java:405)[17:42:15] [Server thread/WARN]: at org.bukkit.craftbukkit.v1_12_R1.CraftServer.enablePlugin(CraftServer.java:395)[17:42:15] [Server thread/WARN]: at org.bukkit.craftbukkit.v1_12_R1.CraftServer.enablePlugins(CraftServer.java:344)[17:42:15] [Server thread/WARN]: at net.minecraft.server.v1_12_R1.MinecraftServer.t(MinecraftServer.java:442)[17:42:15] [Server thread/WARN]: at net.minecraft.server.v1_12_R1.MinecraftServer.l(MinecraftServer.java:403)[17:42:15] [Server thread/WARN]: at net.minecraft.server.v1_12_R1.MinecraftServer.a(MinecraftServer.java:341)[17:42:15] [Server thread/WARN]: at net.minecraft.server.v1_12_R1.DedicatedServer.init(DedicatedServer.java:289)[17:42:15] [Server thread/WARN]: at net.minecraft.server.v1_12_R1.MinecraftServer.run(MinecraftServer.java:616)[17:42:15] [Server thread/WARN]: at java.lang.Thread.run(Thread.java:748)
probably due to
shapeMaterials["C"] = Material.COMMAND_BLOCK.name
where .name would crash it, should be inside a try{}catch{} or like it sets Material.COMMAND_BLOCK = Material.COMMAND that makes that part crash-proof ;)
Everything would be fine, but why was it necessary to port the code to Kotlin? Well, why, when the author abandons the plugin and when someone else wants to continue it, you need to turn it all over in your own way? Why not do everything in one language? Over each plugin you need to rack your brains every time!
although this isn't as critical as it may seem, since version v0.3 works, but the tags on https://dev.bukkit.org/projects/serial-key would be wrong, possibly, maybe papers fault :)