The bug:
When in spectator mode, the player is able to teleport to nearby players by using the ‘Teleport to Player’ action, bound to 1 by default. Normally, a player in spectator mode is not able to teleport to other players in spectator mode, as they won’t appear on the list of valid targets they can teleport to. If a player is in any mode other than spectator while another player has the menu open, they can teleport to them. This only updates once the spectator mode menu/bar is closed and is opened again, meaning if a player is for example, in creative mode, then switches to spectator mode, other spectators are able to teleport to the player that was originally in creative mode.
Steps to reproduce the issue:
Create a multiplayer world and have another player join
On your own instance, enter spectator mode
Ensure the other player is initially not in spectator mode
Observe that you can teleport to the other player while in spectator mode
While your spectator menu/bar is still visible, have the other player enter spectator mode
Notice that you can now teleport to them, despite them still being in spectator mode
Wait for your menu to automatically close, then try teleporting to the other player, notice that the other player does not appear in the list of valid targets to teleport to
Expected result:
The list of valid targets that spectators can teleport to updates instantly
Actual result:
The list of valid targets that spectators can teleport to updates only after the spectator menu/bar automatically hides
Thank you for helping us improve Minecraft! We saved your files: