public static void PacketSend(char src, string name, PacketStream data, string str = "") { if (IsPaused) return; Form1.Instance.Invoke(new MethodInvoker(delegate { int i = Form1.Instance.packets.Rows.Add(); Form1.Instance.packets.Rows[i].DefaultCellStyle.BackColor = Color.LightBlue; Form1.Instance.packets.Rows[i].Cells[0].Value = String.Format("({0}) send", src); Form1.Instance.packets.Rows[i].Cells[1].Value = "0x" + data.GetId().ToString("X4"); Form1.Instance.packets.Rows[i].Cells[2].Value = name; Form1.Instance.packets.Rows[i].Cells[3].Value = data.ToArray().Length; Form1.Instance.packets.Rows[i].Cells[4].Value = data; Form1.Instance.packets.Rows[i].Cells[5].Value = str; })); }