PcoWSkbVqDnWTu_dm2ix
We use cookies on this site to enhance your user experience

Player.CharacterRemoving

Player.CharacterRemoving

Oct 01 2018, 2:05 AM PST

This example prints the name of the character being removed, followed by “has died”.

For instance, if Shedletsky’s character was to die in-game, “Shedletsky has died.” would be printed.

game.Players.PlayerAdded:Connect(function(player)
    player.CharacterRemoving:Connect(function(character)
        print(character.Name .. " has died.")
    end)
end)