Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local player = game.Players.LocalPlayer
- local character = player.Character or player.CharacterAdded:Wait()
- local humanoid = character:WaitForChild("Humanoid")
- local text = script.Parent
- humanoid.HealthChanged:Connect(function()
- script.Parent.Text = "HP: " .. math.floor(humanoid.Health) .. "%"
- end)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement