local DataStore = game:GetService("DataStoreService")
local PointsData = DataStore:GetOrderedDataStore("Points")
game.Players.PlayerAdded:Connect(function(player)
local points = PointsData:GetAsync(player.UserId)
local leaderstats = Instance.new("Folder")
leaderstats.Name = "leaderstats"
local pointsValue = Instance.new("IntValue",leaderstats)
pointsValue.Value = points
leaderstats.Parent = player
pointsValue.Name = "Strength"
end)
game.Players.PlayerRemoving:Connect(function(player)
local strength = player.leaderstats.Strength.Value
PointsData:SetAsync(player.UserId.strength)
print("Saved Data!")
end)
Please help?

3 comments
also formatted your question for you. to format your code, highlight the code you want to format and click the button with the lua logo on it above the textbox
Thanks again royal!
gucci