death = game.Players.LocalPlayer.Character.Humanoid.Died:connect(function() script.Parent.Frame.Visible = true script.Parent.Sound:Play() end)
I have this in a local script, and it works fine. Just not in the actual game.
death = game.Players.LocalPlayer.Character.Humanoid.Died:connect(function() script.Parent.Frame.Visible = true script.Parent.Sound:Play() end)
I have this in a local script, and it works fine. Just not in the actual game.
Try this
plr = game.Players.LocalPlayer
plr.Character.Humanoid.Died:connect(function()
script.Parent.Frame.Visible = true
script.Parent.Sound:Play()
end)
Also are there any error messages in the dev console?
Try it in a regular script then see what happens. ;)
This discussion is preserved as it was. New answers, comments, and votes are closed.
1 comment
Is there any error message when you test this in a game?