datastore = game:GetService("DataStoreService"):GetDataStore("ToolStore")
game.Players.PlayerRemoving:connect(function(player)
local stats = {}
local e = 0
for i,v in pairs(player.Backpack:GetChildren()) do
e=e+1
table.insert(stats,e,v.Name)
end
datastore:SetAsync('Tool thing#'..player.userId,stats)
end)
game.Players.PlayerAdded:connect(function(player2)
local store = datastore:GetAsync('Tool thing#'..player2.userId)
if store then
for q=1,#store do
game.ReplicatedStorage:FindFirstChild(store[q]).Parent = player2.Backpack
end
end
end)
line 17, attempt to index a nil value.
That error stumps me, a copy of all the tools in the game are inside of replicated storage, so I don't see what's wrong with this.

1 comment
I did...