i am trying to check if an object isnt in a players gui because when the game starts there is a loading gui and when it loads it is removed and theres a script i want to run when it loads
local plrs = game.Players:GetChildren() for i = 1, #plrs do if not plrs[i].PlayerGui:FindFirstChild("Loading_Gui") then --code end end
Hi Vetrodex,
To access anything to do with PlayerGui you will need the client to run a localscript. With some more context I might be able to help you further, but for now I would recommend placing your code that you want executed in the same localscript that loads the game on the client's side.