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

Custom health not regenerating?

Asked by
Probix 80
7 years ago
game.StarterGui:SetCoreGuiEnabled(Enum.CoreGuiType.All, false)
local player = game.Players.LocalPlayer
player.Character:WaitForChild("Humanoid")


function CustomHealth()
    script.Parent:TweenSize(UDim2.new(player.Character.Humanoid.Health / player.Character.Humanoid.MaxHealth,-215, 0, 10), "Out", "Sine", 3)
end

player.Character.Humanoid.HealthChanged:connect(CustomHealth)

I tested it and when I take damage it would go down but instead of going back up, it would keep going like it is taking damage but really it's healing.

Help would be very appreciated.

Answer this question