Here is my datastore. It didnt save my data at all or print anything
local DataStoreService = game:GetService("DataStoreService") local NewData = DataStoreService:GetDataStore("myDataStore") game.Players.PlayerAdded:Connect(function(player) local data = Instance.new("Folder") data.Name = "data" data.Parent = player local eggs = Instance.new("IntValue") eggs.Name = "eggs" eggs.Parent = data local info local success, errormessage = pcall(function() data = NewData:GetAsync(player.UserId.."-eggs") end) if success then eggs.Value = info else print("There was an error whilst loading your data") warn(errormessage) end end) game.Players.PlayerRemoving:Connect(function(player) local success, errormessage = pcall(function() NewData:SetAsync(player.UserId.."-eggs", player.data.eggs.Value) end) if success then print("eggs saved") else print("eggs not saved, error") warn(errormessage) end end)