mojira.dev
MC-313351

Tools held by allays can drop damaged when the allays are killed

The Bug:

Tools held by allays can drop damaged when the allays are killed.

Allays drop the item they hold when they are killed. However, when a player kills an allay, the tool it holds sometimes drops with random durability lost, even though the allay never used it.

Steps to Reproduce:

  1. Obtain a netherite sword enchanted with looting by using the command provided below.

    /give @s minecraft:netherite_sword[minecraft:enchantments={looting:100}]
  2. Summon an allay with 1 health holding an iron pickaxe by using the command provided below.

    /summon minecraft:allay ~ ~1 ~ {Health:1f,equipment:{mainhand:{id:"minecraft:iron_pickaxe"}}}
  3. Kill the allay with the sword and observe if the dropped iron pickaxe has lost durability.

Observed Behavior:

Tools held by allays drop damaged when the allays are killed.

Expected Behavior:

Tools held by allays would keep their durability when the allays are killed.

Attachments

Comments 2

This is normal behavior since you didn’t specify drop_chances being set to 2, indicating a picked-up item

Avoma

(Unassigned)

Unconfirmed

Items, Mob behaviour

26.3, 26.4 Snapshot 10

Retrieved