mojira.dev
MCPE-171381

The itemUseOn event doesn't fire when your mainhand is empty.

Expected Behavior: When interacting on a block with an empty mainhand, the beforeEvents.itemUseOn event is fired, as well as the afterEvents.itemUseOn event.

Current Behavior: When interacting on a block with an empty mainhand, these events no longer fire. This behavior does not occur when interacting with an item in your mainhand.

This issue only occurs when using the 1.3.0-beta version of the minecraft-server module or later in behavior packs.

 

Sample Code:
 

world.beforeEvents.itemUseOn.subscribe((data) => {console.warn(1) })

 

Comments 3

It is a bug

Fix it please

Thank you for your report!

However, this issue has been temporarily closed as Awaiting Response.

Could you please attach an example addon showcasing the issue?

This ticket will automatically reopen when you reply.

Quick Links:
📓 Issue Guidelines – 💬 Mojang Support – 📓 Project Summary – 📧 Suggestions – 📖 Minecraft Wiki

Cleaning up old tickets: This ticket had been set to 'Awaiting Response', but has not received a response from the reporter (~3 months+) so is being closed as Incomplete. If you feel this is still a valid issue then please comment, or create a new ticket following the Issue Guidelines which includes steps to reproduce the problem.

Quick Links:
📓 Issue Guidelines – 💬 Mojang Support – 📧 Suggestions – 📖 Minecraft Wiki

PalmMC

(Unassigned)

Unconfirmed

Windows

Windows 11

1.20.0

Retrieved