This script is supposed to make the parts of a tree un-anchored if one of the parts is removed, but the script doesn't work and I don't get any error messages... Any idea what I did wrong? I'm thinking it has to do with line 5 but i'm not sure. Thanks guys!
local Tree = script.Parent
local parts = Tree:GetChildren()
local Wood = Tree:FindFirstChild("Med Wood")
-----------------------------------------------------------------
Tree.ChildRemoved:connect(function()
wait(2)
for index, child in pairs(parts) do
if child:isA("Basepart") then child.Anchored = false
end
end
end)
