private VipXiaoGuo CheckOwnEffect(int type, int vipLevel) { if (EntityWorld.Instance.EntSelf == null) { return(null); } VipXiaoGuo result = null; if (VIPManager.Instance.LimitCardData.Times > TimeManager.Instance.PreciseServerSecond) { result = this.GetVipEffect(type, vipLevel); } if (VipTasteCardManager.Instance.CardTime > TimeManager.Instance.PreciseServerSecond) { List <vipTiYanQia> dataList = DataReader <vipTiYanQia> .DataList; if (dataList == null || dataList.get_Count() == 0) { return(result); } vipTiYanQia vipTiYanQia = dataList.get_Item(0); List <int> effect = vipTiYanQia.effect; for (int i = 0; i < effect.get_Count(); i++) { VipXiaoGuo vipXiaoGuo = DataReader <VipXiaoGuo> .Get(effect.get_Item(i)); if (vipXiaoGuo != null && vipXiaoGuo.type == type) { result = vipXiaoGuo; } } } return(result); }
private void InitTastePanel() { List <vipTiYanQia> dataList = DataReader <vipTiYanQia> .DataList; vipTiYanQia vipTiYanQia = dataList.get_Item(0); if (dataList == null) { return; } List <int> effect = vipTiYanQia.effect; string empty = string.Empty; int num = -1; this.ClearScroll(); for (int i = 0; i < effect.get_Count(); i++) { int key = effect.get_Item(i); VipXiaoGuo vipXiaoGuo = DataReader <VipXiaoGuo> .Get(key); if (vipXiaoGuo != null) { string chineseContent = GameDataUtils.GetChineseContent(vipXiaoGuo.name, true); if (!string.IsNullOrEmpty(chineseContent)) { num++; this.UpdateCardItemInfo(num, chineseContent); } } } }
private void InitCheckId() { List <vipTiYanQia> dataList = DataReader <vipTiYanQia> .DataList; vipTiYanQia vipTiYanQia = dataList.get_Item(0); if (dataList == null) { return; } this.CheckId = vipTiYanQia.ID; }
private void InitExpirePanel(bool isMyOwnVip = false) { List <int> list = null; if (isMyOwnVip) { VipDengJi vipDengJi = DataReader <VipDengJi> .Get(EntityWorld.Instance.EntSelf.VipLv); if (vipDengJi != null) { list = vipDengJi.effect; } } else { List <vipTiYanQia> dataList = DataReader <vipTiYanQia> .DataList; vipTiYanQia vipTiYanQia = dataList.get_Item(0); if (dataList != null) { list = vipTiYanQia.effect; } } string empty = string.Empty; int num = -1; this.ClearExpireScroll(); for (int i = 0; i < list.get_Count(); i++) { int key = list.get_Item(i); VipXiaoGuo vipXiaoGuo = DataReader <VipXiaoGuo> .Get(key); if (vipXiaoGuo != null) { string chineseContent = GameDataUtils.GetChineseContent(vipXiaoGuo.name, true); if (!string.IsNullOrEmpty(chineseContent)) { num++; this.UpdateExpireCardItemInfo(num, chineseContent); } } } }