maxDeaths = 1
game.Players.PlayerAdded:connect(function(p)
local hold = Instance.new("IntValue", p)
hold.Name = "Deaths"
p.CharacterAdded:connect(function(c)
c.Humanoid.Died:connect(function()
hold.Value = hold.Value +1
if hold.Value == maxDeaths then
Player:kick("I am dead. So why am I back ")
end
end)
end)
end)
the "Player" thing is underlined blue and says "unknown global 'player'" why does it say that?

4 comments
@Subz for some reason it doesnt work
@Subsz ts a local script in SSS btw
:connect() is deprecated. Use :Connect()
I think you should do it in a server script