Could my Datastore corrupt if I migrate to latest update?

Hi guys , I have a quick and basic question.
My game have auto-save for every 3 minutes and can also be manually saved.
What if while the Datastore is saving a player’s data . The server suddenly shutdown (by the dev) ?
My datastore works like every other one (pcall is used)

If you make it where you save the player’s data once the player leaves, it MAY still save it. I am not entirely sure, but I am pretty confident that this would work.

In order to do this it is simply using the event PlayerRemoved as follows; game:GetService(“Players”).PlayerRemoved

If you, or anyone else, finds something that disproves this, please let me know!

Use

game:BindToClose()
void BindToClose(Function function);
3 Likes