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

Thorns damage is applied when player shoots himself

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Resolved
    • Resolution: Works As Intended
    • Affects Version/s: Minecraft 16w35a
    • Fix Version/s: None
    • Confirmation Status:
      Confirmed

      Description

      The bug

      When a player shoots himself with a bow he will be damaged by his own thorns enchantment.

      How to reproduce

      1. Use the following command and equip the chestplate
        /give @p minecraft:diamond_chestplate 1 0 {ench:[{id:7s,lvl:32767s}]}
        
      2. Shoot yourself
        → Your chestplate will break and you will die because of the thorns damage

      Possible solution

      The following is based on a decompiled version of Minecraft 1.10 using MCP 9.30.

      This could probably be tested in the methods net.minecraft.enchantment.EnchantmentHelper.applyThornEnchantments(EntityLivingBase, Entity) (better?) or net.minecraft.enchantment.EnchantmentThorns.onUserHurt(EntityLivingBase, Entity, int).

        Attachments

          Activity

            People

            • Assignee:
              Excited [Mojang] Maria Lemón
              Reporter:
              marcono1234 [Mod] Marcono1234
            • Votes:
              5 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:
                CHK: