Add multiplayer command /pause
Moderator: ickputzdirwech
- Muppet9010
- Filter Inserter
- Posts: 278
- Joined: Sat Dec 09, 2017 6:01 pm
- Contact:
Add multiplayer command /pause
Add a /pause command that can be run via console and RCON to pause and un-pause a multiplayer server.
Re: Add multiplayer command /pause
How would that work to unpause considering 70930 ?
I'm an admin over at https://wiki.factorio.com. Feel free to contact me if there's anything wrong (or right) with it.
- eradicator
- Smart Inserter
- Posts: 5206
- Joined: Tue Jul 12, 2016 9:03 am
- Contact:
Re: Add multiplayer command /pause
How about
?
Code: Select all
/c game.tick_paused = true
Author of: Belt Planner, Hand Crank Generator, Screenshot Maker, /sudo and more.
Mod support languages: 日本語, Deutsch, English
My code in the post above is dedicated to the public domain under CC0.
Mod support languages: 日本語, Deutsch, English
My code in the post above is dedicated to the public domain under CC0.
- Muppet9010
- Filter Inserter
- Posts: 278
- Joined: Sat Dec 09, 2017 6:01 pm
- Contact:
Re: Add multiplayer command /pause
Do no commands work when a server is paused? If so then that would seem to be something that could be improved as well for the normal and multiplayer commands (separate discussion).
I appreciate any commands that need to be kept in sync within the game state would not be possible while the game is paused. But if I can click a button on my client GUI that tells the server to un-pause the game and distribute that to all clients I don't see why the same couldn't apply to a specific command.
My understanding was that the relates to pausing game ticks like the editor allows, not the game paused state that you can do via the main menu.
I appreciate any commands that need to be kept in sync within the game state would not be possible while the game is paused. But if I can click a button on my client GUI that tells the server to un-pause the game and distribute that to all clients I don't see why the same couldn't apply to a specific command.
My understanding was that the
Code: Select all
LuaGameScript.tick_paused
- eradicator
- Smart Inserter
- Posts: 5206
- Joined: Tue Jul 12, 2016 9:03 am
- Contact:
Re: Add multiplayer command /pause
Exactly. And thus it doesn't suffer from the "paused server doesn't accept commands" problem. Not sure what your requirements are ofc, so if you say you need the *real* pause than that workaround doesn't work.Muppet9010 wrote: ↑Tue May 21, 2019 6:05 pmMy understanding was that therelates to pausing game ticks like the editor allows, not the game paused state that you can do via the main menu.Code: Select all
LuaGameScript.tick_paused
Author of: Belt Planner, Hand Crank Generator, Screenshot Maker, /sudo and more.
Mod support languages: 日本語, Deutsch, English
My code in the post above is dedicated to the public domain under CC0.
Mod support languages: 日本語, Deutsch, English
My code in the post above is dedicated to the public domain under CC0.