Uploaded image for project: 'Minecraft: Java Edition'
  1. Minecraft: Java Edition
  2. MC-114718

Right clicking cake with empty main hand does not use item in off-hand

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Unresolved
    • None
    • Minecraft 1.11.2, Minecraft 17w06a, Minecraft 1.12.2, Minecraft 18w03b, Minecraft 1.13, Minecraft 18w30b, Minecraft 1.13.1, Minecraft 1.13.2, Minecraft 18w47a, Minecraft 18w47b, Minecraft 18w48a, Minecraft 18w48b, Minecraft 18w49a, Minecraft 18w50a, Minecraft 19w02a, Minecraft 19w04a, Minecraft 19w08a, Minecraft 19w12a, Minecraft 19w12b, Minecraft 19w13a, Minecraft 19w13b, Minecraft 19w14a, Minecraft 19w14b, Minecraft 1.14 Pre-Release 2, Minecraft 1.14 Pre-Release 5, Minecraft 1.14.3 Pre-Release 4, 1.14.4, 19w35a, 19w36a, 19w37a, 19w38b, 19w39a, 19w40a, 19w41a, 19w42a, 19w44a, 19w45a, 19w46a, 19w46b, 1.15 Pre-release 1, 1.15 Pre-Release 2, 1.15 Pre-release 3, 1.15 Pre-release 4, 1.15 Pre-release 6, 1.15 Pre-release 7, 1.15.1 Pre-release 1, 1.15.2 Pre-Release 1, 1.15.2 Pre-release 2, 20w06a, 20w07a, 20w08a, 20w09a, 20w10a, 20w11a, 20w12a, 20w15a, 20w20a, 20w21a, 1.16 Pre-release 2, 1.16 Pre-release 3, 20w28a, 20w29a, 20w30a, 1.16.2 Pre-release 1, 1.16.4 Release Candidate 1, 1.16.4, 20w46a, 20w51a, 21w03a, 21w06a, 21w17a, 21w20a, 1.17 Pre-release 1, 1.17, 1.17.1, 1.18.1, 1.18.2, 1.19, 1.19.2, 1.20.1
    • Confirmed
    • Player
    • Low
    • Gameplay

      The bug

      Right clicking a cake which cannot be eaten with an item with a right click action in the main hand will correctly use the item. However, if the cake is clicked with an empty main hand and the same item in the offhand instead, the item's action is not executed. This is inconsistent with all other blocks.

      How to reproduce

      1. Place an item with right click ability like a fishing rod in your offhand
      2. Right click a cake with an empty main hand
        → You will notice that the fishing rod is not used

      Code analysis

      Based on 1.11.2 decompiled using MCP 9.35 rc1 (may no longer apply given 19w42a changes)

      The respective methods overriding the method net.minecraft.block.Block.onBlockActivated(World, BlockPos, IBlockState, EntityPlayer, EnumHand, EnumFacing, float, float, float) return true if the currently held item is empty.

        1. MC-114718.png
          MC-114718.png
          562 kB
        2. MC-114718.mp4
          3.08 MB

            Unassigned Unassigned
            Awesoman3000 Connor Steppie
            Votes:
            15 Vote for this issue
            Watchers:
            6 Start watching this issue

              Created:
              Updated:
              CHK: