//3-28 public void SendPostageReq(List <ToggleAndObj> taos) { var builder = Farm_Game_Postage_Req.CreateBuilder(); for (int i = 0; i < taos.Count; i++) { if (taos[i].T.isOn) { var a = PMsg_StagePropUnit.CreateBuilder(); a.Count = taos[i].Num; a.Id = taos[i].Id; builder.AddObjs(a); } } _Proxy.SendMsg(NetModules.GameAction.ModuleId, NetModules.GameAction.Farm_Game_Postage_Req, builder); }
//3-27兑换请求 public void OidExchangeReq(int userId, int pattern, string recieverName, string phoneNumber, string province, string city, string county, int pinpai, string adress, string beaty, int PayPattern) { if (FieldsController.ProtocalAction != ProtocalAction.None) { return; } else { FieldsController.ProtocalAction = ProtocalAction.Exchange; } Farm_Game_OidExchange_Req.Builder builder = Farm_Game_OidExchange_Req.CreateBuilder(); builder.UserGameID = userId; builder.RecieverName = recieverName; builder.PhoneNum = phoneNumber; builder.Adress = adress; builder.Beaty = beaty; builder.City = city; builder.County = county == "请选择县级"?"没有填写,见联系地址":county; builder.PinPai = pinpai; builder.Pattern = pattern; builder.PayPattern = PayPattern; builder.Province = province; Debug.Log(string.Format("<color=#ffffffff><---{0}-{1}----></color>", builder.County, "hjhj")); List <ToggleAndObj> taos = CommitViewModel.Instance.taos; for (int i = 0; i < taos.Count; i++) { if (taos[i].T.isOn) { var a = PMsg_StagePropUnit.CreateBuilder(); a.Count = taos[i].Num; a.Id = taos[i].Id; Debug.Log(string.Format("<color=#ffffffff><---{0}-{1}----></color>", a.Count, a.Id)); builder.AddObjs(a); } } Debug.Log(string.Format("<color=#ffffffff><---{0}-{1}----></color>", province, county)); _Proxy.SendMsg(NetModules.GameAction.ModuleId, NetModules.GameAction.Farm_Game_OidExchange_Req, builder); }