VolatileChannelHandler fails to inject on 1.20.6
Custom packet handler fails to inject on 1.20.6 due to incorrect obfuscated field name:
[15:22:17 WARN]: java.lang.ClassCastException: class net.minecraft.network.chat.MutableComponent cannot be cast to class net.minecraft.network.Connection (net.minecraft.network.chat.MutableComponent and net.minecraft.network.Connection are in unnamed module of loader java.net.URLClassLoader @41cf53f9)
[15:22:17 WARN]: at MythicMobsPremium-5.7.0-SNAPSHOT.jar//io.lumine.mythic.core.volatilecode.v1_20_R4.VolatilePacketHandlerImpl.injectPlayer(VolatilePacketHandlerImpl.java:45)
[15:22:17 WARN]: at MythicMobsPremium-5.7.0-SNAPSHOT.jar//io.lumine.mythic.core.volatilecode.v1_20_R4.VolatilePacketHandlerImpl.lambda$new$0(VolatilePacketHandlerImpl.java:35)
[15:22:17 WARN]: at MythicMobsPremium-5.7.0-SNAPSHOT.jar//io.lumine.mythic.bukkit.utils.Delegates$ConsumerToBiConsumerSecond.accept(Delegates.java:144)
[15:22:17 WARN]: at MythicMobsPremium-5.7.0-SNAPSHOT.jar//io.lumine.mythic.bukkit.utils.events.functional.single.EventListener.execute(EventListener.java:131)
[15:22:17 WARN]: at co.aikar.timings.TimedEventExecutor.execute(TimedEventExecutor.java:77)
[15:22:17 WARN]: at org.bukkit.plugin.RegisteredListener.callEvent(RegisteredListener.java:70)
[15:22:17 WARN]: at io.papermc.paper.plugin.manager.PaperEventManager.callEvent(PaperEventManager.java:54)
[15:22:17 WARN]: at io.papermc.paper.plugin.manager.PaperPluginManagerImpl.callEvent(PaperPluginManagerImpl.java:131)
[15:22:17 WARN]: at org.bukkit.plugin.SimplePluginManager.callEvent(SimplePluginManager.java:627)
[15:22:17 WARN]: at net.minecraft.server.players.PlayerList.placeNewPlayer(PlayerList.java:347)
[15:22:17 WARN]: at net.minecraft.server.network.ServerConfigurationPacketListenerImpl.handleConfigurationFinished(ServerConfigurationPacketListenerImpl.java:153)
[15:22:17 WARN]: at net.minecraft.network.protocol.configuration.ServerboundFinishConfigurationPacket.handle(ServerboundFinishConfigurationPacket.java:22)
[15:22:17 WARN]: at net.minecraft.network.protocol.configuration.ServerboundFinishConfigurationPacket.handle(ServerboundFinishConfigurationPacket.java:13)
[15:22:17 WARN]: at net.minecraft.network.protocol.PacketUtils.lambda$ensureRunningOnSameThread$0(PacketUtils.java:55)
[15:22:17 WARN]: at net.minecraft.server.TickTask.run(TickTask.java:18)
[15:22:17 WARN]: at net.minecraft.util.thread.BlockableEventLoop.doRunTask(BlockableEventLoop.java:151)
[15:22:17 WARN]: at net.minecraft.util.thread.ReentrantBlockableEventLoop.doRunTask(ReentrantBlockableEventLoop.java:24)
[15:22:17 WARN]: at net.minecraft.server.MinecraftServer.doRunTask(MinecraftServer.java:1514)
[15:22:17 WARN]: at net.minecraft.server.MinecraftServer.doRunTask(MinecraftServer.java:195)
[15:22:17 WARN]: at net.minecraft.util.thread.BlockableEventLoop.pollTask(BlockableEventLoop.java:125)
[15:22:17 WARN]: at net.minecraft.server.MinecraftServer.pollTaskInternal(MinecraftServer.java:1491)
[15:22:17 WARN]: at net.minecraft.server.MinecraftServer.pollTask(MinecraftServer.java:1414)
[15:22:17 WARN]: at net.minecraft.util.thread.BlockableEventLoop.managedBlock(BlockableEventLoop.java:135)
[15:22:17 WARN]: at net.minecraft.server.MinecraftServer.waitUntilNextTick(MinecraftServer.java:1380)
[15:22:17 WARN]: at net.minecraft.server.MinecraftServer.runServer(MinecraftServer.java:1241)
[15:22:17 WARN]: at net.minecraft.server.MinecraftServer.lambda$spin$0(MinecraftServer.java:323)
[15:22:17 WARN]: at java.base/java.lang.Thread.run(Thread.java:1583)
From looking at the obfuscation mappings, e
is the correct field name for connection
, not c
.