Hello, I’m doing a transformation and I would like that when the player resets he doesn’t die
I’m not sure what you mean, do you want to make it so the player can’t reset?
Imagine that you reset it, and then your health zeroed out, but you didn’t die, after 1 to 2 seconds that you reset your health back to normal, this is what I want to do, did you understand?
No, I’m pretty sure that he means that whenever a player resets… he wants them to stay alive.
then just remove the reset button
humanoid.BreakJointsOnDeath = false while true do wait() if humanoid.health == 0 then humanoid.health = 100 end end
You’d need to prevent the Humanoid’s Health from reaching 0, otherwise they’re dead & they’ll respawn before you know it
You probably need to clamp the health when they reset/die
As far as I know, when the player’s health goes to 0 the player’s character will always be respawned. Maybe you can set their health very low?
If breakjointondeath is disabled, the player will not respawn
I just tried setting BreakJointsOnDeath to false and then setting my characters health to zero and it still respawned.
In my studio never respawns…
You turn it off in the Server Side or with Normal script?
You could try this.
Humanoid.Died:Connect(function() Humanoid:SetStateEnabled(Enum.HumanoidStateType.Dead, false) end)
As an alternative, you could also set the Dead state to false every time the state is changed.
Humanoid.StateChanged:Connect(function() Humanoid:SetStateEnabled(Enum.HumanoidStateType.Dead, false) end)
With this, turning off BreakJointsOnDeath would also fix the character falling apart (since the joints would, well, break), meaning the player shouldn’t instantly die.
All that it does is not break your joints but your character still respawns. Yes, I did this server side. Humanoid.BreakJointsOnDeath
If your character is respawning automatically when your Humanoid.Health is 0, then you actually set ‘game:GetService(‘Players’).RespawnTime’ to 0. [ If the ‘RespawnTime’ is 0, your Player.Character gonna respawn instantly. ]
I didn’t mess around with that setting. My character respawned a couple of seconds after me setting my health to zero. You can always try it out for yourself and see what happens. I’m not really sure how to prevent the character from respawning.
@zQ86 Did not work
The default ROBLOX ‘RespawnTime’ is 5. What I think that @RVTGAMERGg want to do is:
When your Player.Character dies, him want to the character don’t die. But back after 1-2 seconds.
Also, what you can do is:
Remove the ‘ResetButtonCallBack’ when you do the transformation thing.
In a local script in starterplayerscripts
We continuously call because sometimes it doesn’t bind on the first try. We attempt 25 times to connect so we don’t cause infinite loop.
local starterGui = game:GetService("StarterGui") local resetBindable = Instance.new("BindableEvent") resetBindable.Event:Connect (function () print "No resetting here!" end) local success = false local attempts = 0 while success == false do success = pcall (function() starterGui:SetCore("ResetButtonCallback", resetBindable) end) attempts += 1 if attempts >= 25 then break end wait(0.2) end
I’ll do my best to make a Script for you, be right back.