mojira.dev
MC-303150

Can't lay in bed during the day even with "can_sleep" set to "always" and "playerSleepPercentage" set to 101+

To reproduce:

  • Install the attached data pack to a world. The pack modifies the vanilla “overworld.json” dimension type so that the “minecraft:gameplay/bed_rule” attribute’s “can_sleep” value is set to “always”.

  • Set the “playerSleepPercentage” game rule to 101 so that skipping time with beds is impossible.

  • Right click on a bed. The player will be instantly kicked out of the bed.

The expected result is that the player will lay in the bed indefinitely until they choose to get up. This is what happens when players lay in a bed at night and the playerSleepPercentage quota isn’t met, so it’s inconsistent that the same behavior doesn’t apply during the daytime.

Allowing the player to lay in beds during the day is valuable for data packs who want to use the player’s sleeping state to execute certain commands regardless of time of day. It can also be used for players to roleplay taking a rest. Because of this, I think it’s important for this behavior to be changed.

Attachments

Comments 0

No comments.

scheineraustin

(Unassigned)

Plausible

Platform

Normal

Commands, Data Packs

25w42a

Future Update

Retrieved