Is there just any way to save a Folder containing many bool values with DataStore? (Something else than leaderstats, wow.) I've tried many codes but haven't gotten a result.
This is the last code i've used, at least i haven't gotten any errors but no results on it either.
local datastore = game:GetService("DataStoreService"):GetDataStore("GameStore") local Stats = nil local Weps = nil local Foxes = nil
game.Players.PlayerAdded:connect(function(plr)
if plr:FindFirstChild("Stats") == nil then Stats = script.Stats:Clone() Stats.Parent = plr end if plr:FindFirstChild("UnlockedWeapons") == nil then Weps = script.UnlockedWeapons:Clone() Weps.Parent = plr end if plr:FindFirstChild("UnlockedFoxes") == nil then Foxes = script.UnlockedFoxes:Clone() Foxes.Parent = plr end
local key = "user-" .. plr.userId local storeditems = datastore:GetAsync(key) if storeditems then Stats = storeditems[1] --Value of the Points, change "points" if you changed line 10 Weps = storeditems[2] --Value of the Wins, change "wins" if you changed line 14 else local items = {Stats, Weps} --Change Points or Wins if you changed line 10 or 14 datastore:SetAsync(key, items) end end)
game.Players.PlayerRemoving:connect(function(player) local items = {Stats, Weps} --Change Points or Wins if you changed line 10 or 14 local key = "user-" .. player.userId
datastore:SetAsync(key, items)
end)

3 comments
Didn't really help.
Why doesn't it help? It saves your players data. Of course you have to integrate it with DataStore yourself though.
If you don't know how to make DataStore work the I'd recommend reading Data Store