mojira.dev
MC-144309

Two mobs one right click via spawn egg

Issue: two mobs one right click from a spawn egg

Steps to reproduce
Place a creeper spawn egg in one hand and a witch spawn egg in the other hand. Next go to a block of water that is 3 deep and make sure your mouse only hovers over water. Right click on the water and observe two mobs spawning in instead of one. It only happens over water every other function only spawns it in once

Analysis:
ActionResult<EnumActionResult,ItemStack> onItemRightClick() --> returns successful in main hand
ActionResult <EnumActionResult,ItemStack> onItemRightClick() fires in off hand --> returns successful in off hand
Two Entities Spawn in(one creeper, one witch) one in each hand.

Solution: if onItemRightClick returns successful don't start the offhand onItemRightClick

Related issues

Comments

No comments.

migrated

(Unassigned)

Confirmed

Minecraft 19w07a

Retrieved