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

How can i check if a part is collided with another part?

local Part = game:GetService("ReplicatedStorage"):WaitForChild("Part")
local RemoteEvent = script.Parent.RemoteEvent

local function onServerEvent (Player, Target, TargetSurface)
local Clone = Part:Clone()
Clone.Anchored = true
Clone.Position = Target.Position + Vector3.FromNormalId(TargetSurface)*4
Clone.Parent = workspace
end

RemoteEvent.OnServerEvent:Connect(onServerEvent)

How do i check if the clone is collided with a part?

2 answers

Sorry for the trouble, I found an answer. It's GetTouchingParts()

1 comment

0

GetTouchingParts not work with non-colliding parts

You can use part.Touched() and then check to see if the touching part is what you're looking for.

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