0% found this document useful (0 votes)
103 views2 pages

Roblox Server Hop Script Function

Uploaded by

vulizminecraft20
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
103 views2 pages

Roblox Server Hop Script Function

Uploaded by

vulizminecraft20
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd

function NewHopServer(PlaceID)

[Link]("[Link]",{},2 * 60)
local Data,NeedUpdateData = [Link]("[Link]")
if NeedUpdateData then
[Link]("[Link]",true)
Data = {}
local Cursor = ""
for i = 1,3 do
local Url = '[Link] .. PlaceID ..
'/servers/Public?sortOrder=Desc&limit=100&excludeFullGames=true'
if Cursor and Cursor ~= "" then
Url = Url..'&cursor=' .. Cursor
end
local Ret = game:HttpGet(Url)
local Site = [Link]:JSONDecode(Ret)
if [Link] then
wait(10)
break;
end
if [Link] then
for k,v in [Link] do
[Link]([Link],[Link])
end
end
if [Link] and [Link] ~= "null" and
[Link] ~= nil then
Cursor = [Link]
else
break;
end
wait(1)
end
if #[Link] > 10 then
[Link]("[Link]",Data)
else
print("save fail")
wait(20)
end
[Link]("[Link]",false)
return HopServer(PlaceID)
else
local ServerIdJoined = {}
if isfile("[Link]") then
ServerIdJoined =
HttpService:JSONDecode(readfile("[Link]"))
end
for k,v in ServerIdJoined do
if tick() - v > 60 * 40 then
ServerIdJoined[k] = nil
end
end
local Site
local c = 0
while not Site do
local r = [Link](1,#Data)
local Sited = Data[r]
if not ServerIdJoined[Sited] then
Site = Sited
end
c = c + 1
if c % 100 == 0 then wait() end
end
ServerIdJoined[Site] = tick()
writefile("[Link]",HttpService:JSONEncode(ServerIdJoined))
game:GetService("TeleportService"):TeleportToPlaceInstance(PlaceID, Site,
[Link])
print("Hoped")
return
end
end

You might also like