Advertisement
NSKuber

Exercise 3

Mar 31st, 2021
425
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.31 KB | None | 0 0
  1. Wait(Delay(1))
  2.  
  3. local AllPlayers = worldInfo:GetAllPlayersInRange(worldInfo,100000)
  4. for _,player in pairs(AllPlayers) do
  5.   RunAsync(function()
  6.     while true do
  7.       local payload = Wait(Event(player.Died))
  8.       if (payload:GetKiller() ~= player) then
  9.         player:Respawn()
  10.       end
  11.     end
  12.   end)
  13. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement