I’m trying to patch a bug in my game, and after having patched it I want to boot people out of the affected place however the “Shut down all servers” is not working. I am in-game and it refuses to end our servers (people still walking around).
Manually doing “shut down this server” seems to work after a minute of waiting, but the response is still unacceptably slow.
I fixed server shutting down slowly by kicking all players when game.OnClose is fired - the server doesn’t actually shutdown until after everything game.OnClose does is finished, or the 1 minute timeout happens.
Edit: Players wont be able to rejoin the server while its shutting down after they are kicked.
However - kicking before doing anything else w/ OnClose will solve them shutting down slowly.
Your saving operations and such will still happen. I think OnClose might wait 60 seconds even if the operations finish before then (unconfirmed, just a theory). Kicking them in OnClose surely fixed the issue for me. My servers shutdown within 3 seconds every time.