Hello, I am making a combat game and I want to make it so your character doesn’t “die”. It never reaches 0 hp, because I’m trying to make an animation play when the character “dies”. But I want it to be easily configurable.
I have this script done so far but it doesn’t work.
local hum = char.Humanoid local Animator = hum.Animator hum.BreakJointsOnDeath = false hum:SetStateEnabled(Enum.HumanoidStateType.Dead, false) local ST = Instance.new('IntValue') ST.Parent = hum ST.Name = 'Stun' local hDebounce = false hum.HealthChanged:Connect(function() if (hum.Health == 0 and hDebounce == false) then hum.Health = 50 Animator:LoadAnimation(script.Animations.Awaken):Play() end end)
Is there an alternative way? I just want the character death to be animatable, and configurable.