Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

How can I change the player's health?

Asked by 4 years ago

Some told me to check at StarterPlayer but I don't see any properties in StarterPlayer that can change the player's health. Is there any way to do this?

1 answer

Log in to vote
0
Answered by
0msh 333 Moderation Voter
4 years ago

put this in ServerScriptService

game.Players.PlayerAdded:Connect(function(plr)
plr.CharacterAdded:Connect(function(char)
char.Humanoid.MaxHealth = 200 -- change the health
char.Humanoid.Health = char.Humanoid.MaxHealth
end)
end)
0
Thanks lad Simpletton 82 — 4y
Ad

Answer this question