Saving the server information correctly

My game is divided into servers that I have allocated in advance. Players can only connect to them

The task is to save the state of each server, according to the type of location of players, buildings, and everything. That is, even if the server closes, its data must be saved in the data store so that all information about it is loaded before starting this server

I am familiar with the Data Store, but I want to find out what nuances there may be, what errors may occur

Can the server data not be saved in time before closing the server?

1 Like

saving on game:BindToClose() should work just fine for your case
You get around 30 seconds to save all the data you need - it should be enough time
But you can also save periodically, for example every 10 minutes or so, just to be sure

2 Likes

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.