Here is my code:
for i,v in pairs (game.Workspace:GetChildren()) do if v.Name == "Bricktops" or "Pitgrounds" then v:remove() end end
But the line:
v:remove()
Is wrong, How do i remove multiple items at once?
for i,v in pairs (game.Workspace:GetChildren()) do if v.Name:lower() == ("Bricktops"):lower() or v.Name:lower() == ("Pitgrounds"):lower() then v:remove() end end
for i,v in pairs (game.Workspace:GetChildren()) do if v.Name == "Bricktops" or "Pitgrounds" then v:Destroy() end end
Destroy()
Would be the correct term.
That isnt the problem here, although I agree that :Destroy is better than :remove()
for i,v in pairs (game.Workspace:GetChildren()) do if v.Name == "Bricktops" or v.Name=="Pitgrounds" then v:Destroy() end end