public static void OnGetLoginBonusRes(GetLoginBonusRes ret) { if (ret.errcode == 0) { if (ret != null) { RewardStruct reward = new RewardStruct(ret); EquipConfig config = EquipConfig.GetEquipByID(ret.id); if (config.IsMoney()) { PlayerManager.player_data.money += ret.num; } List <RewardStruct> list = new List <RewardStruct>(); list.Add(reward); LoginBonusRewardPanel.Show(list); if (LoginBonusPanel.Instance != null) { LoginBonusPanel.Instance.UpdatePanel(ret.bonusdata); } } } else { string ErrTips = ErrCodeConfig.GetTipsById(ret.errcode); PopItem item = UIManager.AddItem <PopItem>("PopItem", UIManager.PopPanelRoot); if (!string.IsNullOrEmpty(ErrTips)) { item.SetTips(ErrTips); } } }