Help should I use Raycasting, GetPartsInParts or Touched for my strain signalling system

Hi,
I’m currently working on a roblox block train signalling system where the base of it is that a train touches a part to signal theyre in the block and touches another to signal they’re out of it.

I’m trying to determine which way is the best to signal a block enter/exit event

Either i should raycast, use parts in parts, or touched
I would also like to only make the block enter exit event work if a train enters from a certain way. Thanks in advance, sorry if the explaining is bad english is not my first language.

GetPartsInPart would be preferred in this case since you want to check if the train is in the area or not, especially if the train tend to despawn in the middle.

1 Like