mojira.dev
MC-155678

"minecraft.custom:minecraft.damage_dealt" doesn't increase when the thorns enchantment damages entities

The Bug:

"minecraft.custom:minecraft.damage_dealt" doesn't increase when the thorns enchantment damages entities.

Steps to Reproduce:

  1. Create a scoreboard objective for tracking when you deal damage and set it to display on the sidebar by using the commands provided below.  

    /scoreboard objectives add DamageDealt minecraft.custom:minecraft.damage_dealt
    /scoreboard objectives setdisplay sidebar DamageDealt
  2. Summon a husk, attack it and take note of how the scoreboard increases.

  3. Equip some armor enchanted with thorns by using the command provided below.

    /item replace entity @s armor.chest with minecraft:diamond_chestplate[minecraft:enchantments={"minecraft:thorns":3}]
  4. Switch into survival mode and allow the husk to damage you.

  5. Wait for the thorns enchantment to damage the husk.

  6. Take note as to whether or not "minecraft.custom:minecraft.damage_dealt" increases when the thorns enchantment damages entities.

Observed Behavior:

"minecraft.custom:minecraft.damage_dealt" doesn't increase when the thorns enchantment damages entities.

Expected Behavior:

"minecraft.custom:minecraft.damage_dealt" would increase when the thorns enchantment damages entities.

Linked issues

Attachments

Comments 7

To replicate run these commands:

/scoreboard objectives add damageDealt minecraft.custom:minecraft.damage_dealt

/scoreboard objectives setdisplay sidebar damageDealt

/scoreboard players set @s damageDealt 0

/give @s minecraft:diamond_chestplate{Enchantments:[{id:"minecraft:thorns",lvl:10000s}]} 1

Then put on the diamond chestplate and summon zombies to observe them dying and the damage dealt not increasing

Confirmed in 20w13b

Confirmed in 1.16.1 and 20w28a. Related to MC-29519.

Can confirm in 20w51a. Here's the updated command since the replaceitem command no longer exists.

/item entity @s armor.chest replace diamond_chestplate{Enchantments:[{id:thorns,lvl:7}]}

Can confirm in 21w06a.

Can confirm in 1.16.5 and 21w08b.

Here's the updated command for the fifth reproduction step:

/item replace entity @s armor.chest with minecraft:diamond_chestplate{Enchantments:[{id:thorns,lvl:7}]}

Can confirm in 1.17.1. I'd like to request ownership of this ticket since the current reporter has been inactive since June 2019. I'm willing to provide all of the necessary information and will keep this report updated.

TheFox231

Avoma

(Unassigned)

Confirmed

Player

Minecraft 1.14.3, 1.16.1, 20w28a, 1.16.2, 20w51a, ..., 1.21, 1.21.3, 1.21.4, 25w08a, 1.21.7

Retrieved