I'm very new to scripting, I'm working on a tool that inserts a click detector in every brick locally. (So every brick I can click.) This is what I only have so far.
script.Parent.Equipped:Connect(function() game.Workspace:GetChildren() end)
Any help would be appreciated, thanks!
script.Parent.Equipped:Connect(function() -- Whenever the tool is equipped this will fire/ for _,v in pairs(workspace:GetChildren()) do -- Get everything is workspace. local cd = Instance.new("ClickDetector") -- Make a new item *click detector* cd.Parent = v -- Put the item in all items that are in workspace *v* cd.Name = "Click" -- Rename the item to "Click" end end)