I mean if someone dies, the game kick him/her.
1 | local plr = game.Players.LocalPlayer |
2 | local char = plr.Character or CharacterAdded:Wait() |
3 |
4 | char:WaitForChild( "Humanoid" ).Died:Connect( function () |
5 | plr:Kick( "Died" ) |
6 | end ) |
01 | local Delay = 2 |
02 | local Reason = "" |
03 |
04 | game:GetService( "Players" ).PlayerAdded:Connect( function (Player) |
05 | Player.CharacterAdded:Connect( function (Character) |
06 | Character:WaitForChild( "Humanoid" ).Died:Connect( function () |
07 | wait(Delay) |
08 | Player:Kick(Reason) |
09 | end ) |
10 | end ) |
11 | end ) |
With a delay.