Touch Event Inside Cloned Models Not Working

Good day, I have a model of my player, located inside the replicated storage for cloning to the workspace, with a simple touch event script that kills a player but for some reason it doesn’t fire? Is there a reason why the script doesn’t work on the cloned models?

1 Like

Are you using a local script or server script? If you do use serverscripts, Are you use the .Touched event is “connected” to a part and NOT a model? (I am talking about: script.Parent.Touched)

I placed a server script inside the model.

Here’s what my script looks like:
local body = script.Parent

local body = script.Parent
    body.Touched:Connect(function(hit)
    		if hit.Parent.Humanoid then
    		hit.Parent.HUmanoid.Health = 0
    	end
    end)

no errors?

coud be the misspelled "HU"manoid

2 Likes

It’s Humanoid, not HUmanoid (unless you have a custom humanoid).

2 Likes

Miscapitalized “HUmanoid” and Models cannot detect touch events

1 Like

Ah, thank you for telling me :slight_smile: