Recorded video clip of the bug occurring above.
When the user hits reset, there is a massive delay between when the .Died event of the humanoid is triggered and when the user pressed the reset button.
This can be partially be worked around by enabling BreakJointsOnDeath however that defeats the objective of having this property in the first place.
I’ve read other posts saying that I should swap the .Died event for a :GetPropertyChangedSignal(“Health”), however this has a similar issue, the health value also suffers the same massive delay.
Expected behavior
.Died event should fire instantly.
(EDIT)
Might be important to note that CharacterAutoLoads is disabled.
And that’s the only code? You haven’t disabled BreakJointsOnDeath as far as I can see…
Have also verified the incoming replication lag, although I assumed that was a given.
Sorry, I didn’t include that but I’ll edit it in, but no it does not reproduce when either of the settings you mention are toggled. I have both of these set the same way in my game and a ragdoll system running on Died and I have no issues.
Maybe you should include which beta features you have enabled?
Issue doesn’t occur when I test in a baseplate, obviously leads me to believe it’s some sort of change I’m making to the character in my game which causes the delay, I’m hunting for whatever seems to break it now, but so far have come up short.
And before you say it, I have not disabled the “Dead” HumanoidStateType.
Worst case scenario if it’s nothing you’re specifically doing, since you’re listening to this on the server, maybe your server is overloaded with either network traffic, replication, or processing. Maybe try disabling all systems that can communicate through remotes and any other heavy systems and see if the latency improves.
Overloaded traffic wouldn’t explain why enabling BreakJointsOnDeath instantly fixed it, enabling that changes practically zero other elements of my game.
Seems like it’s delayed by 30 seconds. What if you adjust the respawn time? I understand this is probably unrelated but 30 seconds looks like an intentional number.
It should also be known whether this issue persists if you manually kill the player with code.
Respawn time is set to 3 seconds, timing was just coincidentally 30 seconds, and yes have experimented with killing the player with code, makes little difference, it’s also not practical to be killing characters with external code as this is what the reset button is for.
I have been investigating this for some time myself. For me, sometimes it works, sometimes it doesn’t. CharacterAutoLoads is enabled for me. I was going to post a bug report about this last night, but I couldn’t reproduce it.
I have read that there seems to be an issue with network ownership causing this. I have also read that it triggers instantly on the client regardless of what’s happening on the server. One workaround is to watch for it on the client and fire a remote event to the server when the player dies, but I cannot do that in my game.
Here’s a few previous posts about this same issue.
Thanks for the suggestions, interestingly I never saw these when I was researching the problem.
I assume I’ll get a reply from the ROBLOX staff within a few days, but even then I’m not holding my breath as 90% of what I report I never receive an update on anyway.
I guess we’ll see what they come back with, I’m not a massive fan of firing an event to the server whenever a client dies particularly, feels a bit tacky to me.
After doing a little bit of research, I whipped up a little something to reliably detect when a player dies. Not sure why I didn’t think about doing this first.
Interestingly though, I think I may have uncovered a bug with Humanoid:StateChanged(Enum.HumanoidStateType.Dead). It seems that one does not reliably kill the player.
I have provided 6 different methods to detect when a humanoid dies. Four of them are event related, two of them are polling methods (polling methods are mutually exclusive). So one of them will catch when a humanoid dies.