Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
✓ ANSWER ACCEPTED

Tool that opens a door?

I need help with making a Sonic Screwdriver open a door. Any ideas?

1 answer

✓ Accepted answer

Something like this might work as an outline if it is in a LocalScript inside the tool and the door is a model called Door:

local mouse = game.Players.LocalPlayer:GetMouse()
script.Parent.Activated:Connect(function()
	local targ = mouse.Target
	if targ and targ.Parent.Name == "Door" then
		for _,v in pairs(targ.Parent:GetDescendants()) do
			if v:IsA("BasePart") then
				v.CanCollide = false
				v.Transparency = 0.5
			end
		end
	end
end)

This discussion is preserved as it was. New answers, comments, and votes are closed.