local function playerRemoving(player)
if player == tycoonOwner.Value then
tycoonClone.Parent = game.Workspace.Tycoons
for i, v in pairs(PurchasedItem:GetChildren()) do
local itemClone = v:Clone()
InfoToSave[itemClone.Name] = itemClone
end
print(InfoToSave)
tycoon:Destroy()
end
playerData:SetAsync(player.UserId, InfoToSave)
end
hello, im trying to make an autosave progress for my tycoon. But the problem is, it wont let me save the items in the datastore. What does the error means?

1 comment
Because you can't save instances inside of data store, only store properties of the instance that you need or it's name, that;s up to you.