Fifkee

SB Utility #1: Return all PlayerGui Objects

Apr 16th, 2018
154
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.53 KB | None | 0 0
  1. tabl = {}
  2. wait(1)
  3. print('search started')
  4. for i, v in pairs(game:GetService("Players"):GetPlayers()) do
  5.     pg = v:WaitForChild("PlayerGui", 5)
  6.     if pg ~= nil then
  7.     for _, x in pairs(pg:GetChildren()) do
  8.         if x.ClassName == "GuiMain" or x.ClassName == "ScreenGui" then
  9.         if x.Name:match("Chat") or x.Name:match("SB_") then x = "" else
  10.         wait()
  11.         table.insert(tabl, (v.Name.." :: "..x.Name)) end
  12.     end end
  13.     print(table.concat(tabl, "\n"))
  14.     print('search ended, heck off.')
  15.     tabl = {}
  16. end
  17. end
Advertisement
Add Comment
Please, Sign In to add comment