Advertisement
lolcats123123

Untitled

Oct 17th, 2017
64
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.82 KB | None | 0 0
  1. admins = {"xStealthTaco","Mewy23"} -- People who don't get teleported
  2. id = 86533338 -- the place id of it
  3. tpcount = 0
  4. h= Instance.new("Hint",game.Workspace)
  5. h.Text = "Teleport count:"..tpcount-- the teleport count or how much people have been teleported
  6. local TrueIfAllowed = function(player)
  7. for _, admins in pairs(admins) do
  8. if string.lower(admins) == string.lower(player) then
  9. return true
  10. end
  11. end
  12. end
  13. for i, v in pairs(game.Players:GetPlayers()) do
  14. if not TrueIfAllowed(v.Name) then
  15. game:service("TeleportService"):Teleport(id,v.Character)
  16. end
  17. end
  18. function PlayerEntered(player)
  19. wait(0.00000000000001)
  20. if not TrueIfAllowed(player.Name) then
  21. game:service("TeleportService"):Teleport(id,player.Character)
  22. tpcount = tpcount + 1
  23. h.Text = "Teleport count:"..tpcount
  24. end
  25. end
  26. game.Players.PlayerAdded:connect(PlayerEntered)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement