Knockback enchantment affects arrows shot from bows, but not non-arrow projectiles
Arrows shot from a bow enchanted with Knockback will deal increased knockback when hitting a mob, consistent with the behavior for Punch. This behavior does not exist in 1.20.6 and below.
At the same time, non-arrow projectiles (snowballs, tridents) that have been enchanted with either Knockback or Punch do not have knockback applied to ranged attacks; however, Knockback is still applied to melee attacks.
This behavior extends to the minecraft:knockback data-based enchantment effect. The bug likely stems from a bow-specific implementation of Punch that has not been migrated fully to the 1.21 data-driven approach. As of 1.21pre3, there is no way to modify the knockback of a non-arrow projectile through enchantments.
Expected outcome: Knockback should not be applied to arrows shot from a bow enchanted with Knockback.
Observed outcome: Knockback is applied to arrows shot from a bow enchanted with Knockback, but not to any non-arrow projectiles.
Steps to reproduce:
- Run the following commands:
/give @p minecraft:bow[minecraft:enchantments=\{levels:{'minecraft:punch':2}}]
/give @p minecraft:bow[minecraft:enchantments=\{levels:{'minecraft:knockback':2}}] - Fire an arrow each from both bows; if the bug is present, both arrows will deal similar knockback
2024-06-02, 09:52 PM
2024-06-07, 07:20 AM
2024-06-07, 07:20 AM
1
2
1.21 Pre-Release 2, 1.21 Pre-Release 3
-