PluginBugs / Issues-ItemsAdder

Repository used to keep track of issues of my plugin ItemsAdder
https://itemsadder.devs.beer
53 stars 21 forks source link

ClassCastException on EntityShootBowEvent #3780

Closed Lia-LV closed 1 month ago

Lia-LV commented 3 months ago

Terms

Discord tag (optional)

lia_lv

What happened?

If a bow or crossbow with a specific Custom Model Data(it is Discord Nitro Tools for me) is fired, an error appears on the console.

Causing Exception error model -> https://mcmodels.net/products/11037/discord-nitro-tools

Steps to reproduce the issue

shoot anything(firework, arrow) with specific custom model data bow and crossbow. and see console.

Server version

This server is running Paper version 1.20.6-148-ver/1.20.6@20f5165 (2024-07-02T15:37:33Z) (Implementing API version 1.20.6-R0.1-SNAPSHOT) You are running the latest version Previous version: 1.20.6-2233-0d6766e (MC: 1.20.6)

ItemsAdder Version

ItemsAdder version 4.0.1-alpha-test-5

ProtocolLib Version

ProtocolLib version 5.3.0-SNAPSHOT-715

LoneLibs Version

LoneLibs version 1.0.55

Full server log

No response

Error (optional)

[22:46:59 ERROR]: Could not pass event EntityShootBowEvent to ItemsAdder v4.0.1-alpha-test-5
java.lang.ClassCastException: class ia.m.eH cannot be cast to class ia.m.eB (ia.m.eH and ia.m.eB are in unnamed module of loader 'ItemsAdder_4.0.1-alpha-test-5.jar' @423376fb)
        at ItemsAdder_4.0.1-alpha-test-5.jar/ia.m.di.b(SourceFile:364) ~[ItemsAdder_4.0.1-alpha-test-5.jar:?]
        at com.destroystokyo.paper.event.executor.MethodHandleEventExecutor.execute(MethodHandleEventExecutor.java:40) ~[paper-api-1.20.6-R0.1-SNAPSHOT.jar:?]
        at co.aikar.timings.TimedEventExecutor.execute(TimedEventExecutor.java:81) ~[paper-api-1.20.6-R0.1-SNAPSHOT.jar:1.20.6-148-20f5165]
        at org.bukkit.plugin.RegisteredListener.callEvent(RegisteredListener.java:70) ~[paper-api-1.20.6-R0.1-SNAPSHOT.jar:?]
        at io.papermc.paper.plugin.manager.PaperEventManager.callEvent(PaperEventManager.java:54) ~[paper-1.20.6.jar:1.20.6-148-20f5165]
        at io.papermc.paper.plugin.manager.PaperPluginManagerImpl.callEvent(PaperPluginManagerImpl.java:131) ~[paper-1.20.6.jar:1.20.6-148-20f5165]
        at org.bukkit.plugin.SimplePluginManager.callEvent(SimplePluginManager.java:628) ~[paper-api-1.20.6-R0.1-SNAPSHOT.jar:?]
        at org.bukkit.craftbukkit.event.CraftEventFactory.callEntityShootBowEvent(CraftEventFactory.java:635) ~[paper-1.20.6.jar:1.20.6-148-20f5165]
        at net.minecraft.world.item.ProjectileWeaponItem.shoot(ProjectileWeaponItem.java:67) ~[paper-1.20.6.jar:1.20.6-148-20f5165]
        at net.minecraft.world.item.CrossbowItem.performShooting(CrossbowItem.java:190) ~[paper-1.20.6.jar:1.20.6-148-20f5165]
        at net.minecraft.world.item.CrossbowItem.use(CrossbowItem.java:63) ~[paper-1.20.6.jar:1.20.6-148-20f5165]
        at net.minecraft.world.item.ItemStack.use(ItemStack.java:598) ~[paper-1.20.6.jar:1.20.6-148-20f5165]
        at net.minecraft.server.level.ServerPlayerGameMode.useItem(ServerPlayerGameMode.java:483) ~[paper-1.20.6.jar:1.20.6-148-20f5165]
        at net.minecraft.server.network.ServerGamePacketListenerImpl.handleUseItem(ServerGamePacketListenerImpl.java:2016) ~[paper-1.20.6.jar:1.20.6-148-20f5165]
        at net.minecraft.network.protocol.game.ServerboundUseItemPacket.handle(ServerboundUseItemPacket.java:39) ~[paper-1.20.6.jar:1.20.6-148-20f5165]
        at net.minecraft.network.protocol.game.ServerboundUseItemPacket.handle(ServerboundUseItemPacket.java:10) ~[paper-1.20.6.jar:1.20.6-148-20f5165]
        at net.minecraft.network.protocol.PacketUtils.lambda$ensureRunningOnSameThread$0(PacketUtils.java:55) ~[paper-1.20.6.jar:1.20.6-148-20f5165]
        at net.minecraft.server.TickTask.run(TickTask.java:18) ~[paper-1.20.6.jar:1.20.6-148-20f5165]
        at net.minecraft.util.thread.BlockableEventLoop.doRunTask(BlockableEventLoop.java:151) ~[paper-1.20.6.jar:1.20.6-148-20f5165]
        at net.minecraft.util.thread.ReentrantBlockableEventLoop.doRunTask(ReentrantBlockableEventLoop.java:24) ~[paper-1.20.6.jar:1.20.6-148-20f5165]
        at net.minecraft.server.MinecraftServer.doRunTask(MinecraftServer.java:1511) ~[paper-1.20.6.jar:1.20.6-148-20f5165]
        at net.minecraft.server.MinecraftServer.doRunTask(MinecraftServer.java:195) ~[paper-1.20.6.jar:1.20.6-148-20f5165]
        at net.minecraft.util.thread.BlockableEventLoop.pollTask(BlockableEventLoop.java:125) ~[paper-1.20.6.jar:1.20.6-148-20f5165]
        at net.minecraft.server.MinecraftServer.pollTaskInternal(MinecraftServer.java:1488) ~[paper-1.20.6.jar:1.20.6-148-20f5165]
        at net.minecraft.server.MinecraftServer.pollTask(MinecraftServer.java:1411) ~[paper-1.20.6.jar:1.20.6-148-20f5165]
        at net.minecraft.util.thread.BlockableEventLoop.managedBlock(BlockableEventLoop.java:135) ~[paper-1.20.6.jar:1.20.6-148-20f5165]
        at net.minecraft.server.MinecraftServer.waitUntilNextTick(MinecraftServer.java:1377) ~[paper-1.20.6.jar:1.20.6-148-20f5165]
        at net.minecraft.server.MinecraftServer.runServer(MinecraftServer.java:1238) ~[paper-1.20.6.jar:1.20.6-148-20f5165]
        at net.minecraft.server.MinecraftServer.lambda$spin$0(MinecraftServer.java:323) ~[paper-1.20.6.jar:1.20.6-148-20f5165]
        at java.base/java.lang.Thread.run(Thread.java:1583) ~[?:?]

Problematic items yml configuration file (optional)

No response

Other files, you can drag and drop them here to upload. (optional)

No response

Screenshots/Videos (you can drag and drop files or paste links)

No response

Lia-LV commented 3 months ago

It happens another models too, I can see exceptions with 2 models below. https://mcmodels.net/products/11701/archangel-weapon-assortment-kill-effect https://mcmodels.net/products/11744/dragonborn-assortment-kill-effect

I think it seems to be happening most models.

Andre601 commented 3 months ago

Please share your latest.log through https://mclo.gs as it help us getting all the necessary info required to solving this issue.

Lia-LV commented 3 months ago

https://mclo.gs/fgDilvQ here is my latest.log file. and idk why it say 'forge server', but I'm using Paper 1.20.6 latest build so it's vanilla server. not modded. and exceptions start at line 2444.

Jameskarl28 commented 1 month ago

still no fix?

AshleyFOXXX commented 2 weeks ago

any fix to this?