local canattack = true
if canattack == true then
script.Parent.Touched:Connect(function(hit)
if hit.Parent:FindFirstChild("Humanoid") then
hit.Parent.Humanoid:TakeDamage(5)
canattack = false
wait(100)
canattack = true
end
end)
end
The cool down wont work, as well as when i change the player's Max health + health to 500~~~~~~~~~~~~~~~~~ local player = game.Players.LocalPlayer local char = player.Character
char.Humanoid.MaxHealth = 500 char.Humanoid.Health = 500
after the humanoid got damaged by the part it will be lower then 100
Any clue?

4 comments
Also about the thing with health, sry i have no idea.
I tried your way but the part wont damage the player, the output shows "FindFirstChild is not a valid member of the model"
Is your script inside of a part? I have tested the same script with part in worspace and this script inside of it and it worked.
its inside a mesh part