juliarn / npc-lib

Asynchronous, high-performance Minecraft NPC library for 1.8-1.21 servers.
MIT License
320 stars 50 forks source link

Error when NPC is shown to a player #51

Closed vytskalt closed 3 years ago

vytskalt commented 3 years ago

Getting this error:

java.lang.NoSuchMethodException: java.util.Collections$SingletonList.<init>()
at java.lang.Class.getConstructor0(Class.java:3082)
at java.lang.Class.getConstructor(Class.java:1825)
at com.comphenix.protocol.wrappers.BukkitConverters.getGenericList(BukkitConverters.java:277)
at com.comphenix.protocol.wrappers.BukkitConverters.access$100(BukkitConverters.java:88)
at com.comphenix.protocol.wrappers.BukkitConverters$3.getGeneric(BukkitConverters.java:367)
at com.comphenix.protocol.wrappers.BukkitConverters$3.getGeneric(BukkitConverters.java:359)
at com.comphenix.protocol.wrappers.Converters$1.getGeneric(Converters.java:48)
at com.comphenix.protocol.reflect.StructureModifier.writeInternal(StructureModifier.java:372)
at com.comphenix.protocol.reflect.StructureModifier.write(StructureModifier.java:345)
at com.github.juliarn.npc.modifier.VisibilityModifier.queuePlayerListChange(VisibilityModifier.java:60)
at com.github.juliarn.npc.NPC.show(NPC.java:86)
at com.github.juliarn.npc.NPCPool.lambda$npcTick$1(NPCPool.java:173)
at org.bukkit.craftbukkit.v1_8_R3.scheduler.CraftTask.run(CraftTask.java:64)
at org.bukkit.craftbukkit.v1_8_R3.scheduler.CraftAsyncTask.run(CraftAsyncTask.java:53)
at org.github.paperspigot.ServerSchedulerReportingWrapper.run(ServerSchedulerReportingWrapper.java:23)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
at java.lang.Thread.run(Thread.java:748)

I'm on 1.8.8. The NPC is visible to the client.

Angxstupst commented 3 years ago

Please use ProtocolLib 4.6.0.

vytskalt commented 3 years ago

Please use ProtocolLib 4.6.0.

Thanks