Space Engineers

Space Engineers

Sleep Mod
200 Comments
Mr. X WeregλrurumonX Jan 15 @ 8:55pm 
@haniah - Does NOT work with Real Solar Systems.
NotOkDoc Jan 5 @ 2:02pm 
It doesnt work on normal beds
Hanniah (she/they) Dec 24, 2024 @ 2:27pm 
Does anyone know how this works or not with Real Solar Systems?
ExCaedibus Oct 19, 2024 @ 1:08pm 
Using the cryo pod for other things like recharging and logging off... Can you perhaps put the sleeping thing to the bed blocks, please? When you are updating. That would be great, thank you.
[82DK] wyomingwolf May 16, 2024 @ 6:46pm 
Nvm, does change the time yet no message of sleeping.
[82DK] wyomingwolf May 16, 2024 @ 5:36pm 
Think recent update broke the mod, not able to sleep through night
Meya Mar 23, 2024 @ 4:36pm 
This game used to do this without a mod or maybe that had a mod I remember going into cryopod in first survival world and it'd do that with the sun was so nice
Zen_Man Dec 27, 2023 @ 11:37am 
Useless for me as time does not progress (devices do not continue to work).
ButtKraken Oct 31, 2023 @ 1:26pm 
The world loads fine on the next game load, first load in does this.
ButtKraken Oct 31, 2023 @ 1:25pm 
Exception occurred: System.NullReferenceException: Object reference not set to an instance of an object.
at Zkillerproxy.SleepMod.CryoCommunication.occupiedCryoCount()
at Zkillerproxy.SleepMod.Server.sleep()
at Zkillerproxy.SleepMod.Server.UpdateBeforeSimulation()
Crowigor Sep 4, 2023 @ 5:16am 
Great mod. It would be nice to add a question when the character lies down. "Do you want to skip time? Yes/No"
Patrick Jul 27, 2023 @ 6:22pm 
Had a random crash. Here's the stack trace. Oddly enough, I don't have any cryopods in the world. About 15 minutes prior I deleted a bunch of MES entities, so it's possible there were cryopods on some of them. Regardless, just fyi, this occurred. Feel free to visit my discord if you want to troubleshoot.
[code]
Exception occurred: System.InvalidOperationException: Collection was modified; enumeration operation may not execute.
at System.ThrowHelper.ThrowInvalidOperationException(ExceptionResource resource)
at System.Collections.Generic.List`1.Enumerator.MoveNextRare()
at Zkillerproxy.SleepMod.CryoCommunication.occupiedCryoCount()
at Zkillerproxy.SleepMod.Server.sleep()
at Zkillerproxy.SleepMod.Server.UpdateBeforeSimulation()
[\code]
Ashes Vargrand Jul 18, 2023 @ 3:15pm 
hi, its a nice mod.

can i change the 10km range from other players? so i can serverwide go sleep?
KagedDaemon Jun 27, 2023 @ 11:56am 
@knight it advances time by uping the timescale while the player(s) are in Cryopods
KagedDaemon Jun 27, 2023 @ 11:54am 
Not entirely sure WHY people want to sleep in space... but I found out how to make it so. Go to

"[install drive:\Steam\steamapps\workshop\content\244850\1780376231\Data\Scripts\Zkillerproxy\SleepMod"
then find the line for
"if (IsNearPlanets(players[0].GetPosition(), out planet, out planetPosition) == false)"
change to
"if (IsNearPlanets(players[0].GetPosition(), out planet, out planetPosition) == true)"
and then just load the game!
yes I am aware this is a Necro, but peoples asked and I answered.
Knight Before Dawn May 27, 2023 @ 2:11pm 
I'm just curious how this mod works.

Assuming all players are in bed/cryo-pod:
Does it advance the time by X hours?
Does it skip time ahead specifically to X time?

If the latter how does the game calculate time? Is it based on where you are with relation to the nearest planet compared to the solar angle or is it a global time variable that could consider 7:00 am to be what is actually sunset in your particular location?
Myst Leissa Apr 29, 2023 @ 2:27pm 
@NeverKlever, which Life Support Mod are you using? I'm aware of two supported ones and qutie a few unsupported ones...
Peekofwar Apr 16, 2023 @ 12:26pm 
@NeverKlever Dying of thirst? That must be a mod, since SE doesn't have a thirst meter.
NeverKlever Mar 6, 2023 @ 5:37pm 
think this mods needs update with stasis effects. died of thirst in a cryo pod and looking into why and how this happen. thanks this mod is awesome for planet fall but if its changing stasis effects when inside need to remove mod so im not dieing of thirst.
Storm Feb 24, 2023 @ 3:18pm 
Does Eat Sleep Repeat have issues with this mod?
Deltalead45 Feb 20, 2023 @ 2:45am 
@Patrick
1: no
2:no
3: no
4: no.

its just a trigger to move the time of day slider.
Patrick Nov 30, 2022 @ 12:22pm 
Hello, I like this mod and have been using it for awhile. Can you clarify some things?

1. Are refineries and assemblers updated as if they were producing for the time you were asleep? Consuming and producing amounts of resources accordingly?

2. Do batteries, reactors, etc, update their power and fuel as if they had been running for the time you were asleep?

3. Do H2 Engines consume hydrogen (and charge batteries) in an amount as if they had been running for the time you were asleep?

4. Are batteries drained as if they'd been used for the time you were asleep? For example, if I had a craft hovering on atmospheric thrusters with 1 hr of flight time remaining and I go to sleep for 4 hours, what happens? Does that craft run out of power and fall?
Miki Oct 20, 2022 @ 9:38am 
i have found a bug with the mod being used on externally hosted servers. the long short is wen ever you sleep skipping the night and then all plays are logged off it resets the server. i love the mod for skipping the nights but its not server ready for hosts such as host havoc
Ranos Sep 30, 2022 @ 1:43am 
@Dude_Geode_Miner It does.
Dude_Geode_Miner Sep 19, 2022 @ 12:17pm 
i do not like being THAT dude, But is this still working for singalplaer?
Druark Jul 11, 2022 @ 7:47am 
@Nagrom, save games can have mods enabled. You have to disable it in there as well or it will keep trying to reinstall it to maintain dependencies for the save.
N4GR Jun 17, 2022 @ 2:29pm 
This mod is a virus for your dedicated server, it doesn't matter if you remove the mod from the configs, delete the sleep config or even delete it from the workshop folder, it'll sneak its way back in and automatically download without your permission. :winter2019happydog:
xXTopGunXx May 13, 2022 @ 10:49pm 
This sleep mod doesn’t show up in my script list anymore is there something wrong with it or something in my game is it working for anyone else ?
<†>Baigle1<†>™ Apr 22, 2022 @ 3:41pm 
This needs to be vanilla. Dependency handling, ordering, and bundling is also a major issue when adding mods to a world.
w00kie Apr 15, 2022 @ 6:35am 
@Urist look at Skallabjorns comment one or two pages back. You can edit the numbers directly in the skript
Urist Apr 7, 2022 @ 12:17pm 
Is there any way to adjust the wake-up time? With my day settings, it currently wastes like an hour of daylight.
Capt Fuzzy Apr 5, 2022 @ 2:54pm 
Ok, just a little update:
The "1 player not in cryopod" is still happening, but it does allow me to sleep at some point.
That point is kinda random, but somewhere in the neighborhood of 9 pm, give or take a few minutes.
Any ideas as to why this is happening?
Capt Fuzzy Mar 28, 2022 @ 12:11pm 
Got a question for ya.., how is it possible that my friends are all in cryo-pods and I'm the last one in and I get a message saying: 'Cannot sleep, 1 player not in cryo-pod.
It's worked well when it's just me in a world, but it seems that whenever someone joins me, this little problem crops up and I cannot sleep.
Quickhand69er Mar 22, 2022 @ 11:27pm 
@Skallabjorn Thank you. Steam\steamapps\workshop\content\244850\1780376231\Data\Scripts\Zkillerproxy\SleepMod
To make it a little easier for some.
Kaito Dec 30, 2021 @ 9:49am 
Sleeping through storms would be rad
Chronos "Salty" Pliskin Nov 7, 2021 @ 6:16am 
Is this compatible with mods like Daily Needs and Eat. Drink. Sleep. Repeat! mod?
Diego Oct 31, 2021 @ 12:45pm 
@Zifir IMyCryoChamber its a info for modders. Its a class they can extend to let a block have the same function (really simplified)
Grebanton1234 May 6, 2021 @ 6:54am 
If you sleep and then leave the game there will be a error message when starting the game again. To get back in game you need to start a backup. Im not sure if this issue is caused only by the sleep mod because i have other mods installed aswell
KAIZEN Apr 17, 2021 @ 3:37am 
What is IMyCryoChamber? I could not find that if It is a mod in workshop
NeonDrip Dec 23, 2020 @ 6:00pm 
I wish we could change the wake up value @Skallabjorn mentioned from in the game
like how the noises can be instead of having to dig into the files,
something like /SleepMod WakeTime [## Time in 24hour format]

noise toggle command for reference
/SleepMod EnableNoises [True/False]
Skallabjorn Dec 6, 2020 @ 2:04pm 
@wolfrt if you go into the mods folder , in the scripts subfolder there is a script called server.cs. Line 37 you can change the times from 7 am and 5 pm ( 7 and 17 ) to whatever you want in military time )
ChozoSR388 Sep 28, 2020 @ 12:55am 
Dude, can we please sleep in space? And to answer the in mod question, all it takes is a clock (which we already have, thanks to HUD compass), and a little common sense (i.e.: Well, I slept sixteen hours ago, so, I might as well do it again!) to tell day from night. Turns out humans are actually pretty good at it.
wolfrt Sep 26, 2020 @ 7:04am 
Would it be possible to change the wake up time? Id kind of like to be up at the crack of dawn...
Cyr0 Sep 21, 2020 @ 5:42am 
@JW_GROM "Any block that extends from IMyCryoChamber is a valid Cryo Pod for sleeping, this includes beds and modded beds/Cryo Pods."
Right out of the description.
Pafnucy Aug 31, 2020 @ 2:31am 
Would it be possible to add configurable distance other than 10km?
Ostre Wasy Jul 29, 2020 @ 11:46am 
Can this work with beds from DLC or Modders like Eikester???
tlc09387 Jul 26, 2020 @ 3:54pm 
Thanks so much for the help @Zkillerproxy! I have no idea how that may have happened, unless it was the way that I pasted the world in using the creative tools. *shrug* I do appreciate the prompt responses, though. I'd give you beer/coffee money, but I don't see a donation link, so I just gave this and the compass mods a couple awards from steam... :steamhappy:
Zelious  [author] Jul 25, 2020 @ 11:36pm 
@tlc09387 I think I've fixed it, your world was using some strange custom sun rotation that basically had the sun twisting around the 'north' direction of the world. The changes I've made to this mod, and also to the HUD Compass since they use the same code, should have it adjust for that correctly now.

It is also possible that, in the process, I've managed to break it for other worlds with exotic sun rotation settings. I've tested with a normal world and it was still working fine. I'll just have to wait and see if it get tens of angry comments overnight.

And BTW SE workshop worlds come with their mod list which will automatically be downloaded, for all intents and purposes you can ignore steam and its mod management stuff.
tlc09387 Jul 25, 2020 @ 8:42pm 
@Zkillerproxy I uploaded a copy of the world for you to the steam workshop: https://steamcommunity.com/sharedfiles/filedetails/?id=2177987924

I made a pared down mod list, that will ensure just that nothing will be removed from the world when loaded, and confirmed that the bug is still occurring. I'm not sure how the steam workshop does the mods on a save, whether it will only force the ones I listed, or all of the mods that were associated with the world when I published it. But, either way I hope it will help you with the troubleshooting.
Zelious  [author] Jul 24, 2020 @ 10:07pm 
@tlc09387 I usually use a similar number of mods myself XD, I would quite like to have a look anyway since this mod should be impossible for other mods to break (due to how it interacts with SE), as such there is a good chance this is a bug I need to squash.