Bug Closed · Resolved

Brewing inventory issues.

#6265 opened by Unknown 1 year ago

Unknownreported this bug

Summary Click in Plugin generated brewing inventory

Steps to reproduce

Click in Plugin generated brewing inventory

Current behavior

Throws error, because it searches for the inventory holder. The inventory was created with Bukkit.createInventory(null, InventoryType.BREWING)

Debug log snippet [MythicMobs]: [EVENTS] Exception thrown whilst handling event: org.bukkit.event.inventory.InventoryClickEvent

WARN 17:04:07

java.lang.ClassCastException: class org.bukkit.craftbukkit.inventory.CraftInventoryCustom cannot be cast to class org.bukkit.inventory.BrewerInventory (org.bukkit.craftbukkit.inventory.CraftInventoryCustom and org.bukkit.inventory.BrewerInventory are in unnamed module of loader java.net.URLClassLoader @7ab2bfe1) at MythicCrucible-2.2.0-SNAPSHOT.jar//io.lumine.mythiccrucible.items.recipes.brewing.BrewingEventListeners.customPotionItemStackClick(BrewingEventListeners.java:90) at MythicMobsPremium-5.8.1.jar//io.lumine.mythic.bukkit.utils.Delegates$ConsumerToBiConsumerSecond.accept(Delegates.java:144) at MythicMobsPremium-5.8.1.jar//io.lumine.mythic.bukkit.utils.events.functional.single.EventListener.execute(EventListener.java:131) at co.aikar.timings.TimedEventExecutor.execute(TimedEventExecutor.java:80) at org.bukkit.plugin.RegisteredListener.callEvent(RegisteredListener.java:70) at io.papermc.paper.plugin.manager.PaperEventManager.callEvent(PaperEventManager.java:54) at io.papermc.paper.plugin.manager.PaperPluginManagerImpl.callEvent(PaperPluginManagerImpl.java:131) at org.bukkit.plugin.SimplePluginManager.callEvent(SimplePluginManager.java:628) at net.minecraft.server.network.ServerGamePacketListenerImpl.handleContainerClick(ServerGamePacketListenerImpl.java:3224) at net.minecraft.network.protocol.game.ServerboundContainerClickPacket.handle(ServerboundContainerClickPacket.java:69) at net.minecraft.network.protocol.game.ServerboundContainerClickPacket.handle(ServerboundContainerClickPacket.java:33) at net.minecraft.network.protocol.PacketUtils.lambda$ensureRunningOnSameThread$0(PacketUtils.java:56) at net.minecraft.server.TickTask.run(TickTask.java:18) at net.minecraft.util.thread.BlockableEventLoop.doRunTask(BlockableEventLoop.java:151) at net.minecraft.util.thread.ReentrantBlockableEventLoop.doRunTask(ReentrantBlockableEventLoop.java:24) at net.minecraft.server.MinecraftServer.doRunTask(MinecraftServer.java:1535) at net.minecraft.server.MinecraftServer.doRunTask(MinecraftServer.java:201) at net.minecraft.util.thread.BlockableEventLoop.pollTask(BlockableEventLoop.java:125) at net.minecraft.server.MinecraftServer.pollTaskInternal(MinecraftServer.java:1512) at net.minecraft.server.MinecraftServer.pollTask(MinecraftServer.java:1505) at net.minecraft.util.thread.BlockableEventLoop.managedBlock(BlockableEventLoop.java:135) at net.minecraft.server.MinecraftServer.managedBlock(MinecraftServer.java:1464) at net.minecraft.server.MinecraftServer.waitUntilNextTick(MinecraftServer.java:1471) at net.minecraft.server.MinecraftServer.runServer(MinecraftServer.java:1316) at net.minecraft.server.MinecraftServer.lambda$spin$0(MinecraftServer.java:329) at java.base/java.lang.Thread.run(Thread.java:1583)

Proposed fixes

Should check if has an holder.

Unknowncommented

This ticket will be closed until a modern-version (at least Mythic 5.8.2+ and Paper 1.21.4) server log from startup to issue replication is linked, such as via Pastebin in order to attempt to reproduce.

Additional info about this "plugin generated brewing inventory" (what plugin, configuration, etc) would also be required.

Sign in to join the discussion.