Advertisement
Guest User

Untitled

a guest
Mar 15th, 2020
2,594
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.38 KB | None | 0 0
  1. game.Players.PlayerAdded:Connect(function(Player)
  2.     Player.CharacterAdded:Connect(function(Character)
  3.         local Humanoid = Character:WaitForChild("Humanoid")
  4.         Humanoid.Died:Connect(function()
  5.             if Humanoid:FindFirstChild("creator") then
  6.                 print(Player, "was killed by", Humanoid.creator.Value)
  7.             else
  8.                 print(Player, "was not killed by another player")
  9.             end
  10.         end)
  11.     end)
  12. end)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement