local player = game:GetService("Players").LocalPlayer
local char = player.Character or player.CharacterAdded:Wait()
function lives()
game.Workspace.Lives.Value = game.Workspace.Lives.Value - 1
print(game.Workspace.Lives.Value)
end
char:WaitForChild("Humanoid").Died:connect(lives)
The code above works perfectly... once. After that, it no longer functions. I'm confused as to why this is happening and the API reference on RobloxDev haven't clued me in on the issue. Any ideas?

1 comment
Use player.CharacterAdded