Whenever I run the script, I keep getting this error:
15:49:13.197 - BanGUI is not a valid member of PlayerGui "Players.AbsurdAwesome101.PlayerGui"
This is the code:
script.Parent.Equipped:Connect(function() if lp.PlayerGui.BanGUI ~= nil then local gui = lp.PlayerGui.BanGUI local frames = gui:GetChildren() frames.Visible = true else script.Parent.BanGUI:Clone().Parent = lp.PlayerGui end end)
this is inside a local script inside a tool. Legit no reason to be giving me errors, so whats wrong????
Fixed.
script.Parent.Equipped:Connect(function() if lp.PlayerGui:FindFirstChild("BanGUI") ~= nil then local gui = lp.PlayerGui.BanGUI gui.BanModeToggle.Visible = true gui.BreakToggle.Visible = true else script.Parent.BanGUI:Clone().Parent = lp.PlayerGui end end)