So I have this script:
local passid = 972737920
local tools = {"BlueFidgetSpinner"}
local GamePassService = Game:GetService('GamePassService')
game.Players.PlayerAdded:connect(function(player)
repeat wait(0.1) until player.Backpack
repeat wait(0.1) until player.StarterGear
if GamePassService:PlayerHasPass(player, passid) then
for i = 1,#tools do
game.Lighting:FindFirstChild(tools[i]):Clone().Parent = player.Backpack
game.Lighting:FindFirstChild(tools[i]):Clone().Parent = player.StarterGear
end
end
end)
and for some reason, it's telling me: "Backpack is not a valid member of Player". Player does have a backpack though. So does anyone know how i could fix this?

1 comment
you could do player:WaitForChild("Backpack") since that makes sure it exists