mojira.dev
MC-203416

Beds and respawn anchors cause lag when used

When using a bed or a respawn anchor, there is noticeable lag. This happens when the player sleeps in the bed or sets the spawn point.

This seems to happen mostly when a bed or respawn anchor is used for the first time after loading the world. After the first use, subsequent uses appear normal. It is difficult to reproduce in a newly-created world.

The issue is most likely to occur when a player uses a bed or respawn anchor for the first time when sleeping is not possible. A clear lag spike occurs before the game displays the message: "You can sleep only at night and during thunderstorms". Sometimes it happens before sleeping in a bed successfully but this is less common. It will only happen once per session.

Attachments

Comments 10

Please provide a screenshot with the F3 Debug screen enabled

A possible workaround is to use a bed in another save game, save that game, and then load up the game where the bed lag occurs. This suggests the cause of the lag is client-side.

Can Confirm, this also happens sometimes with advancements

Respawn anchors are also affected. I have amended the description to state this.

I can confirm this happens not just with beds but when anything appears in chat for the first time after loading a world, whether it's an advancement or "respawn point set" or just sleeping in a bed. This consistently happens every time a world is loaded, but only for the first time something would come up in chat.

Can confirm, trying to sleep on bed causes lag spike

This bug has stopped happening for me for some reason.

Can confirm in 1.17.1.

For me, this seems to have been fixed in the first 1.18 snapshot. Is anyone still experiencing this?

bdm68

(Unassigned)

Community Consensus

(Unassigned)

1.16.4, 1.17.1

Retrieved