So, I have a clicker clicking at 0.1s speed and a datastore is saving a value, but after about 20 clicks it starts coming up with an error and stops saving the value. Help please?
function newData(statType,startingAmt,datastore,Name,Parent,player)
local test = Instance.new(statType,Parent)
test.Name = Name
test.Value = datastore:GetAsync(player.UserId) or startingAmt
datastore:SetAsync(player.UserId, test.Value)
test.Changed:Connect(function()
datastore:SetAsync(player.UserId, test.Value)
end)
game.Players.PlayerRemoving:Connect(function(player)
datastore:SetAsync(player.UserId, player.stats[Name].Value)
end)
end

1 comment
This is because you are sending too many requests to the datastore server. This is to prevent the data store server from crashing due to too many requests..