
Breaking top blocks of Grandfather Clock drops multiple items - Block Duplication Bug
Aruaya158 opened this issue ยท 0 comments
Describe the bug
When breaking the top two blocks of the Grandfather Clock, multiple clock items drop instead of just one. However, when breaking the bottom block, the drop is correct.
This suggests that the multi-block structure of the clock does not properly track or prevent duplicate item drops when broken from the top.
To Reproduce
Steps to reproduce the behavior:
- Place a Grandfather Clock in the world.
- Break the top block โ Multiple items drop.
- Break the middle block โ Multiple items drop.
- Break the bottom block โ Only one item drops correctly.
Expected behavior
Destroying any part of the Grandfather Clock should result in only one item drop, not multiple.
Screenshots
N/A
Environment
Minecraft Version: 1.20.1
Forge Version: 47.3.22
Cozy Home Version: 3.0.4
Server Type: Mohist
Additional context
[23:13:36 ERROR]: Failed to handle packet net.minecraft.network.protocol.game.ServerboundUseItemOnPacket@50250a05, suppressing error
java.lang.NullPointerException: Cannot invoke "net.minecraft.world.entity.Entity.m_146922_(float)" because "_ent" is null
at net.mcreator.cozyhome.procedures.GrandfatherClockPlacedProcedure.execute(GrandfatherClockPlacedProcedure.java:119) ~[cozy_home-3.0.4-forge-1.20.1.jar%23434!/:?]
at net.mcreator.cozyhome.procedures.GrandfatherClockPlacedProcedure.onBlockPlace(GrandfatherClockPlacedProcedure.java:36) ~[cozy_home-3.0.4-forge-1.20.1.jar%23434!/:?]
at net.mcreator.cozyhome.procedures.__GrandfatherClockPlacedProcedure_onBlockPlace_EntityPlaceEvent.invoke(.dynamic) ~[cozy_home-3.0.4-forge-1.20.1.jar%23434!/:?]
at net.minecraftforge.eventbus.ASMEventHandler.invoke(ASMEventHandler.java:73) ~[eventbus-6.0.5.jar%23150!/:?]
at net.minecraftforge.eventbus.EventBus.post(EventBus.java:319) ~[eventbus-6.0.5.jar%23150!/:?]
at net.minecraftforge.eventbus.EventBus.post(EventBus.java:299) ~[eventbus-6.0.5.jar%23150!/:?]
at net.minecraftforge.event.ForgeEventFactory.onBlockPlace(ForgeEventFactory.java:183) ~[forge-1.20.1-47.3.22-universal.jar%23515!/:?]
at net.minecraftforge.common.ForgeHooks.onPlaceItemIntoWorld(ForgeHooks.java:630) ~[forge-1.20.1-47.3.22-universal.jar%23515!/:?]
at net.minecraft.world.item.ItemStack.m_41661_(ItemStack.java:302) ~[server-1.20.1-20230612.114412-srg.jar%23510!/:?]
at net.minecraft.server.level.ServerPlayerGameMode.m_7179_(ServerPlayerGameMode.java:507) ~[server-1.20.1-20230612.114412-srg.jar%23510!/:?]
at net.minecraft.server.network.ServerGamePacketListenerImpl.m_6371_(ServerGamePacketListenerImpl.java:1584) ~[server-1.20.1-20230612.114412-srg.jar%23510!/:?]
at net.minecraft.network.protocol.game.ServerboundUseItemOnPacket.m_5797_(ServerboundUseItemOnPacket.java:34) ~[server-1.20.1-20230612.114412-srg.jar%23510!/:?]
at net.minecraft.network.protocol.game.ServerboundUseItemOnPacket.m_5797_(ServerboundUseItemOnPacket.java:8) ~[server-1.20.1-20230612.114412-srg.jar%23510!/:?]
at net.minecraft.network.protocol.PacketUtils.m_263899_(PacketUtils.java:25) ~[server-1.20.1-20230612.114412-srg.jar%23510!/:?]
at net.minecraft.server.TickTask.run(TickTask.java:18) ~[server-1.20.1-20230612.114412-srg.jar%23510!/:?]
at net.minecraft.util.thread.BlockableEventLoop.m_6367_(BlockableEventLoop.java:151) ~[server-1.20.1-20230612.114412-srg.jar%23510!/:?]
at net.minecraft.util.thread.ReentrantBlockableEventLoop.m_6367_(ReentrantBlockableEventLoop.java:23) ~[server-1.20.1-20230612.114412-srg.jar%23510!/:?]
at net.minecraft.server.MinecraftServer.m_6367_(MinecraftServer.java:1026) ~[server-1.20.1-20230612.114412-srg.jar%23510!/:?]
at net.minecraft.server.MinecraftServer.m_6367_(MinecraftServer.java:176) ~[server-1.20.1-20230612.114412-srg.jar%23510!/:?]
at net.minecraft.util.thread.BlockableEventLoop.m_7245_(BlockableEventLoop.java:124) ~[server-1.20.1-20230612.114412-srg.jar%23510!/:?]
at net.minecraft.server.MinecraftServer.m_129961_(MinecraftServer.java:1009) ~[server-1.20.1-20230612.114412-srg.jar%23510!/:?]
at net.minecraft.server.MinecraftServer.m_7245_(MinecraftServer.java:1003) ~[server-1.20.1-20230612.114412-srg.jar%23510!/:?]
at net.minecraft.util.thread.BlockableEventLoop.m_18699_(BlockableEventLoop.java:112) ~[server-1.20.1-20230612.114412-srg.jar%23510!/:?]
at net.minecraft.server.MinecraftServer.m_130012_(MinecraftServer.java:988) ~[server-1.20.1-20230612.114412-srg.jar%23510!/:?]
at net.minecraft.server.MinecraftServer.m_130011_(MinecraftServer.java:914) ~[server-1.20.1-20230612.114412-srg.jar%23510!/:?]
at net.minecraft.server.MinecraftServer.m_206580_(MinecraftServer.java:286) ~[server-1.20.1-20230612.114412-srg.jar%23510!/:?]
at java.lang.Thread.run(Thread.java:833) [?:?]