private void timer2_Tick(object sender, EventArgs e) { label1.Text = String.Format("{0}", count--); if (!UdpEvent.Instance.IsHost) { return; } if (count <= 0) { //START var data = new StartProtocol(); data.ip = UdpEvent.Instance.Ip; UdpEvent.Instance.Notify(data); } }
private void OnStart(StartProtocol p, bool self, int from) { if (start) { return; } start = true; Invoke2(() => { label1.Text = "0"; label2.Text = "Start " + self; timer2.Stop(); timer1.Stop(); }); }
private void timer2_Tick(object sender, EventArgs e) { label1.Text = String.Format("{0}", count--); if (!UdpEvent.Instance.IsHost) return; if (count <= 0) { //START var data = new StartProtocol(); data.ip = UdpEvent.Instance.Ip; UdpEvent.Instance.Notify(data); } }
private void OnStart(StartProtocol p, bool self, int from) { if (start) return; start = true; Invoke2(() => { label1.Text = "0"; label2.Text = "Start " + self; timer2.Stop(); timer1.Stop(); }); }