Advertisement
Guest User

gaymosesgetshotbyniggerrs

a guest
Feb 20th, 2020
191
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.67 KB | None | 0 0
  1. local HttpService = game:GetService("HttpService")
  2. local TeleportService = game:GetService("TeleportService")
  3. local PlaceId = game.PlaceId
  4. local URL = ("https://www.roblox.com/games/getgameinstancesjson?placeId=%s&startindex="):format(PlaceId)
  5. local List = {}
  6. for page = 0, 30 do
  7. local Query = HttpService:JSONDecode(game:HttpGet(URL..page))
  8.  
  9. for i,v in next, Query.Collection do
  10. List[v.Guid] = v.Ping
  11. end
  12. end
  13. local ChosenServer = game.JobId
  14. for i,v in pairs(List) do
  15. if i ~= game.JobId then
  16. ChosenServer = i
  17. break
  18. end
  19. end
  20. TeleportService:TeleportToPlaceInstance(game.PlaceId, ChosenServer, game.Players.LocalPlayer)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement