Touched not detecting an object its clearly in contact with

I have a touched event that triggers when a hitbox detects contact with a hurtbox.
However, it doesn’t happen consistenly for some reason.

Here’s the output (server)
These were taken when the player is in very close proximity to the opponent, so on paper, all of these hits should be detected
The script prints the player the hitbox belongs to and then prints the hurtbox it makes contact with.
The rest of the script doesn’t continue if it makes contact with the owner’s hurtbox, so there’s no need to worry about that
The hitbox fails when it doesn’t register the other player and doesnt print “hit player2”.


	if hitActive then
		print(hitboxOwner.Name .. " " .. touched.Parent.Parent.Name)
		if touched.Parent.Parent ~= hitboxOwner then
			touched.Color =, 0, 0) --Changes color of hurtbox
			print("hit "..touched.Parent.Parent.Name)
			hitActive = false
			hitboxOwner.Pause.Value = true
			touched.Parent.Parent.Pause.Value = true
			RCEvent:Fire(nil, 0.1) --Pauses animations
			touched.Color =, 0.666667, 0) --Returns the color of hurtbox
			hitboxOwner.Pause.Value = false
			touched.Parent.Parent.Pause.Value = false

What causes touched to be so inconsistent? Is there a way around it?

Try using a different method than Touched, that method is quite janky to work with. How about raycasting instead? :thinking:


How would I go about it? Can I still use the hitboxes shown from the video?

The boxes will be kept, but the raycasting should cast from the point you start hitting followed up by checking if the cast actually hits the hitbox.

It sounds like rays are a one dimensional thing
Is it possible for raycasting to cover a Vector3 space like the hitboxes?

It should possible, considering that raycasting is used in FPS games and sometimes melee-based games.