No field with type net.minecraft.server.v1_15_R1.DataWatcher exists in class PacketPlayOutSpawnEntityLiving
bundabrg opened this issue ยท 5 comments
Description and relevant errors:
Dev of BetonQuest here. I'm having issues with 1.15.1 when spawning an armourstand.
10:27:33 [INFO] [s2-lobby] [10:27:33 WARN]: [BetonQuest] Task #224 for BetonQuest v1.11-dev generated an exception
10:27:33 [INFO] [s2-lobby] com.comphenix.protocol.reflect.FieldAccessException: No field with type net.minecraft.server.v1_15_R1.DataWatcher exists in class PacketPlayOutSpawnEntityLiving.
10:27:33 [INFO] [s2-lobby] at com.comphenix.protocol.reflect.StructureModifier.writeInternal(StructureModifier.java:363) ~[?:?]
10:27:33 [INFO] [s2-lobby] at com.comphenix.protocol.reflect.StructureModifier.write(StructureModifier.java:343) ~[?:?]
10:27:33 [INFO] [s2-lobby] at pl.betoncraft.betonquest.compatibility.protocollib.wrappers.WrapperPlayServerSpawnEntityLiving.setMetadata(WrapperPlayServerSpawnEntityLiving.java:311) ~[?:?]
10:27:33 [INFO] [s2-lobby] at pl.betoncraft.betonquest.compatibility.protocollib.conversation.MenuConvIO.start(MenuConvIO.java:190) ~[?:?]
10:27:33 [INFO] [s2-lobby] at pl.betoncraft.betonquest.compatibility.protocollib.conversation.MenuConvIO.display(MenuConvIO.java:313) ~[?:?]
10:27:33 [INFO] [s2-lobby] at pl.betoncraft.betonquest.conversation.Conversation$1.run(Conversation.java:269) ~[?:?]
10:27:33 [INFO] [s2-lobby] at org.bukkit.craftbukkit.v1_15_R1.scheduler.CraftTask.run(CraftTask.java:84) ~[patched_1.15.1.jar:git-Paper-25]
10:27:33 [INFO] [s2-lobby] at org.bukkit.craftbukkit.v1_15_R1.scheduler.CraftScheduler.mainThreadHeartbeat(CraftScheduler.java:452) ~[patched_1.15.1.jar:git-Paper-25]
10:27:33 [INFO] [s2-lobby] at net.minecraft.server.v1_15_R1.MinecraftServer.b(MinecraftServer.java:1179) ~[patched_1.15.1.jar:git-Paper-25]
10:27:33 [INFO] [s2-lobby] at net.minecraft.server.v1_15_R1.DedicatedServer.b(DedicatedServer.java:417) ~[patched_1.15.1.jar:git-Paper-25]
10:27:33 [INFO] [s2-lobby] at net.minecraft.server.v1_15_R1.MinecraftServer.a(MinecraftServer.java:1106) ~[patched_1.15.1.jar:git-Paper-25]
10:27:33 [INFO] [s2-lobby] at net.minecraft.server.v1_15_R1.MinecraftServer.run(MinecraftServer.java:933) ~[patched_1.15.1.jar:git-Paper-25]
10:27:33 [INFO] [s2-lobby] at java.lang.Thread.run(Thread.java:834) [?:?]
The relevant line in BQ that triggers this which then calls the wrapper here
Let me know if I can provide any assistance.
Mojang removed data watchers from the packet in 1.15. BQ needs to update and take that into account. Nothing we can do on the ProtocolLib side.
Thanks, I'll do some research on what to change then. TBH I don't yet quite get Datawatchers and used it purely to make the armorstand invisible.
Hello, I'm using a lib called NameTagChanger by Alvin-LB which uses DataWatchers at this line:
https://github.com/Alvin-LB/NameTagChanger/blob/80d19924bf492dfde0b4b7c1936a633e4a854bb9/src/main/java/com/bringholm/nametagchanger/ProtocolLibPacketHandler.java#L140
What's the alternative/solution so I can fix it myself? I'm not very familiar with ProtocolLib
@SimonIT essentially you have to send a separate metadata packet with that data