I am having an issue when you throw the object, it clones and when it hits a player, it is supposed to damage them. It is a .Touched() function. Any Help?
The Code:
local part = script.Parent local damage = 10 part.Touched:Connect(function(hit) if hit.Parent:FindFirstChild("Humanoid") then local humanoid = hit.Parent:FindFirstChild("Humanoid") humanoid:TakeDamage(damage) end end)
I was using the clone script through the client, so I used a remote event and switched scripts over. I used the client for animations and I used the remote event to get the mouse position.