mojira.dev
MC-196714

Attempting to mine a block while holding a sword/trident in Creative mode resets attack cooldown, but doesn't display attack indicator

The bug

When holding a sword or trident in Creative mode, clicking on a block resets the attack cooldown. However, the player is not informed of this as the attack speed indicator does not appear.

How to reproduce

  1. Ensure you are in Creative mode

  2. Give yourself a sword that deals 10 attack damage and has a slow attack speed:

    /give @s diamond_sword[attribute_modifiers={modifiers:[{amount:9,name:attack_damage,operation:add_value,type:generic.attack_damage,uuid:[I;1,2,3,4]},{amount:-3.5,name:attack_speed,operation:add_value,type:generic.attack_speed,uuid:[I;5,6,7,8]}]}]
  3. Spawn two cows

  4. Attack the first cow with the sword when the attack meter is full
    → ✔ The cow is killed

  5. Click on a block with the sword when the attack meter is full
    → ❌ The attack speed indicator is not displayed

  6. Immediately attack the second cow
    → ✔ The cow is not killed

Linked issues

Comments

Avoma

Can confirm in 21w06a.

Avoma

Can confirm in 21w11a.

Avoma

Can confirm in 1.18.1 and 22w05a.

Avoma

Can confirm in 1.19.

j_p_smith

(Unassigned)

Confirmed

Gameplay

Low

Player

Minecraft 1.12, Minecraft 1.12.1, Minecraft 18w14b, Minecraft 18w20a, Minecraft 18w22a, ..., 24w11a, 24w12a, 1.20.6, 1.21, 1.21.3

Retrieved