Hi. im trying to make a script that temporarily disables your chat. This is my code. it is a local script, and the parent of the local script is Player Gui.
x = script.Parent:FindFirstChild("Chat") wait() while true do if game.Workspace.Current.Value ~= script.Parent.Parent.TeamColor then x.Enabled = false else x.Enabled = true end end
Im kinda stupid, i had to put wait for child instead of find first child, and i had to put the wait() in the loop not before