private void OnEnd_BuyItem(P2CBuyItem ret) { this.StopWaitCoroutine(); if (ret != null && ret.retaCode == 0) { List <string> rItems = BattleEquipTools_config.GetRItems(this.RItems, this.CurHItem, this.PItems); if (BattleEquipTools_config.IsChanged(this.RItems, rItems)) { this.Update_rItems(rItems); this.Update_rItemsSub(); if (this.CurMenu == BattleEquipType.recommend) { this.Update_curSItem(null); this.Update_sItems(); } } if (this.DealingShop != null) { this.DealingShop.DealCounter++; this.DealingShop.RollbackStack.Push(this.data.CurRollbackInfo); this.data.CurRollbackInfo = null; } } else { MobaMessageManagerTools.SendClientMsg(ClientC2C.BattleShop_err, "购买失败,errCode=" + ret.retaCode, false); } if (this.DealingShop != null) { this.DealingShop.State = EBattleShopState.eIdle; this.DealingShop = null; } this.CurHItem = null; }
private void OnMsg_C2P_BuyItem(MobaMessage msg) { P2CBuyItem probufMsg = msg.GetProbufMsg <P2CBuyItem>(); this.OnEnd_BuyItem(probufMsg); }