Server Message Command Problems

Hello all! So I have been trying to make a :sm command which shows a server message which should pop up to players which currently works. But it has one issue. The executor of the command instantly sees the server message pop up as a gui but any other player has a delay with it and the gui on their screen delays a few seconds. Does anyone know how I can fix my script below to prevent this? Thanks!

-- Command Format - :sm <Message>

-- Change Settings Here:
local groupId = 15257297

local minimumRankToUseCommand = 16

--------------------------------------

game.Players.PlayerAdded:Connect(function(plr)
	if plr.Team == "Host" or "Co-Host" or plr:GetRankInGroup(groupId) >= minimumRankToUseCommand then
		plr.Chatted:Connect(function(msg)
			local split = msg:split(" ")

			if split[1]:lower() == ":sm" then
				if split[2] then
					local plrTable = game.Players:GetPlayers()
					for i, v in pairs(plrTable) do
						v.PlayerGui.ServerMessage.MainFrame.Message.Text = string.sub(msg, 4, #msg)
						v.PlayerGui.ServerMessage.Enabled = true
						wait(6)
						v.PlayerGui.ServerMessage.Enabled = false
					end
				end
			end
		end)
	end
end)

When you iterated on the players table, after enable the message for the first player, you started to wait 6 seconds, then disable the message, then continue with the second player, again wait 6 seconds, then third player 6 secs. etc etc.
You are waiting 6 seconds per player before continue with next one

Try this:
game.Players.PlayerAdded:Connect(function(plr)
	if plr.Team == "Host" or "Co-Host" or plr:GetRankInGroup(groupId) >= minimumRankToUseCommand then
		plr.Chatted:Connect(function(msg)
			local split = msg:split(" ")

			if split[1]:lower() == ":sm" then
				if split[2] then
					local plrTable = game.Players:GetPlayers()
					for i, v in pairs(plrTable) do
						v.PlayerGui.ServerMessage.MainFrame.Message.Text = string.sub(msg, 4, #msg)
						v.PlayerGui.ServerMessage.Enabled = true
					end
					task.wait(6)
					for i, v in pairs(plrTable) do
						v.PlayerGui.ServerMessage.Enabled = false
					end
				end
			end
		end)
	end
end)