public static void MakePrefabByChipData(GameWebAPI.RespDataMA_ChipM.Chip masterChip, GameObject emptyObject, Vector3 position, Vector3 scale, Action <ChipIcon> actCB = null, int texSizeWidth = -1, int texSizeHeight = -1, bool colliderEnable = true) { Action <UnityEngine.Object> actEnd = delegate(UnityEngine.Object obj) { GameObject gameObject = UnityEngine.Object.Instantiate(obj) as GameObject; gameObject.transform.SetParent(emptyObject.transform.parent); gameObject.transform.localPosition = position; gameObject.transform.localScale = scale; BoxCollider component = gameObject.GetComponent <BoxCollider>(); if (component != null) { component.enabled = colliderEnable; } UIWidget component2 = emptyObject.GetComponent <UIWidget>(); DepthController component3 = gameObject.GetComponent <DepthController>(); component3.AddWidgetDepth(component2.depth); ChipIcon component4 = gameObject.GetComponent <ChipIcon>(); component4.SetData(masterChip, texSizeWidth, texSizeHeight); if (actCB != null) { actCB(component4); } }; AssetDataMng.Instance().LoadObjectASync("UICommon/ListParts/ListPartsChip", actEnd); }
protected void SetIcons(string path, List <UISprite> list, GameWebAPI.RespDataCM_LoginBonus.LoginReward[] rewardList) { int num = 1; string name = path + num; if (base.transform.Find(name) == null) { return; } UISprite component = base.transform.Find(name).GetComponent <UISprite>(); while (component != null) { list.Add(component); if (rewardList.Length < num) { component.gameObject.SetActive(false); } else { int num2 = num - 1; string rewardIcon = this.GetRewardIcon(rewardList[num2]); string assetCategoryId = rewardList[num2].assetCategoryId; string assetValue = rewardList[num2].assetValue; if (string.IsNullOrEmpty(assetCategoryId) || string.IsNullOrEmpty(rewardIcon) || this.textureCategoryList.Contains(assetCategoryId.ToInt32())) { component.gameObject.SetActive(false); } else if (assetCategoryId.ToInt32() == 17) { GameWebAPI.RespDataMA_ChipM.Chip chipMainData = ChipDataMng.GetChipMainData(assetValue); ChipDataMng.MakePrefabByChipData(chipMainData, component.gameObject, component.transform.localPosition, component.transform.localScale, null, -1, -1, true); } else if (assetCategoryId.ToInt32() == 1) { this.monsterIcon = GUIMonsterIcon.MakePrefabByMonsterData(MonsterDataMng.Instance().CreateMonsterDataByMID(assetValue), Vector3.one, Vector3.zero, component.transform, true, false); this.monsterIcon.ResizeIcon(component.width, component.height); if (null != this.monsterIcon) { DepthController depthController = this.monsterIcon.GetDepthController(); if (null != depthController) { depthController.AddWidgetDepth(this.monsterIcon.transform, component.depth + 1); } } } else { component.spriteName = rewardIcon; } } num++; name = path + num; if (!(base.transform.Find(name) != null)) { break; } component = base.transform.Find(name).GetComponent <UISprite>(); } }
public static CMD_QuestItemPOP Create(GameWebAPI.RespDataMA_ChipM.Chip data) { CMD_QuestItemPOP cmd_QuestItemPOP = GUIMain.ShowCommonDialog(null, "CMD_QuestItemPOP", null) as CMD_QuestItemPOP; cmd_QuestItemPOP.SetParam(data); return(cmd_QuestItemPOP); }
private void Send(GameWebAPI.RespDataCS_ChipListLogic.UserChipList baseChip) { RestrictionInput.StartLoad(RestrictionInput.LoadType.SMALL_IMAGE_MASK_ON); int userChipId = baseChip.userChipId; GameWebAPI.RespDataMA_ChipM.Chip baseMaterChip = ChipDataMng.GetChipMainData(baseChip); int num = baseMaterChip.needChip.ToInt32(); int[] array = null; if (num > 0) { array = new int[num]; int num2 = 0; foreach (GameWebAPI.RespDataCS_ChipListLogic.UserChipList userChipList2 in ChipDataMng.userChipData.userChipList) { if (userChipId != userChipList2.userChipId && userChipList2.chipId == baseChip.chipId && userChipList2.userMonsterId == 0) { array[num2] = userChipList2.userChipId; num2++; if (num2 >= array.Length) { break; } } } } Action callback = delegate() { GameWebAPI.RespDataCS_ChipListLogic.UserChipList[] array2 = this.ConvertChipList(ChipDataMng.userChipData); this.chipList.ReAllBuild(array2, false, false); this.chipList.SetShortTouchCallback(new Action <GUIListChipParts.Data>(this.OnShortTouchChip)); this.chipList.SetLongTouchCallback(new Action <GUIListChipParts.Data>(this.OnLongTouchChip)); this.messageLabel.gameObject.SetActive(array2.Count <GameWebAPI.RespDataCS_ChipListLogic.UserChipList>() == 0); this.listCountLabel.text = string.Format(StringMaster.GetString("SystemFraction"), ChipDataMng.userChipData.userChipList.Length, DataMng.Instance().RespDataUS_PlayerInfo.playerInfo.chipLimitMax); GameWebAPI.RespDataMA_ChipM.Chip chipEnhancedData = ChipDataMng.GetChipEnhancedData(baseMaterChip.chipId); CMD_ChipReinforcementAnimation.Create(this.gameObject, chipEnhancedData, null); }; int resultCode = 0; APIRequestTask task = ChipDataMng.RequestAPIChipFusion(baseChip.userChipId, array, delegate(int res) { resultCode = res; }); AppCoroutine.Start(task.Run(delegate { if (resultCode == 1) { callback(); } else { string @string = StringMaster.GetString("SystemDataMismatchTitle"); string message = string.Format(StringMaster.GetString("ChipDataMismatchMesage"), resultCode); AlertManager.ShowModalMessage(delegate(int modal) { }, @string, message, AlertManager.ButtonActionType.Close, false); } RestrictionInput.EndLoad(); }, null, null), false); }
private void SetCacheChipIconResources() { string selectDeckNum = DataMng.Instance().RespDataMN_DeckList.selectDeckNum; GameWebAPI.RespDataMN_GetDeckList.DeckList deckList = null; GameWebAPI.RespDataMN_GetDeckList.DeckList[] deckList2 = DataMng.Instance().RespDataMN_DeckList.deckList; for (int i = 0; i < deckList2.Length; i++) { if (selectDeckNum == deckList2[i].deckNum) { deckList = deckList2[i]; break; } } int[] array = null; for (int j = 0; j < deckList.monsterList.Length; j++) { MonsterData userMonster = ClassSingleton <MonsterUserDataMng> .Instance.GetUserMonster(deckList.monsterList[j].userMonsterId); MonsterChipEquipData chipEquip = userMonster.GetChipEquip(); array = chipEquip.GetChipIdList(); } for (int k = 0; k < array.Length; k++) { GameWebAPI.RespDataMA_ChipM.Chip chipMainData = ChipDataMng.GetChipMainData(array[k]); string iconPath = chipMainData.GetIconPath(); if (!AssetDataMng.Instance().IsAssetBundleData(iconPath)) { UnityEngine.Object resource = AssetDataMng.Instance().LoadObject(iconPath, null, true); AssetDataCacheMng.Instance().AddCache(iconPath, AssetDataCacheMng.CACHE_TYPE.CHARA_PARTY, resource); } } }
public static CMD_ChipReinforcementAnimation Create(GameObject parent, GameWebAPI.RespDataMA_ChipM.Chip data, Action <int> callback = null) { CMD_ChipReinforcementAnimation cmd_ChipReinforcementAnimation = GUIMain.ShowCommonDialog(callback, "CMD_Chip_LvUP", null) as CMD_ChipReinforcementAnimation; cmd_ChipReinforcementAnimation.SetParam(data); return(cmd_ChipReinforcementAnimation); }
public static GameWebAPI.RespDataMA_ChipM.Chip SetChipIconPath(GameWebAPI.RespDataMA_ChipM.Chip chip) { if (string.IsNullOrEmpty(chip.GetIconPath())) { chip.SetIconPath(string.Format("ChipThumbnail/{0}", chip.icon)); } return(chip); }
public static GameWebAPI.RespDataMA_ChipM.Chip GetChipMainData(GameWebAPI.RespDataCS_ChipListLogic.UserChipList userChip) { GameWebAPI.RespDataMA_ChipM.Chip chip = null; ChipDataMng.GetDictionaryChipM().TryGetValue(userChip.chipId, out chip); chip = ChipDataMng.SetChipIconPath(chip); chip = ChipDataMng.SetChipSellPrice(chip); return(chip); }
public void SetupOnlyDetailParams(int userChipId, GameWebAPI.RespDataMA_ChipM.Chip chipData) { this.myParameter.menuType = CMD_ChipSphere.MenuType.Detail; this.myParameter.chipName = chipData.name; this.myParameter.chipDetail = chipData.detail; this.myParameter.chipRank = chipData.rank; this.myParameter.chipIconPath = chipData.GetIconPath(); this.myParameter.userChipId = userChipId; }
public static GameWebAPI.RespDataMA_ChipM.Chip GetChipMainData(int chipId) { GameWebAPI.RespDataMA_ChipM.Chip chip = null; if (ChipDataMng.GetDictionaryChipM().TryGetValue(chipId, out chip)) { chip = ChipDataMng.SetChipIconPath(chip); chip = ChipDataMng.SetChipSellPrice(chip); } return(chip); }
private static int ComparerRarityOrderByDesc(GameWebAPI.RespDataCS_ChipListLogic.UserChipList x, GameWebAPI.RespDataCS_ChipListLogic.UserChipList y) { GameWebAPI.RespDataMA_ChipM.Chip chipMainData = ChipDataMng.GetChipMainData(x); GameWebAPI.RespDataMA_ChipM.Chip chipMainData2 = ChipDataMng.GetChipMainData(y); int num = chipMainData.rank.ToInt32(); int num2 = chipMainData2.rank.ToInt32(); int num3 = num2 - num; return((num3 != 0) ? num3 : (y.chipId - x.chipId)); }
public void SetData(GameWebAPI.RespDataMA_ChipM.Chip data) { if (data == null) { base.gameObject.SetActive(false); UnityEngine.Object.Destroy(base.gameObject); this.isSetData = false; return; } this.chipIcon.SetData(data, -1, -1); this.isSetData = true; }
private void OnShortTouchChip(GUIListChipParts.Data data) { this.chipList.SetSelectColor(this.selectedUserChipId, false); this.chipList.SetNowSelectMessage(this.selectedUserChipId, false); int userChipId = data.userChip.userChipId; this.chipList.SetSelectColor(userChipId, true); this.chipList.SetNowSelectMessage(userChipId, true); this.selectedUserChipId = data.userChip.userChipId; this.selectedChip = data.masterChip; global::Debug.LogWarning("ShortTouch " + data.userChip.userChipId); this.SetupAttackButton(); this.SetupChipDetail(); }
public static GameWebAPI.RespDataMA_ChipM.Chip GetChipEnhancedData(string chipId) { GameWebAPI.RespDataMA_ChipM.Chip beforeChip = null; ChipDataMng.GetDictionaryChipM().TryGetValue(int.Parse(chipId), out beforeChip); IEnumerable <GameWebAPI.RespDataMA_ChipM.Chip> source = MasterDataMng.Instance().RespDataMA_ChipMaster.chipM.Where((GameWebAPI.RespDataMA_ChipM.Chip c) => c.chipGroupId == beforeChip.chipGroupId && int.Parse(c.rank) > int.Parse(beforeChip.rank)); GameWebAPI.RespDataMA_ChipM.Chip chip = null; if (source.Count <GameWebAPI.RespDataMA_ChipM.Chip>() > 0) { chip = source.OrderBy((GameWebAPI.RespDataMA_ChipM.Chip c) => int.Parse(c.rank)).ToArray <GameWebAPI.RespDataMA_ChipM.Chip>()[0]; chip = ChipDataMng.SetChipIconPath(chip); chip = ChipDataMng.SetChipSellPrice(chip); } return(chip); }
public void SetupDetail(int userChipId, GameWebAPI.RespDataMA_ChipM.Chip chipData) { this.isOpened = true; this.SetupOnlyDetailParams(userChipId, chipData); this.frameSprite.spriteName = "Chip_Sphere_Thumbnail_ON"; NGUITools.SetActiveSelf(this.chargesGO, false); NGUITools.SetActiveSelf(this.lookGO, false); NGUITools.SetActiveSelf(this.chipNameLabel.gameObject, true); NGUITools.SetActiveSelf(this.chipDescriptLabel.gameObject, true); this.chipNameLabel.text = this.myParameter.chipName; this.chipDescriptLabel.text = this.myParameter.chipDetail; NGUIUtil.ChangeUITextureFromFileASync(this.chipTexture, chipData.GetIconPath(), false, null); NGUITools.SetActiveSelf(this.rankSprite.gameObject, true); this.rankSprite.spriteName = ChipTools.GetRankPath(chipData.rank); }
private void LoadIcon(GameWebAPI.RespDataMA_ChipM.Chip data = null, int texSizeWidth = -1, int texSizeHeight = -1) { this.isLoad = true; string texname = (data == null) ? "ChipThumbnail/Chip_Empty" : data.GetIconPath(); NGUIUtil.LoadTextureAsync(this.iconTexture, texname, delegate { this.isLoad = false; if (this != null && texSizeWidth > 0 && texSizeHeight > 0) { float x = (float)texSizeWidth / (float)this.defaultTexSizeWidth; float y = (float)texSizeHeight / (float)this.defaultTexSizeHeight; this.transform.localScale = new Vector3(x, y, 1f); } }); }
private bool IsAlreadySameGroupIdChipAttached(List <string> myDigimonChipGroupIds, int chipId) { if (myDigimonChipGroupIds == null) { return(false); } string strChipId = chipId.ToString(); GameWebAPI.RespDataMA_ChipM.Chip chip = MasterDataMng.Instance().RespDataMA_ChipMaster.chipM.Where((GameWebAPI.RespDataMA_ChipM.Chip c) => c.chipId == strChipId).SingleOrDefault <GameWebAPI.RespDataMA_ChipM.Chip>(); if (chip == null) { global::Debug.LogError("なぜかchipIdがおかしい."); return(true); } return(myDigimonChipGroupIds.Contains(chip.chipGroupId)); }
private bool SetChipIcon(string assetsValue, GameObject parent, int width, int height) { bool result = false; GameWebAPI.RespDataMA_ChipM.Chip chipMainData = ChipDataMng.GetChipMainData(assetsValue); if (chipMainData != null) { Transform transform = parent.transform; GameWebAPI.RespDataMA_ChipM.Chip masterChip = chipMainData; Vector3 localPosition = transform.localPosition; Vector3 localScale = transform.localScale; ChipDataMng.MakePrefabByChipData(masterChip, parent, localPosition, localScale, null, width, height, true); result = true; } return(result); }
private IEnumerator SetParamProcess(GameWebAPI.RespDataMA_ChipM.Chip data) { IEnumerator loadWait = this.Load(data); while (loadWait.MoveNext()) { yield return(null); } this.label.text = data.name; IEnumerator animationWait = this.Animation(); while (animationWait.MoveNext()) { yield return(null); } yield break; }
public void SetParam(GameWebAPI.RespDataCS_ChipListLogic.UserChipList data) { this.userChip = data; GameWebAPI.RespDataMA_ChipM.Chip prevMaterChip = ChipDataMng.GetChipMainData(this.userChip.chipId.ToString()); this.prevReinforcementInfo.name.text = prevMaterChip.name; this.prevReinforcementInfo.description.text = prevMaterChip.detail; this.prevReinforcementInfo.chipIcon.SetData(prevMaterChip, -1, -1); GameWebAPI.RespDataMA_ChipM.Chip chipEnhancedData = ChipDataMng.GetChipEnhancedData(this.userChip.chipId.ToString()); this.nextReinforcementInfo.name.text = chipEnhancedData.name; this.nextReinforcementInfo.description.text = chipEnhancedData.detail; this.nextReinforcementInfo.chipIcon.SetData(chipEnhancedData, -1, -1); int num = prevMaterChip.needChip.ToInt32(); foreach (ChipIcon chipIcon in this.consumptionInfo.chipIcons) { chipIcon.SetActive(false); } for (int j = 0; j < num; j++) { this.consumptionInfo.chipIcons[j].SetActive(true); this.consumptionInfo.chipIcons[j].SetData(prevMaterChip, -1, -1); } GameWebAPI.RespDataCS_ChipListLogic userChipData = ChipDataMng.userChipData; int num2 = userChipData.userChipList.Count((GameWebAPI.RespDataCS_ChipListLogic.UserChipList x) => this.userChip.userChipId != x.userChipId && x.chipId.ToString() == prevMaterChip.chipId && x.userMonsterId <= 0); bool flag = num2 >= num; if (flag) { this.consumptionInfo.message.text = StringMaster.GetString("ChipReinforcementModal-05"); this.consumptionInfo.message.color = ConstValue.DEFAULT_COLOR; this.EnableDecisionButton(true); } else { for (int k = 0; k < num; k++) { bool flag2 = k >= num2; this.consumptionInfo.chipIcons[k].SetSelectColor(flag2); this.consumptionInfo.chipIcons[k].SetSelectRankColor(flag2); } this.consumptionInfo.message.text = StringMaster.GetString("ChipReinforcementModal-06"); this.consumptionInfo.message.color = Color.red; this.EnableDecisionButton(false); } }
public void SetParams(List <GameWebAPI.RespDataCS_ChipListLogic.UserChipList> selectedUserChipList, string getCluster) { this.titleLabel.text = StringMaster.GetString("ChipSaleCheck-01"); this.normalMessageLabel.text = StringMaster.GetString("ChipSaleCheck-02"); bool flag = false; for (int i = 0; i < selectedUserChipList.Count; i++) { GameWebAPI.RespDataMA_ChipM.Chip chipMainData = ChipDataMng.GetChipMainData(selectedUserChipList[i].chipId.ToString()); if (int.Parse(chipMainData.rank) >= 7) { flag = true; } this.CreateIcon(chipMainData, this.guiMonsterIcons[i].gameObject); } this.warningMessageLabel.text = ((!flag) ? string.Empty : string.Format(StringMaster.GetString("ChipSaleCheck-03"), "A")); this.getClusterLabel.text = getCluster; }
private void CreateIcon(GameWebAPI.RespDataMA_ChipM.Chip masterChip, GameObject goEmpty) { Action <UnityEngine.Object> actEnd = delegate(UnityEngine.Object obj) { GameObject gameObject = UnityEngine.Object.Instantiate(obj) as GameObject; gameObject.transform.SetParent(goEmpty.transform.parent); gameObject.transform.localPosition = goEmpty.transform.localPosition; gameObject.transform.localScale = new Vector3(0.92f, 0.92f, 1f); UIWidget component = goEmpty.GetComponent <UIWidget>(); DepthController component2 = gameObject.GetComponent <DepthController>(); component2.AddWidgetDepth(component.depth); ChipIcon component3 = gameObject.GetComponent <ChipIcon>(); component3.SetData(masterChip, -1, -1); NGUITools.DestroyImmediate(goEmpty); }; AssetDataMng.Instance().LoadObjectASync("UICommon/ListParts/ListPartsChip", actEnd); }
private GameWebAPI.RespDataCS_ChipListLogic.UserChipList[] ConvertChipList(GameWebAPI.RespDataCS_ChipListLogic chipListLogic) { List <GameWebAPI.RespDataCS_ChipListLogic.UserChipList> list = new List <GameWebAPI.RespDataCS_ChipListLogic.UserChipList>(); if (chipListLogic != null && chipListLogic.userChipList != null) { foreach (GameWebAPI.RespDataCS_ChipListLogic.UserChipList userChipList2 in chipListLogic.userChipList) { GameWebAPI.RespDataMA_ChipM.Chip chipEnhancedData = ChipDataMng.GetChipEnhancedData(userChipList2.chipId.ToString()); if (chipEnhancedData != null) { list.Add(userChipList2); } } CMD_ChipSortModal.UpdateSortedUserChipList(list.ToArray()); return(CMD_ChipSortModal.sortedUserChipList); } return(list.ToArray()); }
private void SetupIcon(GameWebAPI.RespDataMA_ChipM.Chip chipMainData) { NGUITools.SetActiveSelf(this.thumbnailTexture.gameObject, true); NGUIUtil.ChangeUITextureFromFileASync(this.thumbnailTexture, chipMainData.GetIconPath(), false, null); if (this.rareSprite != null) { this.rareSprite.spriteName = ChipTools.GetRankPath(chipMainData.rank); NGUITools.SetActiveSelf(this.rareSprite.gameObject, true); } if (this.noChipLabel != null) { NGUITools.SetActiveSelf(this.noChipLabel.gameObject, false); } if (this.chipNameLabel != null) { NGUITools.SetActiveSelf(this.chipNameLabel.gameObject, true); this.chipNameLabel.text = chipMainData.name; } }
public List <string> GetChipGroupList() { List <string> list = null; List <ChipClientEquip> chipEquip = this.monsterSlotInfo.GetChipEquip(); if (0 < chipEquip.Count) { list = new List <string>(); for (int i = 0; i < chipEquip.Count; i++) { GameWebAPI.RespDataMA_ChipM.Chip chipMainData = ChipDataMng.GetChipMainData(chipEquip[i].chipId.ToString()); if (chipMainData != null) { list.Add(chipMainData.chipGroupId); } } } return(list); }
public void SetData(GameWebAPI.RespDataMA_ChipM.Chip data = null, int texSizeWidth = -1, int texSizeHeight = -1) { string text = (data == null) ? string.Empty : ("Chip_Lv" + data.rank); if (this.rankSprite.spriteName != text) { this.rankSprite.spriteName = text; } base.transform.localScale = Vector3.one; this.loadList.Add(delegate { this.LoadIcon(data, texSizeWidth, texSizeHeight); }); if (this.dimMessage != null) { this.SetNowSelectMessage(false); } this.SetEquipmentIcon(false); this.SetSelectMessage(string.Empty); }
public static void CreateChipIcon(GameWebAPI.RespDataMA_ChipM.Chip data, UITexture baseIcon, Action <ChipIcon> callback = null) { Action <UnityEngine.Object> actEnd = delegate(UnityEngine.Object obj) { GameObject gameObject = UnityEngine.Object.Instantiate(obj) as GameObject; gameObject.transform.SetParent(baseIcon.transform); gameObject.transform.localPosition = Vector3.zero; gameObject.transform.localScale = Vector3.one; DepthController component = gameObject.GetComponent <DepthController>(); component.AddWidgetDepth(baseIcon.depth); ChipIcon component2 = gameObject.GetComponent <ChipIcon>(); component2.SetData(data, -1, -1); baseIcon.mainTexture = null; if (callback != null) { callback(component2); } }; AssetDataMng.Instance().LoadObjectASync("UICommon/Parts/Parts_ChipThumbnail", actEnd); }
public void SetParam(GameWebAPI.RespDataMA_ChipM.Chip data) { this.titleLabel.text = data.name; this.textLabel.text = data.detail; this.iconSprite.gameObject.SetActive(false); this.iconTexture.gameObject.SetActive(true); Action <UnityEngine.Object> actEnd = delegate(UnityEngine.Object obj) { GameObject gameObject = UnityEngine.Object.Instantiate(obj) as GameObject; gameObject.transform.SetParent(this.iconTexture.transform.parent); gameObject.transform.localPosition = this.iconTexture.transform.localPosition; gameObject.transform.localScale = Vector3.one; DepthController component = gameObject.GetComponent <DepthController>(); component.AddWidgetDepth(this.iconTexture.depth); ChipIcon component2 = gameObject.GetComponent <ChipIcon>(); component2.SetData(data, -1, -1); gameObject.GetComponent <BoxCollider>().enabled = false; }; AssetDataMng.Instance().LoadObjectASync("UICommon/ListParts/ListPartsChip", actEnd); }
public static List <string> GetBonusText(List <string> activateChipIds, List <GameWebAPI.RespDataMA_EventPointBonusM.EventPointBonus> eventBonusPoints, List <GameWebAPI.RespDataMA_GetWorldDungeonExtraEffectM.WorldDungeonExtraEffectM> stageGimmickBonusPoints) { List <string> list = new List <string>(); for (int i = 0; i < activateChipIds.Count; i++) { GameWebAPI.RespDataMA_ChipM.Chip chipMainData = ChipDataMng.GetChipMainData(activateChipIds[i]); if (chipMainData != null) { list.Add(chipMainData.name); } } for (int j = 0; j < eventBonusPoints.Count; j++) { list.Add(eventBonusPoints[j].detail); } for (int k = 0; k < stageGimmickBonusPoints.Count; k++) { list.Add(stageGimmickBonusPoints[k].detail); } return(list); }
private IEnumerator Load(GameWebAPI.RespDataMA_ChipM.Chip data) { foreach (UITexture baseIcon in this.icons) { ChipTools.CreateChipIcon(data, baseIcon, delegate(ChipIcon chipIcon) { this.chipIconList.Add(chipIcon); }); } float maxTime = 30f; float currentTime = 0f; while (this.chipIconList.Count < this.icons.Length) { currentTime += Time.deltaTime; if (currentTime >= maxTime) { yield break; } yield return(null); } yield break; }