mojira.dev
MC-171852

Putting item in a spectator's hand plays sound "Gear equips" for other players

The bug

If you use a command to equip an item to a spectator's hands, other players can hear a noise, despite the fact spectators essentially aren't supposed to exist, let alone make noises.

It also happens for other game modes, but I'd assume it's intended to happen to non-spectators.
So yeah, if there's a command block constantly modifying a spectator's hand, it'll make really loud noises, and so I think this is a pretty bad bug.

Comments 8

Still happens in 20w07a.

Should still happen in 20w08a.

Hello Chandler. I see you have edited my ticket. Did the bug change, last time I checked it was offhand only.

I did some testing and yes, it now includes the mainhand. I also updated the game mode, added the new affects versions and confirmed your ticket 🙂

Thank you for coming through, I haven't been able to test in a very long time.

 

Here is a clip of this bug happening in a datapack that I am working on for reference: https://clips.twitch.tv/ExquisiteAuspiciousLionKAPOW

I believe that the problem comes from net.minecraft.entity.PlayerEntity#setItemStackToSlot does not check the player's gamemode before  this.playEquipSound(stack)

Thank you so much to Mojang for fixing this!!!
 

Roadhog360

coschevi

Confirmed

Low

Sound

command, inventory, multiplayer, sound

20w06a, 20w07a, 1.16.1, 20w30a, 1.16.2 Pre-release 1, 1.16.2 Pre-release 3, 1.16.2 Release Candidate 1, 1.16.2 Release Candidate 2, 1.16.2, 1.16.3

20w45a

Retrieved