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

How would you fire an event when a part touches another part?

I want an event to fire whenever a part touches another part. I've tried Instance.Touched for this, but that seems to only work when a player touches it. What should I do?

1 comment

0

Provide your script.

1 answer

Hopefully this helps!

local part1 = game.Workspace.Part1
local part2 = game.Workspace.Part2 

part1.Touched:Connect(function(hit)
	if hit == part2 then 
		print ("Touched!")
	end
end)

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