✓ Accepted answer
Noticed that there was a mistake in my code below. Just fixed it. Mine should work.
Three Errors:
- You're better off using a LocalScript.
- You typed "Mouce" instead of "Mouse."
- Parent needs a capital P.
Okay, first of all, are you using a LocalScript? If not, you should. Let me re-do your code for you.
Put this code in a LocalScript in the place where you put your current script:
EDIT: Simplified the below code
function click()
game.Players.LocalPlayer.Character.Humanoid.Health = 0
end
script.Parent.MouseButton1Click:connect(click)
That should do it.
5 comments
devChris, Thanks!
No problem. Care to accept my answer?
I already did, but, do I need frames?
You don't need frames.
Oh. SOme guy said I needed frames