My datastore system works fine, I have it so when I'm unable to get the datastore (if it's failing or down) it kicks the player, however recently datstores failed and I was kicked but my data was still overwritten. Should I be kicking players or not? What is the best way to handle errors from roblox?
Wrap all datastore requests in pcall like so:
local success, message = pcall(function() Datastore:SetAsync(key, data) end) if not success then -- If the datastore failed, you should retry saving this player's data. warn("Datastore failed, retry saving the players data.") else -- Everything worked! print("Datastore worked, saves stats accordingly.") end