-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathtestlist sv
More file actions
103 lines (91 loc) · 3.22 KB
/
testlist sv
File metadata and controls
103 lines (91 loc) · 3.22 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
local Fluent = loadstring(game:HttpGet("https://github.com/dawid-scripts/Fluent/releases/latest/download/main.lua"))()
local Window = Fluent:CreateWindow({
Title = "SALUNA VIP ♥",
SubTitle = " Made by Saluna",
TabWidth = 100,
Size = UDim2.fromOffset(475, 340),
Acrylic = true, -- The blur may be detectable, setting this to false disables blur entirely
Theme = "Darker",
MinimizeKey = Enum.KeyCode.F2 -- Used when theres no MinimizeKeybind
})
Tabs = {
Server = Window:AddTab({ Title = "Server", Icon = "rbxassetid://7539983773" })
}
local Options = Fluent.Options
local ServerRiel = {}
local PlaceID = game.PlaceId
local foundAnything = ""
local HttpService = game:GetService("HttpService")
local PlaceID = game.PlaceId
local foundAnything = ""
local HttpService = game:GetService("HttpService")
local url = 'https://games.roblox.com/v1/games/' .. PlaceID .. '/servers/Public?sortOrder=Asc&limit=100'
if foundAnything ~= "" then
url = url .. '&cursor=' .. foundAnything
end
-- Correct handling of pcall
local success, Site = pcall(function()
return HttpService:JSONDecode(game:HttpGet(url))
end)
-- Only proceed if the pcall was successful
if success and Site then
-- Handle pagination
if Site.nextPageCursor and Site.nextPageCursor ~= "null" then
foundAnything = Site.nextPageCursor
else
foundAnything = ""
end
-- Iterate over servers and collect data
for _, server in ipairs(Site.data) do
if server.playing < server.maxPlayers then
table.insert(ServerRiel, server.id.." \nPing("..math.floor(server.ping)..") - ".."FPS("..math.floor(server.fps)..") - ".."Players("..server.playing.."/"..server.maxPlayers..")")
end
end
end
SVLISTED = Tabs.Server:AddDropdown("SVLISTED", {
Title = "Choose Server",
Description = "Choose Server From The List",
Values = ServerRiel,
Multi = false,
Default = "",
})
SVLISTED:OnChanged(function(hellozxw)
pcall(function()
hmm = tostring(hellozxw)
game:GetService("TeleportService"):TeleportToPlaceInstance(game.PlaceId, string.match(hmm, "^(.-) "), game.Players.LocalPlayer)
end)
end)
spawn(function()
while wait(1) do
pcall(function()
table.clear(ServerRiel)
local PlaceID = game.PlaceId
local foundAnything = ""
local HttpService = game:GetService("HttpService")
local url = 'https://games.roblox.com/v1/games/' .. PlaceID .. '/servers/Public?sortOrder=Asc&limit=100'
if foundAnything ~= "" then
url = url .. '&cursor=' .. foundAnything
end
-- Correct handling of pcall
local success, Site = pcall(function()
return HttpService:JSONDecode(game:HttpGet(url))
end)
-- Only proceed if the pcall was successful
if success and Site then
-- Handle pagination
if Site.nextPageCursor and Site.nextPageCursor ~= "null" then
foundAnything = Site.nextPageCursor
else
foundAnything = ""
end
-- Iterate over servers and collect data
for _, server in ipairs(Site.data) do
if server.playing < server.maxPlayers then
table.insert(ServerRiel, server.id.." \nPing("..math.floor(server.ping)..") - ".."FPS("..math.floor(server.fps)..") - ".."Players("..server.playing.."/"..server.maxPlayers..")")
end
end
SVLISTED:SetValues(ServerRiel)
end
end)
end
end)