workspace.Items.ChildAdded:Connect(function(Item) Item:FindFirstChild("TouchInterest"):Destroy() end) workspace.ChildAdded:Connect(function(Child) if Child:IsA("Tool") then wait() Child.Parent = workspace.Items end end)
all it gives is
22:53:41.851 - ServerScriptService.TouchRemover:2: attempt to index a nil value 22:53:41.852 - Stack Begin 22:53:41.853 - Script 'ServerScriptService.TouchRemover', Line 2 22:53:41.853 - Stack End
Like @Lazarix9 said, you should be using WaitForChild()
when using ChildAdded
especially in workspace. Look at this guide on the ChildAdded
event.