Advertisement
xmaanzach

Kill For Cash Tutorial

May 17th, 2018
15,652
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.59 KB | None | 0 0
  1. --// local variables
  2. local humanoid = script.Parent.Humanoid
  3. local Alive = true
  4.  
  5. --// Player Died function
  6. humanoid.Died:connect(function()
  7. if Alive == true then
  8. Alive = false
  9. wait(0.25)
  10. local player = game.Players:GetPlayerFromCharacter(script.Parent)
  11. local killed = humanoid:FindFirstChild("creator")
  12.  
  13. if killed then
  14. if player ~= killed.Value then
  15. killed.Value.leaderstats.Cash.Value = killed.Value.leaderstats.Cash.Value + 15 -- '15' aumento y 'Cash' leaderstats
  16. end
  17. end
  18. end
  19. end)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement