is this why my datastore doesnt work? No Errors Its a Warning
local DSService = game:GetService("DataStoreService"):GetDataStore("Normalslots")
game.Players.PlayerAdded:Connect(function(player)
local uniquekey = "id-"..player.userId
local leaderstats = Instance.new("Folder")
leaderstats.Name = "leaderstats"
leaderstats.Parent = player
local Clicks = Instance.new("IntValue", leaderstats)
Clicks.Name = "Clicks"
Clicks.Value = 0
local Prestiges = Instance.new("IntValue", leaderstats)
Prestiges.Name = "Prestiges"
Prestiges.Value = 0
local Coins = Instance.new("IntValue", leaderstats)
Coins.Name = "Coins"
Coins.Value = 0
local GetSaved = DSService:GetAsync(uniquekey)
if GetSaved then
Clicks.Value = GetSaved[1]
Prestiges.Value = GetSaved[2]
Coins.Value = GetSaved[3]
else
local NumbersForSaving = {Clicks.Value, Prestiges.Value, Coins.Value}
DSService:SetAsync(uniquekey,NumbersForSaving)
end
end)
game.Players.PlayerRemoving:connect(function(player)
local uniquekey = "id-"..player.userId
local Savetable = {player.leaderstats.Clicks.Value, player.leaderstats.Prestiges.Value, player.leaderstats.Coins.Value}
DSService:SetAsync(uniquekey,Savetable)
game:BindToClose(function()
local RS = game:GetService('RunService')
if RS:IsStudio() then return end
for _, player in ipairs(game.Players:GetPlayers()) do
end
end)
end)

2 comments
Why can't you search that on google? Literally 20 posts on that. Anyway, datastores have a limit, and when that limit is reached, roblox throws that warning.
agree, there are actually more than 20 posts on this, like half a billion