Let me start by saying, I do have /gamerule doDaylightCycle set to False. I did this because I wanted to make the days in minecraft slower than its normal daylight cycle. I have it set up with a red stone clock and a command block adding at an increment of 5, which makes my days about 30 minutes long. The issue is, I still want to be able to sleep. I thought I could sleep like normal, but it turns out that with doDaylightCycle off, the bed does not time set back to day. Is there any work around to this issue? I dont want to speed up night time specifically, I just want to know if theres a way to do this while keeping the normal functionality of the bed.
I only have 2 ideas to make it work at the moment, but I dont know how or if it is possible to implement these ideas.
1. Is there a way to make it so that when I sleep in a bed, a command block sets time back to day?
2. If I keep /doDaylightCycle to True, is there a way I can remove time instead of adding it? Think of taking two steps forward, one step back, in order to slow down the night cycle? And if I were to do this, would it fix the functionality of the bed?
Ive looked through the Datapacks but I dont see any that talk about slowing down the daylight cycle. Ive only found one called Multiplayer sleep, which only requires a percentage of players to sleep in order to skip the night. Are you saying that this datapack would work, in order to skip the night, because it changes the functionality of the bed to work regardless of doDaylightCycle is true or false? Or, are you suggesting that there is another datapack that I am just not seeing?
/execute at @a if block ~ ~ ~ minecraft:magenta_bed run time set day
will set the time to day but it does so whether you sleep or stand on a magenta bed and I don't know how to get it to accept any color except by using 16 command blocks which shouldn't be necessary.
It's a start at least and indicates that it should be possible to get it to work the way you want, I'm just not very good at commands.
Beds have a blockstate called Occupied which is true if the player is using the bed, it would seem that that could be used to stop the time being reset to morning every time the player stands on the bed.
As for your second idea, adding a number a bit less than 24000 should set the time to a little earlier the next day, I don't know if that affects things like how soon the local difficulty increases or so but the most noticeable effect would be the time of day jumping back a bit making the day (and night unless you sleep) a bit longer.