The Bug:
"minecraft.custom:minecraft.damage_dealt" doesn't increase when the thorns enchantment damages entities.
Steps to Reproduce:
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
Summon a husk, attack it and take note of how the scoreboard increases.
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}]
Switch into survival mode and allow the husk to damage you.
Wait for the thorns enchantment to damage the husk.
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
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}]}
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}]}
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