mojira.dev
MC-308270

Sharpness, Smite, and Bane of Arthropods do not apply to offhand spear charge attacks

Charge attacks dealt with an offhand spear do not apply Sharpness, Smite, or Bane of Arthropods. Relates to MC-304406.

Like with MC-304406, holding a mainhand weapon that has Sharpness/Smite/Bane of Arthropods causes it to apply to the offhand spear’s charge attack.

Expected Result: Sharpness/Smite/Bane of Arthropods take effect when attacking with an offhand spear via charge attack, like it does for mainhand charge attacks

Observed Result: Sharpness/Smite/Bane of Arthropods do not take effect when attacking with an offhand spear via charge attack

Linked issues

Comments 2

The problem is deeply nested, but might not be fixed, at least not anytime soon.

net.minecraft.world.entity.player.Player::stabAttack uses the getEnchantedDamage method from ServerPlayer (this could potentially be mangled due to my decompiler since it uses polymorphism) and it uses this.getWeaponItem() which in turn uses the main hand.

It’s related to MC-3304, and is likely a duplicate.

This is a duplicate of MC-3304 based on the resolution of MC-303973.

SeaOfPixels

(Unassigned)

Unconfirmed

26.1.2

Retrieved