public override void ExecuteOutCoin(OutCoinMsg obj) { viewData.Logs += $"正在出币\n数量:{obj.CoinCount}\n概率:{obj.Chance}\n电压:{obj.Voltage}"; obj.ClientID = viewData.ClientID; new Thread(() => { int i = 1; while (i <= obj.CoinCount) { Thread.Sleep(10); viewData.RunStatus += $"出币{i}/{obj.CoinCount}个"; i++; } viewData.Logs += $"完成:出币{obj.CoinCount}个\n"; SendMessage(obj.Socket, new OutCoinMsgFinish { Type = MsgType.OutCoinFinish, ClientID = obj.ClientID, MessageID = obj.MessageID }); }).Start(); }
public override void ExecuteOutCoin(OutCoinMsg obj) { MessageBox.Show("执行出币"); }