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
