to whitelist a part, you should use a table. Put your whitelisted parts in the table, then check if the part is in the table
Like this:
local whitelistedparts = {Part1.Part2,Part3}
boom.Hit:Connect(function(part: BasePart, _)
if not table.Find(whitelistedparts,part) then return end
part.Anchored = (part == mine) or false
if hit.Parent:FindFirstChild("Humanoid") then
hit.Parent.Humanoid.Health = 0
end;
Debris:AddItem(part,5)
end)
local whitelistedparts = {Part1.Part2,Part3}
boom.Hit:Connect(function(part: BasePart, _)
part.Anchored = (part == mine) or false
if hit.Parent:FindFirstChild("Humanoid") then
hit.Parent.Humanoid.Health = 0
end;
if not table.Find(whitelistedparts,part) then return end
Debris:AddItem(part,5)
end)
whitelisting means that the parts in the table are the only ones that are being added to debris
did you mean blacklisting? because it means that it will add anything except the parts from the table to debris