bergerhealer / BKCommonLib

An extensive library used in bergerhealer's plugins
Other
181 stars 45 forks source link

Initializing Legacy Material Support. Unless you have legacy plugins and/or data this is a bug! #163

Closed fklscc closed 7 months ago

fklscc commented 7 months ago
BkCommonLib version: 1.20.4-v4
Spigot version: Paper-496 (MC: 1.20.4)

Problem or bug:

`[BKCommonLib] Loading server plugin BKCommonLib v1.20.4-v4 [01:10:29] [Server thread/WARN]: [org.bukkit.craftbukkit.v1_20_R3.legacy.CraftLegacy] Initializing Legacy Material Support. Unless you have legacy plugins and/or data this is a bug!

[01:10:29] [Server thread/WARN]: at org.bukkit.craftbukkit.v1_20_R3.legacy.CraftLegacy.(CraftLegacy.java:261) [01:10:29] [Server thread/WARN]: at org.bukkit.craftbukkit.v1_20_R3.util.CraftMagicNumbers.getItem(CraftMagicNumbers.java:191) [01:10:29] [Server thread/WARN]: at com.bergerkiller.mountiplex.reflection.util.fast.GeneratedCodeInvoker$mpldefgen44906a57.newInstance(Unknown Source) [01:10:29] [Server thread/WARN]: at com.bergerkiller.mountiplex.reflection.util.fast.GeneratedCodeInvoker$mpldefgen44906a57.invoke(Unknown Source) [01:10:29] [Server thread/WARN]: at BKCommonLib-1.20.4-v4-1691.jar//com.bergerkiller.mountiplex.reflection.declarations.Template$StaticMethod$Converted.invoke(Template.java:1417) [01:10:29] [Server thread/WARN]: at BKCommonLib-1.20.4-v4-1691.jar//com.bergerkiller.generated.net.minecraft.world.item.ItemStackHandle.newInstance(ItemStackHandle.java:29) [01:10:29] [Server thread/WARN]: at BKCommonLib-1.20.4-v4-1691.jar//com.bergerkiller.bukkit.common.utils.RecipeUtil.(RecipeUtil.java:34) [01:10:29] [Server thread/WARN]: at java.base/java.lang.Class.forName0(Native Method) [01:10:29] [Server thread/WARN]: at java.base/java.lang.Class.forName(Class.java:421) [01:10:29] [Server thread/WARN]: at java.base/java.lang.Class.forName(Class.java:412) [01:10:29] [Server thread/WARN]: at BKCommonLib-1.20.4-v4-1691.jar//com.bergerkiller.bukkit.common.Common.loadClasses(Common.java:171) [01:10:29] [Server thread/WARN]: at BKCommonLib-1.20.4-v4-1691.jar//com.bergerkiller.bukkit.common.internal.CommonClasses.loadCommon(CommonClasses.java:86) [01:10:29] [Server thread/WARN]: at BKCommonLib-1.20.4-v4-1691.jar//com.bergerkiller.bukkit.common.internal.CommonClasses.loadUtil(CommonClasses.java:79) [01:10:29] [Server thread/WARN]: at BKCommonLib-1.20.4-v4-1691.jar//com.bergerkiller.bukkit.common.internal.CommonClasses.init(CommonClasses.java:59) [01:10:29] [Server thread/WARN]: at BKCommonLib-1.20.4-v4-1691.jar//com.bergerkiller.bukkit.common.internal.CommonPlugin.onLoad(CommonPlugin.java:548) [01:10:29] [Server thread/WARN]: at io.papermc.paper.plugin.storage.ServerPluginProviderStorage.processProvided(ServerPluginProviderStorage.java:59) [01:10:29] [Server thread/WARN]: at io.papermc.paper.plugin.storage.ServerPluginProviderStorage.processProvided(ServerPluginProviderStorage.java:18) [01:10:29] [Server thread/WARN]: at io.papermc.paper.plugin.storage.SimpleProviderStorage.enter(SimpleProviderStorage.java:39) [01:10:29] [Server thread/WARN]: at io.papermc.paper.plugin.entrypoint.LaunchEntryPointHandler.enter(LaunchEntryPointHandler.java:36) [01:10:29] [Server thread/WARN]: at org.bukkit.craftbukkit.v1_20_R3.CraftServer.loadPlugins(CraftServer.java:507) [01:10:29] [Server thread/WARN]: at net.minecraft.server.dedicated.DedicatedServer.e(DedicatedServer.java:274) [01:10:29] [Server thread/WARN]: at net.minecraft.server.MinecraftServer.w(MinecraftServer.java:1131) [01:10:29] [Server thread/WARN]: at net.minecraft.server.MinecraftServer.lambda$spin$0(MinecraftServer.java:319) [01:10:29] [Server thread/WARN]: at java.base/java.lang.Thread.run(Thread.java:1583)`

Expected behaviour: Remove this warning

Steps to reproduce: Every time the server is started

bergerkiller commented 7 months ago

Can't at the moment. It initializes old stuff because this library has to support all the way back to 1.8. It has no further impact on the server besides logging that warning.

bbayu123 commented 7 months ago

Closing: Not a bug, won't fix.

bergerkiller commented 7 months ago

Well, I want to fix this at some point, but until Bukkit officially deletes the legacy api, its just extra work that doesn't have much benefit.

At the moment, BKCL's BlockData API largely replaces this deprecated mess, and Im already using that in most places.

Regardless, this issue was reported 2 or 3 times before, so at the very least it would be a duplicate.