``I made a trashcan where when you touch a part the items in your inventory gets removed but it doesn't seem like to work but I have no errors in the output so I don't why it's not working.
playa = game.Players.LocalPlayer
backpacka = playa.Backpack
script.Parent.Parent.Touched:connect(function(p)
if backpacka then
for _,v in ipairs(backpacka:GetChildren()) do
if v:IsA('Tool') then
v:Destroy()
end
end
end
end)

2 comments
This script is a localscript And as seen its in the workspace Localscripts dont run there they only run in the player or if its a decendant of the players character otherwise they just wont run
Is your game filtering enabled or not?