There is various weapons inside the game, if the players die they respawn. But I also have costumes and such for the avatar, so I’m trying to find a way so that the Player will automatically respawn with the costume.
Because the event
game.Players.LocalPlayer.CharacterAdded
will fired only once the character got add in the game
try using
local player = game.Players.LocalPlayer
local char = player.Character or player.CharacterAdded:Wait()
char.Humanoid.Died:Connect(function() – then continue with your code
Didn’t test it yet, but hope it would work!
Yeah I guess either way would work. We would need to change the code a bit if we wanted to do that (which isn’t a problem)
One minor issue is that he wants things to wait a certain amount of time after dying, which might not work because the character might be destroyed by then.