Allow the OS to sleep/hibernate when the (singleplayer) game is paused

Ideas that are too old (too many things have changed since) and ones which won't be implemented for certain reasons or if there are obviously better suggestions.

Moderator: ickputzdirwech

Post Reply
nir.hershko
Manual Inserter
Manual Inserter
Posts: 3
Joined: Fri Jun 08, 2018 6:54 pm
Contact:

Allow the OS to sleep/hibernate when the (singleplayer) game is paused

Post by nir.hershko »

I'm currently on Factorio 1.1.50 from Steam on Windows 10, single player (with mods but I don't think it matters).

While factorio is running, Windows doesn't turn off the screen even when idle (which makes sense). I'd like it to allow Windows to turn off the screen and sleep if the game is paused.

More words below, but not much new information so don't read the rest if you don't want to.
My setup is that I often pause the game to do something else without knowing when I will return - could be 1 minute, could be the next day (I have kids you see..). Today I just found that even though I `WinKey-D`-ed to the desktop (while the game is paused), it just stayed like that for many hours without turning off the screen and computer (wasting computer and screen power, and possibly burning the pixels a bit, though that's negligible compared to the factorio UI that's burned there :P ). Now, I already knew that it doesn't allow Windows to sleep, and didn't expect it, but still it would've been real nice if it did anyway and i didn't have to know in advance for how long i'll be gone. After all, that's what the automatic sleep feature is for in the first place.

Related post: viewtopic.php?p=453123#p453123 (for headless, Aug 2019, got no answer as of now). It _feels_ like this one (single player case) is simpler to implement, and probably useful to more people.
Related thread: viewtopic.php?f=49&t=71018 (has a suggested fix which i didn't try because it ignores whether the game is paused; my powercfg btw: https://pastebin.com/raw/3B6Ggm3N)

Rseding91
Factorio Staff
Factorio Staff
Posts: 13937
Joined: Wed Jun 11, 2014 5:23 am
Contact:

Re: Allow the OS to sleep/hibernate when the (singleplayer) game is paused

Post by Rseding91 »

Letting the OS automatically go to sleep while a high-CPU high GPU application is running makes no sense. Additionally letting the OS sleep while the game is running messes up the GPU resources the game is using on some systems and so we won't be allowing it automatically.

You can still manually force the OS to sleep by clicking the start menu, power, and clicking "sleep".
If you want to get ahold of me I'm almost always on Discord.

User avatar
ssilk
Global Moderator
Global Moderator
Posts: 12889
Joined: Tue Apr 16, 2013 10:35 pm
Contact:

Re: Allow the OS to sleep/hibernate when the (singleplayer) game is paused

Post by ssilk »

Hm, I think the question is not, if, but why Factorio eats so much CPU/GPU, when paused.

For example: When I let my notebook run with Factorio in background it eats the batteries empty within 1-2 hours, but effectively does nothing, but steadily displaying drawing a static picture.

Would be simple to make a screenshot and do the same with my screensaver. :)
Cool suggestion: Eatable MOUSE-pointers.
Have you used the Advanced Search today?
Need help, question? FAQ - Wiki - Forum help
I still like small signatures...

nir.hershko
Manual Inserter
Manual Inserter
Posts: 3
Joined: Fri Jun 08, 2018 6:54 pm
Contact:

Re: Allow the OS to sleep/hibernate when the (singleplayer) game is paused

Post by nir.hershko »

For me (AMD 2600X) it takes <2% CPU when paused (and <3% cpu when running what I'm currently playing), and it's using <1% GPU resources (both paused and not). It can go to sleep and come back with no problem, so I'd definitely turn on such an option if it was available.

FuryoftheStars
Smart Inserter
Smart Inserter
Posts: 2768
Joined: Tue Apr 25, 2017 2:01 pm
Contact:

Re: Allow the OS to sleep/hibernate when the (singleplayer) game is paused

Post by FuryoftheStars »

Afaik, sleep & hibernation are not perfect. The more complex the application running, the greater the chance of issues. As Factorio lives largely in memory and is very complex, I'd expect the chances of issues to be high.

As Rseding91 mentioned, though, you can still manually put your PC to sleep if you desire (many computers have a dedicated button for this on the keyboard, and Windows has it in the Start menu -> Power options) and see what happens after repeated sleep/wake cycles. I would advise also saving before each one, and maybe occasionally doing a test load to make sure that something didn't get corrupted that was only detectable during load. (Actually makes me wonder if some of these folks with magical save file corruptions are actually doing this....)

Ultimately, if the devs do include it, I'd half expect them to have the option disabled by default and located in the hidden "the rest" settings section with the "won't support" disclaimer.
My Mods: Classic Factorio Basic Oil Processing | Sulfur Production from Oils | Wood to Oil Processing | Infinite Resources - Normal Yield | Tree Saplings (Redux) | Alien Biomes Tweaked | Restrictions on Artificial Tiles | New Gear Girl & HR Graphics

Post Reply

Return to “Outdated/Not implemented”