I already know that parts and things such as that cannot be saved in a DataStore!
- I am new (Today new) at Data Stores so I'll probably have "newb" mistakes.*
I am basically testing DataStores to see if I know how to even do them yet I don't appear to be joining with a change in my Stage . I have 3 scripts, 1 that will save data when you leave, one that uses the data when you join(if any) and the last one that uses
OnCloseso I can keep the server open when it's suppose to shutdown for Data Saving.
Here's the Added script:
game.Players.PlayerAdded:connect(function(plr)
local DS = game:GetService("DataStoreService"):GetDataStore(plr.Name)
plr:WaitForChild("leaderstats"):WaitForChild("Stage")
if DS:GetAsync(plr.Name) ~= 0 then
plr.leaderstats.Stage.Value = DS:GetAsync(plr.Name)
else
print(plr.Name.."Doesn't Need Data Transfer")
end
end)
Here's the Leaving script:
game.Players.PlayerRemoving:connect(function(plr)
local DS = game:GetService("DataStoreService"):GetDataStore(plr.Name)
local Key = plr.Name
if plr.leaderstats.Value == 0 then
print("Ignore Data Save For "..plr.Name)
elseif plr.leaderstats.Value >= 1 then
DS:SetAsync(Key, plr.leaderstats.Stage.Value)
end
end)
Here's the OnClose script:
game.OnClose = function()
wait(3)
end
Please don't shy from sharing information so I may better myself in Data Stores.

4 comments
Please stop Posting the Same question.
@TheContinentofEurope , There's no rule against a re-post. I also deleted the existing question before this was created. This is only the second time as well. (Take notice of the person who has post the same question 3-4 times just a small rewording once)
Please stop posting the same question....
It's Technically different. Not talking about an error. Not the same header either