public void ChangeRarityFrameAtlus(RARITY_TYPE?rarity) { if (!rarity.HasValue || spriteRarityAtlas == null || spriteRarityAtlas.Length == 0) { return; } if (rarity.HasValue) { switch (rarity.Value) { case RARITY_TYPE.S: case RARITY_TYPE.SS: case RARITY_TYPE.SSS: goto IL_006a; } } int num = 0; goto IL_0071; IL_006a: num = 1; goto IL_0071; IL_0071: string spriteName = rarityFrame.spriteName; rarityFrame.atlas = spriteRarityAtlas[num]; rarityFrame.spriteName = spriteName; spriteName = rarityTextIcon.spriteName; rarityTextIcon.atlas = spriteRarityAtlas[num]; rarityTextIcon.spriteName = spriteName; }
protected ItemIcon CreateItemIconDetail(ITEM_ICON_TYPE icon_type, int icon_id, RARITY_TYPE?rarity, SkillItemSortData item_data, bool is_show_main_status, Transform parent = null, string event_name = null, int event_data = 0, bool is_new = false, int toggle_group = -1, int select_number = -1, bool is_equipping = false, bool is_select_max = false) { ItemIconDetail.ICON_STATUS iCON_STATUS = ItemIconDetail.ICON_STATUS.NONE; if (is_select_max && select_number == -1) { iCON_STATUS = ItemIconDetail.ICON_STATUS.GRAYOUT; } if (inventoryUI == UI.GRD_INVENTORY) { if (icon_type == ITEM_ICON_TYPE.SKILL_GROW) { ItemTable.ItemData itemData = Singleton <ItemTable> .I.GetItemData(item_data.skillData.itemId); bool is_select = select_number != -1; ItemIcon itemIcon = ItemIconDetail.CreateMaterialIcon(icon_type, icon_id, rarity, itemData, is_show_main_status, parent, item_data.skillData.num, itemData.name, "MATERIAL_NUM", event_data, toggle_group, is_select, false); ((ItemIconDetail)itemIcon).setupperSkill.GrayOut(iCON_STATUS); return(itemIcon); } return(ItemIconDetail.CreateSkillDetailSelectNumberIcon(icon_type, icon_id, rarity, item_data, is_show_main_status, parent, event_name, event_data, is_new, toggle_group, select_number, is_equipping, iCON_STATUS)); } if (icon_type == ITEM_ICON_TYPE.SKILL_GROW) { ItemTable.ItemData itemData2 = Singleton <ItemTable> .I.GetItemData(item_data.skillData.itemId); bool is_select2 = select_number != -1; return(ItemIconDetailSmall.CreateSmallMaterialIcon(icon_type, icon_id, rarity, parent, item_data.skillData.num, itemData2.name, "MATERIAL_NUM", event_data, toggle_group, is_select2, is_new, 0, 0, iCON_STATUS)); } return(ItemIconDetailSmall.CreateSmallSkillSelectDetailIcon(icon_type, icon_id, rarity, item_data, parent, event_name, event_data, is_new, toggle_group, select_number, is_equipping, iCON_STATUS)); }
protected ItemIcon CreateItemIconDetail(ITEM_ICON_TYPE icon_type, int icon_id, RARITY_TYPE?rarity, SkillItemSortData item_data, bool is_show_main_status, Transform parent = null, string event_name = null, int event_data = 0, bool is_new = false, int toggle_group = -1, bool is_select = false, bool is_equipping = false, bool isValidExceed = false, bool isShowEnableExceed = false) { if (inventoryUI == UI.GRD_INVENTORY) { return(ItemIconDetail.CreateSkillDetailIcon(icon_type, icon_id, rarity, item_data, is_show_main_status, parent, event_name, event_data, is_new, toggle_group, is_select, is_equipping, isValidExceed, isShowEnableExceed)); } return(ItemIconDetailSmall.CreateSmallSkillDetailIcon(icon_type, icon_id, rarity, item_data, parent, event_name, event_data, is_new, toggle_group, is_select, is_equipping, isValidExceed, isShowEnableExceed)); }
protected ItemIcon CreateItemIconDetail(ITEM_ICON_TYPE icon_type, int icon_id, RARITY_TYPE?rarity, SkillItemSortData item_data, bool is_show_main_status, Transform parent = null, string event_name = null, int event_data = 0, bool is_new = false, int toggle_group = -1, int select_number = -1, bool is_equipping = false) { if (inventoryUI == UI.GRD_INVENTORY) { return(ItemIconDetail.CreateSkillDetailSelectNumberIcon(icon_type, icon_id, rarity, item_data, is_show_main_status, parent, event_name, event_data, is_new, toggle_group, select_number, is_equipping, ItemIconDetail.ICON_STATUS.NONE)); } return(ItemIconDetailSmall.CreateSmallSkillSelectDetailIcon(icon_type, icon_id, rarity, item_data, parent, event_name, event_data, is_new, toggle_group, select_number, is_equipping, ItemIconDetail.ICON_STATUS.NONE)); }
public static string GetRarityTextSpriteName(RARITY_TYPE?rarityType, GET_TYPE getType) { int num = (int)(rarityType.HasValue ? rarityType.Value : RARITY_TYPE.D); if (getType == GET_TYPE.PAY) { return(ITEM_ICON_ITEM_RARITY_ICON_SPRITE[num]); } return(ITEM_ICON_ITEM_RARITY_ICON_EVENT_SPRITE[num]); }
public static ItemIcon CreateMaterialIcon(ITEM_ICON_TYPE icon_type, int icon_id, RARITY_TYPE?rarity, ItemTable.ItemData item_table, bool is_show_main_status, Transform parent = null, int num = -1, string name = null, string event_name = null, int event_data = 0, int toggle_group = -1, bool is_select = false, bool is_new = false) { ItemIconDetail itemIconDetail = ItemIcon.CreateIcon <ItemIconDetail>(MonoBehaviourSingleton <GlobalSettingsManager> .I.linkResources.itemIconDetailPrefab, icon_type, icon_id, rarity, parent, ELEMENT_TYPE.MAX, null, -1, event_name, event_data, is_new, toggle_group, is_select, string.Empty, false, item_table.enemyIconID, item_table.enemyIconID2, false, QUEST_ICON_SIZE_TYPE.DEFAULT, GET_TYPE.PAY); itemIconDetail.setupperMaterial.Set(new object[3] { item_table, num, is_show_main_status }); return(itemIconDetail); }
private static T CreateEquipIconByEquipItemTable <T>(Object prefab, EquipItemTable.EquipItemData equipItemTableData, int sex, Transform parent, EQUIPMENT_TYPE?magi_enable_icon_type = default(EQUIPMENT_TYPE?), int num = -1, string event_name = null, int event_data = 0, bool is_new = false, int toggle_group = -1, bool is_select = false, string icon_under_text = null, bool is_equipping = false, bool disable_rarity_text = false) where T : ItemIcon { ITEM_ICON_TYPE icon_type = ITEM_ICON_TYPE.NONE; RARITY_TYPE? rarity = null; ELEMENT_TYPE element = ELEMENT_TYPE.MAX; int icon_id = -1; string empty = string.Empty; GET_TYPE gET_TYPE = GET_TYPE.NONE; if (equipItemTableData != null) { icon_type = GetItemIconType(equipItemTableData.type); rarity = equipItemTableData.rarity; element = equipItemTableData.GetTargetElementPriorityToTable(); icon_id = equipItemTableData.GetIconID(sex); gET_TYPE = equipItemTableData.getType; } GET_TYPE getType = gET_TYPE; return(CreateIcon <T>(prefab, icon_type, icon_id, rarity, parent, element, magi_enable_icon_type, num, event_name, event_data, is_new, toggle_group, is_select, icon_under_text, is_equipping, 0, 0, disable_rarity_text, QUEST_ICON_SIZE_TYPE.DEFAULT, getType)); }
protected override void UpdateEquipIcon(List <CharaInfo.EquipItem> equip_set_info) { //IL_0310: Unknown result type (might be due to invalid IL or missing references) SetActive(transRoot, UI.LBL_CHANGE_MODE, isVisualMode); int i = 0; for (int num = 7; i < num; i++) { SetEvent(FindCtrl(transRoot, icons[i]), "EMPTY", 0); SetEvent(FindCtrl(transRoot, icons_btn[i]), "EMPTY", 0); SetLabelText(FindCtrl(transRoot, icons_level[i]), string.Empty); } bool flag = isVisualMode; bool flag2 = isVisualMode; bool flag3 = isVisualMode; bool flag4 = isVisualMode; int j = 0; for (int num2 = localEquipSet.item.Length; j < num2; j++) { ITEM_ICON_TYPE iTEM_ICON_TYPE = ITEM_ICON_TYPE.NONE; RARITY_TYPE? nullable = null; ELEMENT_TYPE eLEMENT_TYPE = ELEMENT_TYPE.MAX; int num3 = -1; EquipItemInfo equipItemInfo = localEquipSet.item[j]; EquipItemTable.EquipItemData equipItemData = null; if (equipItemInfo != null) { switch (equipItemInfo.tableData.type) { case EQUIPMENT_TYPE.ARMOR: flag2 = false; break; case EQUIPMENT_TYPE.HELM: flag = false; break; case EQUIPMENT_TYPE.ARM: flag3 = false; break; case EQUIPMENT_TYPE.LEG: flag4 = false; break; } equipItemData = ((!isVisualMode) ? Singleton <EquipItemTable> .I.GetEquipItemData(equipItemInfo.tableID) : GetVisualModeTargetTable(equipItemInfo.tableData.id, equipItemInfo.tableData.type, record.charaInfo)); } if (isVisualMode) { if (equipItemData != null) { num3 = equipItemData.GetIconID(GetCharaSex()); SetActive(FindCtrl(transRoot, icons_level[j]), false); } } else if (equipItemInfo != null && equipItemInfo.tableID != 0) { num3 = equipItemData.GetIconID(GetCharaSex()); SetActive(FindCtrl(transRoot, icons_level[j]), true); string text = string.Format(StringTable.Get(STRING_CATEGORY.MAIN_STATUS, 1u), equipItemInfo.level.ToString()); SetLabelText(FindCtrl(transRoot, icons_level[j]), text); } Transform parent = FindCtrl(transRoot, icons[j]); ItemIcon itemIcon = ItemIcon.CreateEquipItemIconByEquipItemInfo(equipItemInfo, GetCharaSex(), parent, null, -1, "EQUIP", j, false, -1, false, null, false, false); SetLongTouch(itemIcon.transform, "DETAIL", j); SetEvent(FindCtrl(transRoot, icons_btn[j]), "DETAIL", j); SetEvent(itemIcon.transform, "DETAIL", j); itemIcon.get_gameObject().SetActive(num3 != -1); if (num3 != -1) { itemIcon.SetEquipExtInvertedColor(equipItemInfo, base.GetComponent <UILabel>(transRoot, (Enum)icons_level[j])); } } if (flag && record.charaInfo.hId != 0) { int index = 4; int hId = record.charaInfo.hId; EQUIPMENT_TYPE e_type = EQUIPMENT_TYPE.HELM; CharaInfo charaInfo = record.charaInfo; SetVisualModeIcon(index, hId, e_type, charaInfo); } if (flag2 && record.charaInfo.aId != 0) { int index2 = 3; int aId = record.charaInfo.aId; EQUIPMENT_TYPE e_type2 = EQUIPMENT_TYPE.ARMOR; CharaInfo charaInfo2 = record.charaInfo; SetVisualModeIcon(index2, aId, e_type2, charaInfo2); } if (flag3 && record.charaInfo.rId != 0) { int index3 = 5; int rId = record.charaInfo.rId; EQUIPMENT_TYPE e_type3 = EQUIPMENT_TYPE.ARM; CharaInfo charaInfo3 = record.charaInfo; SetVisualModeIcon(index3, rId, e_type3, charaInfo3); } if (flag4 && record.charaInfo.lId != 0) { int index4 = 6; int lId = record.charaInfo.lId; EQUIPMENT_TYPE e_type4 = EQUIPMENT_TYPE.LEG; CharaInfo charaInfo4 = record.charaInfo; SetVisualModeIcon(index4, lId, e_type4, charaInfo4); } }
public override void UpdateUI() { SetActive((Enum)UI.BTN_NEXT, false); SetActive((Enum)UI.OBJ_BONUS_POINT_SHOP, false); SetGrid(UI.GRD_DROP_ITEM, null, dropItemIconData.Length, true, delegate(int i, Transform o, bool is_recycle) { //IL_0287: Unknown result type (might be due to invalid IL or missing references) //IL_028c: Unknown result type (might be due to invalid IL or missing references) ITEM_ICON_TYPE iTEM_ICON_TYPE = ITEM_ICON_TYPE.NONE; RARITY_TYPE?rarity = null; ELEMENT_TYPE element = ELEMENT_TYPE.MAX; EQUIPMENT_TYPE?magi_enable_icon_type = null; int icon_id = -1; int num = -1; if (i < dropItemIconData.Length && dropItemIconData[i] != null) { iTEM_ICON_TYPE = dropItemIconData[i].GetIconType(); icon_id = dropItemIconData[i].GetIconID(); rarity = dropItemIconData[i].GetRarity(); element = dropItemIconData[i].GetIconElement(); magi_enable_icon_type = dropItemIconData[i].GetIconMagiEnableType(); num = dropItemIconData[i].GetNum(); if (num == 1) { num = -1; } } bool is_new = false; switch (iTEM_ICON_TYPE) { case ITEM_ICON_TYPE.ITEM: case ITEM_ICON_TYPE.QUEST_ITEM: { ulong uniqID = dropItemIconData[i].GetUniqID(); if (uniqID != 0L) { is_new = MonoBehaviourSingleton <InventoryManager> .I.IsNewItem(iTEM_ICON_TYPE, dropItemIconData[i].GetUniqID()); } break; } default: is_new = true; break; case ITEM_ICON_TYPE.NONE: break; } int enemy_icon_id = 0; if (iTEM_ICON_TYPE == ITEM_ICON_TYPE.ITEM) { ItemTable.ItemData itemData = Singleton <ItemTable> .I.GetItemData(dropItemIconData[i].GetTableID()); enemy_icon_id = itemData.enemyIconID; } ItemIcon itemIcon = null; if (dropItemIconData[i].GetIconType() == ITEM_ICON_TYPE.QUEST_ITEM) { itemIcon = ItemIcon.Create(new ItemIcon.ItemIconCreateParam { icon_type = dropItemIconData[i].GetIconType(), icon_id = dropItemIconData[i].GetIconID(), rarity = new RARITY_TYPE?(dropItemIconData[i].GetRarity()), parent = o, element = dropItemIconData[i].GetIconElement(), magi_enable_equip_type = dropItemIconData[i].GetIconMagiEnableType(), num = dropItemIconData[i].GetNum(), enemy_icon_id = enemy_icon_id, questIconSizeType = ItemIcon.QUEST_ICON_SIZE_TYPE.REWARD_DELIVERY_LIST }); } else { GET_TYPE getType = dropItemIconData[i].GetGetType(); itemIcon = ItemIcon.Create(iTEM_ICON_TYPE, icon_id, rarity, o, element, magi_enable_icon_type, num, "DROP", i, is_new, -1, false, null, false, enemy_icon_id, 0, false, getType); } itemIcon.SetRewardBG(true); itemIcon.SetRewardCategoryInfo(dropItemIconData[i].GetCategory()); SetMaterialInfo(itemIcon.transform, dropItemIconData[i].GetMaterialType(), dropItemIconData[i].GetTableID(), GetCtrl(UI.PNL_MATERIAL_INFO)); itemIcon.transform.FindChild("MaterialInfo").get_gameObject().SetActive(false); Transform val = SetPrefab(o, "QuestResultDropIconOpener", true); QuestResultDropIconOpener.Info info2 = new QuestResultDropIconOpener.Info { IsRare = ResultUtility.IsRare(dropItemIconData[i]), IsBroken = ResultUtility.IsBreakReward(dropItemIconData[i]) }; val.GetComponent <QuestResultDropIconOpener>().Initialized(itemIcon, info2, delegate(Transform t, QuestResultDropIconOpener.Info info, bool is_skip) { string ui_effect_name = "ef_ui_dropitem_silver_01"; if (info.IsBroken) { ui_effect_name = "ef_ui_dropitem_red_01"; } else if (info.IsRare) { ui_effect_name = "ef_ui_dropitem_gold_01"; } SetVisibleWidgetOneShotEffect(GetCtrl(dropItemSCR), t, ui_effect_name); }); }); base.GetComponent <UITable>((Enum)UI.TBL_GUILD_REQUEST_RESULT).Reposition(); TreasureStart(); }
public override void UpdateUI() { UI[] array = new UI[3] { UI.OBJ_MISSION_INFO_1, UI.OBJ_MISSION_INFO_2, UI.OBJ_MISSION_INFO_3 }; UI[] array2 = new UI[3] { UI.OBJ_TOP_CROWN_1, UI.OBJ_TOP_CROWN_2, UI.OBJ_TOP_CROWN_3 }; UI[] array3 = new UI[3] { UI.LBL_MISSION_INFO_1, UI.LBL_MISSION_INFO_2, UI.LBL_MISSION_INFO_3 }; UI[] array4 = new UI[3] { UI.SPR_MISSION_INFO_CROWN_1, UI.SPR_MISSION_INFO_CROWN_2, UI.SPR_MISSION_INFO_CROWN_3 }; UI[] array5 = new UI[3] { UI.SPR_CROWN_1, UI.SPR_CROWN_2, UI.SPR_CROWN_3 }; QuestInfoData info = questInfo; QUEST_TYPE questType = info.questData.tableData.questType; int num = 0; SetFontStyle((Enum)UI.STR_MISSION, 2); SetFontStyle((Enum)UI.STR_TREASURE, 2); SetFontStyle((Enum)UI.STR_SELL, 2); string text = null; switch (questType) { default: text = "STR_QUEST_TYPE_NORMAL"; break; case QUEST_TYPE.ORDER: text = "STR_QUEST_TYPE_ORDER"; break; case QUEST_TYPE.EVENT: text = "STR_QUEST_TYPE_EVENT"; break; case QUEST_TYPE.STORY: text = "STR_QUEST_TYPE_STORY"; break; } SetText((Enum)UI.LBL_QUEST_TYPE, text); SetLabelText((Enum)UI.LBL_QUEST_NUM, string.Format(base.sectionData.GetText("QUEST_NUMBER"), info.questData.tableData.locationNumber, info.questData.tableData.questNumber)); SetLabelText((Enum)UI.LBL_QUEST_NAME, info.questData.tableData.questText); int num2 = (int)info.questData.tableData.limitTime; SetLabelText((Enum)UI.LBL_LIMIT_TIME, $"{num2 / 60:D2}:{num2 % 60:D2}"); SetActive((Enum)UI.LBL_GUILD_REQUEST_NEED_POINT, false); SetActive((Enum)UI.STR_MISSION_EMPTY, false); if (!info.isExistMission) { SetActive((Enum)UI.OBJ_MISSION_INFO_ROOT, false); } else { SetActive((Enum)UI.OBJ_MISSION_INFO_ROOT, true); int i = 0; for (int num3 = info.missionData.Length; i < num3; i++) { SetActive((Enum)array[i], info.missionData[i] != null); SetActive((Enum)array2[i], info.missionData[i] != null); if (info.missionData[i] != null) { SetActive((Enum)array4[i], info.missionData[i].state >= CLEAR_STATUS.CLEAR); SetActive((Enum)array5[i], info.missionData[i].state >= CLEAR_STATUS.CLEAR); SetLabelText((Enum)array3[i], info.missionData[i].tableData.missionText); } } } if (questType == QUEST_TYPE.ORDER) { SetActive((Enum)UI.OBJ_SELL_ITEM, true); QuestItemInfo quest_item = MonoBehaviourSingleton <InventoryManager> .I.GetQuestItem(info.questData.tableData.questID); if (quest_item != null && quest_item.sellItems != null && quest_item.sellItems.Count > 0) { SetGrid(UI.GRD_REWARD_SELL, string.Empty, quest_item.sellItems.Count, false, delegate(int i_2, Transform t_2, bool is_recycle_2) { QuestItem.SellItem sellItem = quest_item.sellItems[i_2]; REWARD_TYPE type2 = (REWARD_TYPE)sellItem.type; uint itemId = (uint)sellItem.itemId; if (sellItem.num <= 0) { Log.Error(LOG.OUTGAME, "QuestItem sold get item num is zero. type={0},itemId={1}", type2, itemId); } else { int num4 = -1; ItemIcon itemIcon4 = ItemIcon.CreateRewardItemIcon(type2, itemId, t_2, num4, null, 0, false, -1, false, null, false, false, ItemIcon.QUEST_ICON_SIZE_TYPE.DEFAULT); SetMaterialInfo(itemIcon4.transform, type2, itemId, null); } }); } SetActive((Enum)UI.OBJ_TOP_CROWN_ROOT, false); } SetActive((Enum)UI.OBJ_TREASURE, true); SetGrid(UI.GRD_REWARD_QUEST, string.Empty, 5, false, delegate(int i_2, Transform t_2, bool is_recycle_2) { if (info.questData.reward != null && info.questData.reward.Length > i_2) { REWARD_TYPE type = (REWARD_TYPE)info.questData.reward[i_2].type; uint id = (uint)info.questData.reward[i_2].id; ItemIcon itemIcon3 = ItemIcon.CreateRewardItemIcon(type, id, t_2, -1, null, 0, false, -1, false, null, false, false, ItemIcon.QUEST_ICON_SIZE_TYPE.DEFAULT); SetMaterialInfo(itemIcon3.transform, type, id, null); } }); EnemyTable.EnemyData enemyData = Singleton <EnemyTable> .I.GetEnemyData((uint)info.questData.tableData.GetMainEnemyID()); if (enemyData != null) { int iconId = enemyData.iconId; RARITY_TYPE?rarity = (info.questData.tableData.questType != QUEST_TYPE.ORDER) ? null : new RARITY_TYPE?(info.questData.tableData.rarity); ItemIcon itemIcon = ItemIcon.Create(ITEM_ICON_TYPE.QUEST_ITEM, iconId, rarity, GetCtrl(UI.OBJ_ENEMY), enemyData.element, null, -1, null, 0, false, -1, false, null, false, 0, 0, false, GET_TYPE.PAY); itemIcon.SetEnableCollider(false); ItemIcon itemIcon2 = ItemIcon.Create(ITEM_ICON_TYPE.QUEST_ITEM, iconId, rarity, GetCtrl(UI.OBJ_ENEMY), enemyData.element, null, -1, null, 0, false, -1, false, null, false, 0, 0, false, GET_TYPE.PAY); itemIcon2.SetEnableCollider(false); } SetActive((Enum)UI.SPR_ELEMENT_ROOT, false); if (enemyData != null) { SetActive((Enum)UI.SPR_ELEMENT_ROOT_2, true); SetElementSprite((Enum)UI.SPR_ELEMENT_2, (int)enemyData.element); SetActive((Enum)UI.STR_NON_ELEMENT_2, enemyData.element == ELEMENT_TYPE.MAX); SetElementSprite((Enum)UI.SPR_WEAK_ELEMENT_2, (int)enemyData.weakElement); SetActive((Enum)UI.STR_NON_WEAK_ELEMENT_2, enemyData.weakElement == ELEMENT_TYPE.MAX); } else { SetActive((Enum)UI.SPR_ELEMENT_ROOT_2, false); SetActive((Enum)UI.STR_NON_WEAK_ELEMENT_2, false); } ShowInfo(questType, isShowDropInfo); SetActive((Enum)UI.TWN_DIFFICULT_STAR, false); num = (MonoBehaviourSingleton <QuestManager> .I.GetClearStatusQuestEnemySpecies(info.questData.tableData.questID)?.questStatus ?? 1); SetClearStatus((CLEAR_STATUS)num); if (!MonoBehaviourSingleton <UserInfoManager> .I.isGuildRequestOpen) { SetActive((Enum)UI.BTN_GUILD_REQUEST, false); } }
public static ItemIcon CreateSmithCreateEquipDetailIcon(ITEM_ICON_TYPE icon_type, int icon_id, RARITY_TYPE?rarity, SmithCreateSortData item_data, Transform parent = null, string event_name = null, int event_data = 0, ItemIconDetail.ICON_STATUS icon_status = ItemIconDetail.ICON_STATUS.NONE, bool is_new = false, int toggle_group = -1, bool is_select = false, bool is_equipping = false, GET_TYPE getType = GET_TYPE.PAY) { SmithCreateItemInfo smithCreateItemInfo = item_data.GetItemData() as SmithCreateItemInfo; string icon_under_text = (!smithCreateItemInfo.equipTableData.IsWeapon()) ? smithCreateItemInfo.equipTableData.baseDef.ToString() : smithCreateItemInfo.equipTableData.baseAtk.ToString(); ItemIconDetailSmall itemIconDetailSmall = ItemIcon.CreateIcon <ItemIconDetailSmall>(MonoBehaviourSingleton <GlobalSettingsManager> .I.linkResources.itemIconDetailSmallPrefab, icon_type, icon_id, rarity, parent, smithCreateItemInfo.equipTableData.GetTargetElementPriorityToTable(), null, -1, event_name, event_data, is_new, toggle_group, is_select, icon_under_text, is_equipping, 0, 0, false, QUEST_ICON_SIZE_TYPE.DEFAULT, getType); itemIconDetailSmall.EquipTypeIconInit(smithCreateItemInfo.equipTableData); itemIconDetailSmall.SetEquipIndexSprite(-1); itemIconDetailSmall.SetIconStatusSprite(icon_status); itemIconDetailSmall.SetupSelectNumberSprite(-1); itemIconDetailSmall.SetFavoriteIcon(false); return(itemIconDetailSmall); }
private static ItemIcon _CreateSmallSkillDetailIcon(ITEM_ICON_TYPE icon_type, int icon_id, RARITY_TYPE?rarity, SkillItemSortData item_data, Transform parent = null, string event_name = null, int event_data = 0, bool is_new = false, int toggle_group = -1, int select_number = -1, bool is_equipping = false, ItemIconDetail.ICON_STATUS icon_status = ItemIconDetail.ICON_STATUS.NONE) { //IL_001a: Unknown result type (might be due to invalid IL or missing references) string format = (!item_data.skillData.IsExceeded()) ? "Lv. {0}/{1}" : ("Lv. {0}/" + UIUtility.GetColorText("{1}", ExceedSkillItemTable.color)); string icon_under_text = string.Format(format, item_data.GetLevel(), item_data.skillData.GetMaxLevel()); ItemIconDetailSmall itemIconDetailSmall = ItemIcon.CreateIcon <ItemIconDetailSmall>(MonoBehaviourSingleton <GlobalSettingsManager> .I.linkResources.itemIconDetailSmallPrefab, icon_type, icon_id, rarity, parent, item_data.GetIconElement(), item_data.skillData.tableData.GetEnableEquipType(), -1, event_name, event_data, is_new, toggle_group, select_number > -1, icon_under_text, is_equipping, 0, 0, false, QUEST_ICON_SIZE_TYPE.DEFAULT, GET_TYPE.PAY); itemIconDetailSmall.EquipTypeIconInit(null); itemIconDetailSmall.SetEquipIndexSprite(-1); itemIconDetailSmall.SetIconStatusSprite(icon_status); itemIconDetailSmall.SetupSelectNumberSprite(select_number); itemIconDetailSmall.SetFavoriteIcon(item_data.IsFavorite()); return(itemIconDetailSmall); }
public static ItemIcon CreateSmallMaterialIcon(ITEM_ICON_TYPE icon_type, int icon_id, RARITY_TYPE?rarity, Transform parent = null, int num = -1, string name = null, string event_name = null, int event_data = 0, int toggle_group = -1, bool is_select = false, bool is_new = false, int enemy_icon_id = 0, int enemy_icon_id2 = 0, ItemIconDetail.ICON_STATUS icon_status = ItemIconDetail.ICON_STATUS.NONE) { string icon_under_text = "×" + num.ToString(); ItemIconDetailSmall itemIconDetailSmall = ItemIcon.CreateIcon <ItemIconDetailSmall>(MonoBehaviourSingleton <GlobalSettingsManager> .I.linkResources.itemIconDetailSmallPrefab, icon_type, icon_id, rarity, parent, ELEMENT_TYPE.MAX, null, -1, event_name, event_data, is_new, toggle_group, is_select, icon_under_text, false, enemy_icon_id, enemy_icon_id2, false, QUEST_ICON_SIZE_TYPE.DEFAULT, GET_TYPE.PAY); itemIconDetailSmall.EquipTypeIconInit(null); itemIconDetailSmall.SetEquipIndexSprite(-1); itemIconDetailSmall.SetIconStatusSprite(icon_status); itemIconDetailSmall.SetupSelectNumberSprite(-1); itemIconDetailSmall.SetFavoriteIcon(false); return(itemIconDetailSmall); }
public static ItemIcon CreateSmallSkillSelectDetailIcon(ITEM_ICON_TYPE icon_type, int icon_id, RARITY_TYPE?rarity, SkillItemSortData item_data, Transform parent = null, string event_name = null, int event_data = 0, bool is_new = false, int toggle_group = -1, int select_number = -1, bool is_equipping = false, ItemIconDetail.ICON_STATUS icon_status = ItemIconDetail.ICON_STATUS.NONE) { ItemIcon itemIcon = _CreateSmallSkillDetailIcon(icon_type, icon_id, rarity, item_data, parent, event_name, event_data, is_new, toggle_group, select_number, is_equipping, icon_status); itemIcon.SetFavoriteIcon(item_data.IsFavorite()); return(itemIcon); }
public static ItemIcon CreateSmallSkillDetailIcon(ITEM_ICON_TYPE icon_type, int icon_id, RARITY_TYPE?rarity, SkillItemSortData item_data, Transform parent = null, string event_name = null, int event_data = 0, bool is_new = false, int toggle_group = -1, bool is_select = false, bool is_equipping = false, bool isValidExceed = false, bool isShowEnableExceed = false) { ItemIconDetail.ICON_STATUS icon_status = ItemIconDetail.ICON_STATUS.NONE; if (isShowEnableExceed) { icon_status = ItemIconDetail.ICON_STATUS.VALID_EXCEED_0; } else if (isValidExceed) { icon_status = ItemIconDetail.ICON_STATUS.VALID_EXCEED; } ItemIcon itemIcon = _CreateSmallSkillDetailIcon(icon_type, icon_id, rarity, item_data, parent, event_name, event_data, is_new, toggle_group, (!is_select) ? (-1) : 0, is_equipping, icon_status); itemIcon.SetFavoriteIcon(item_data.IsFavorite()); return(itemIcon); }
protected ItemIcon CreateEquipAbilityIconDetail(ITEM_ICON_TYPE icon_type, int icon_id, RARITY_TYPE?rarity, EquipItemSortData item_data, SkillSlotUIData[] skill_slot_data, bool is_show_main_status, Transform parent = null, string event_name = null, int event_data = 0, ItemIconDetail.ICON_STATUS icon_status = ItemIconDetail.ICON_STATUS.NONE, bool is_new = false, int toggle_group = -1, bool is_select = false, int equip_index = -1, GET_TYPE getType = GET_TYPE.PAY) { return(ItemIconDetail.CreateEquipAbilityIcon(icon_type, icon_id, rarity, item_data, skill_slot_data, is_show_main_status, parent, event_name, event_data, icon_status, is_new, toggle_group, is_select, equip_index, getType)); }
private void SetItemIcon(Transform holder, ItemSortData data, Transform parent_scroll) { ITEM_ICON_TYPE iTEM_ICON_TYPE = ITEM_ICON_TYPE.NONE; RARITY_TYPE? rarity = null; ELEMENT_TYPE element = ELEMENT_TYPE.MAX; EQUIPMENT_TYPE?magi_enable_icon_type = null; int icon_id = -1; int num = -1; if (data != null) { iTEM_ICON_TYPE = data.GetIconType(); icon_id = data.GetIconID(); rarity = data.GetRarity(); element = data.GetIconElement(); magi_enable_icon_type = data.GetIconMagiEnableType(); num = data.GetNum(); if (num == 1) { num = -1; } } bool is_new = false; switch (iTEM_ICON_TYPE) { case ITEM_ICON_TYPE.ITEM: case ITEM_ICON_TYPE.QUEST_ITEM: { ulong uniqID = data.GetUniqID(); if (uniqID != 0L) { is_new = MonoBehaviourSingleton <InventoryManager> .I.IsNewItem(iTEM_ICON_TYPE, data.GetUniqID()); } break; } default: is_new = true; break; case ITEM_ICON_TYPE.NONE: break; } int enemy_icon_id = 0; if (iTEM_ICON_TYPE == ITEM_ICON_TYPE.ITEM) { ItemTable.ItemData itemData = Singleton <ItemTable> .I.GetItemData(data.GetTableID()); enemy_icon_id = itemData.enemyIconID; } ItemIcon itemIcon = null; if (data.GetIconType() == ITEM_ICON_TYPE.QUEST_ITEM) { ItemIcon.ItemIconCreateParam itemIconCreateParam = new ItemIcon.ItemIconCreateParam(); itemIconCreateParam.icon_type = data.GetIconType(); itemIconCreateParam.icon_id = data.GetIconID(); itemIconCreateParam.rarity = data.GetRarity(); itemIconCreateParam.parent = holder; itemIconCreateParam.element = data.GetIconElement(); itemIconCreateParam.magi_enable_equip_type = data.GetIconMagiEnableType(); itemIconCreateParam.num = data.GetNum(); itemIconCreateParam.enemy_icon_id = enemy_icon_id; itemIconCreateParam.questIconSizeType = ItemIcon.QUEST_ICON_SIZE_TYPE.REWARD_DELIVERY_LIST; itemIcon = ItemIcon.Create(itemIconCreateParam); } else { itemIcon = ItemIcon.Create(iTEM_ICON_TYPE, icon_id, rarity, holder, element, magi_enable_icon_type, -1, "DROP", 0, is_new, -1, false, null, false, enemy_icon_id, 0, false, GET_TYPE.PAY); } SetMaterialInfo(itemIcon.transform, data.GetMaterialType(), data.GetTableID(), parent_scroll); }
private void SetQuestData(QuestTable.QuestTableData questData, Transform t) { //IL_0257: Unknown result type (might be due to invalid IL or missing references) //IL_0264: Unknown result type (might be due to invalid IL or missing references) //IL_0279: Unknown result type (might be due to invalid IL or missing references) //IL_02ff: Unknown result type (might be due to invalid IL or missing references) //IL_030c: Unknown result type (might be due to invalid IL or missing references) //IL_0319: Unknown result type (might be due to invalid IL or missing references) UI[] array = new UI[10] { UI.OBJ_DIFFICULT_STAR_1, UI.OBJ_DIFFICULT_STAR_2, UI.OBJ_DIFFICULT_STAR_3, UI.OBJ_DIFFICULT_STAR_4, UI.OBJ_DIFFICULT_STAR_5, UI.OBJ_DIFFICULT_STAR_6, UI.OBJ_DIFFICULT_STAR_7, UI.OBJ_DIFFICULT_STAR_8, UI.OBJ_DIFFICULT_STAR_9, UI.OBJ_DIFFICULT_STAR_10 }; int num = (int)(questData.difficulty + 1); int i = 0; for (int num2 = array.Length; i < num2; i++) { SetActive(t, array[i], i < num); } ResetTween(t, UI.TWN_DIFFICULT_STAR, 0); PlayTween(t, UI.TWN_DIFFICULT_STAR, true, null, false, 0); EnemyTable.EnemyData enemyData = Singleton <EnemyTable> .I.GetEnemyData((uint)questData.GetMainEnemyID()); if (enemyData != null) { SetActive(t, UI.OBJ_ENEMY, true); int iconId = enemyData.iconId; RARITY_TYPE?rarity = (questData.questType != QUEST_TYPE.ORDER) ? null : new RARITY_TYPE?(questData.rarity); ItemIcon itemIcon = ItemIcon.Create(ITEM_ICON_TYPE.QUEST_ITEM, iconId, rarity, FindCtrl(t, UI.OBJ_ENEMY), enemyData.element, null, -1, null, 0, false, -1, false, null, false, 0, 0, false, GET_TYPE.PAY); itemIcon.SetEnableCollider(false); SetActive(t, UI.SPR_ELEMENT_ROOT, enemyData.element != ELEMENT_TYPE.MAX); SetElementSprite(t, UI.SPR_ELEMENT, (int)enemyData.element); SetElementSprite(t, UI.SPR_WEAK_ELEMENT, (int)enemyData.weakElement); SetActive(t, UI.STR_NON_WEAK_ELEMENT, enemyData.weakElement == ELEMENT_TYPE.MAX); } else { SetActive(t, UI.OBJ_ENEMY, false); SetElementSprite(t, UI.SPR_WEAK_ELEMENT, 6); SetActive(t, UI.STR_NON_WEAK_ELEMENT, true); } Transform val = FindCtrl(t, UI.SPR_ICON_DOUBLE); Transform val2 = FindCtrl(t, UI.SPR_ICON_DEFENSE_BATTLE); Transform val3 = FindCtrl(t, UI.LBL_RECRUTING_MEMBERS); Transform val4 = FindCtrl(t, UI.SPR_WINDOW_BASE); if (val4 != null) { UISprite component = val4.GetComponent <UISprite>(); Transform val5 = FindCtrl(t, UI.OBJ_SEARCH_INFO_ROOT); UISprite component2 = val5.GetComponent <UISprite>(); if (questData.questType == QUEST_TYPE.GATE || questData.questType == QUEST_TYPE.DEFENSE) { component.spriteName = "QuestListPlateO"; component2.spriteName = "SearchAdWindowO"; val.get_gameObject().SetActive(true); val2.get_gameObject().SetActive(questData.questType == QUEST_TYPE.DEFENSE); val3.get_gameObject().SetActive(questData.questType == QUEST_TYPE.DEFENSE); string format = StringTable.Get(STRING_CATEGORY.GATE_QUEST_NAME, 0u); string text = string.Empty; if (enemyData != null) { text = string.Format(format, questData.GetMainEnemyLv(), enemyData.name); } SetLabelText(t, UI.LBL_QUEST_NAME, text); SetLabelText(t, UI.LBL_QUEST_NUM, string.Empty); } else { component.spriteName = "QuestListPlateN"; component2.spriteName = "SearchAdWindow"; val.get_gameObject().SetActive(false); val2.get_gameObject().SetActive(false); val3.get_gameObject().SetActive(false); SetLabelText(t, UI.LBL_QUEST_NAME, questData.questText); SetLabelText(t, UI.LBL_QUEST_NUM, string.Format(base.sectionData.GetText("QUEST_NUMBER"), questData.locationNumber, questData.questNumber)); } } else { SetLabelText(t, UI.LBL_QUEST_NAME, questData.questText); SetLabelText(t, UI.LBL_QUEST_NUM, string.Format(base.sectionData.GetText("QUEST_NUMBER"), questData.locationNumber, questData.questNumber)); } }
public void SetRarity(ITEM_ICON_TYPE icon_type, RARITY_TYPE?rarity_type, bool disable_text, GET_TYPE getType) { if (!rarity_type.HasValue && icon_type != ITEM_ICON_TYPE.QUEST_ITEM) { rarityFrame.spriteName = string.Empty; rarityFrame.set_enabled(false); rarityTextIcon.spriteName = string.Empty; rarityTextIcon.set_enabled(false); } else { int num = (int)(rarity_type.HasValue ? rarity_type.Value : RARITY_TYPE.D); rarityFrame.set_enabled(true); rarityTextIcon.set_enabled(true); switch (icon_type) { default: rarityFrame.set_enabled(isVisible); rarityFrame.spriteName = ITEM_ICON_EQUIP_RARITY_FRAME_SPRITE[num]; UIBehaviour.SetRarityColorType(num, rarityFrame); rarityTextIcon.set_enabled(!disable_text && isVisible); rarityTextIcon.spriteName = GetRarityTextSpriteName(rarity_type, getType); break; case ITEM_ICON_TYPE.USE_ITEM: rarityFrame.set_enabled(false); rarityTextIcon.set_enabled(false); break; case ITEM_ICON_TYPE.QUEST_ITEM: if (rarity_type.HasValue) { rarityFrame.set_enabled(isVisible); rarityFrame.spriteName = ITEM_ICON_MONSTER_RARITY_FRAME_SPRITE[num]; UIBehaviour.SetRarityColorType(num, rarityFrame); rarityTextIcon.set_enabled(!disable_text && isVisible); rarityTextIcon.spriteName = GetRarityTextSpriteName(rarity_type, getType); } else { rarityFrame.spriteName = ITEM_ICON_MONSTER_NORMAL_FRAME_SPRITE; rarityFrame.set_enabled(isVisible); UIBehaviour.SetRarityColorType(num, rarityFrame); rarityTextIcon.spriteName = string.Empty; rarityTextIcon.set_enabled(false); } break; case ITEM_ICON_TYPE.SKILL_ATTACK: case ITEM_ICON_TYPE.SKILL_SUPPORT: case ITEM_ICON_TYPE.SKILL_HEAL: case ITEM_ICON_TYPE.SKILL_PASSIVE: case ITEM_ICON_TYPE.SKILL_GROW: { int num2 = (int)(icon_type - 10); rarityFrame.set_enabled(isVisible); rarityFrame.spriteName = ITEM_ICON_SKILL_FRAME[num2] + ITEM_ICON_RARITY[num]; UIBehaviour.SetRarityColorType(num, rarityFrame); rarityTextIcon.set_enabled(!disable_text && isVisible); rarityTextIcon.spriteName = GetRarityTextSpriteName(rarity_type, getType); break; } case ITEM_ICON_TYPE.UNKNOWN: rarityFrame.set_enabled(false); rarityTextIcon.set_enabled(false); break; } ChangeRarityFrameAtlus(rarity_type); } }
protected static T CreateIcon <T>(Object prefab, ITEM_ICON_TYPE icon_type, int icon_id, RARITY_TYPE?rarity, Transform parent = null, ELEMENT_TYPE element = ELEMENT_TYPE.MAX, EQUIPMENT_TYPE?magi_enable_icon_type = default(EQUIPMENT_TYPE?), int num = -1, string event_name = null, int event_data = 0, bool is_new = false, int toggle_group = -1, bool is_select = false, string icon_under_text = null, bool is_equipping = false, int enemy_icon_id = 0, int enemy_icon_id2 = 0, bool disable_rarity_text = false, QUEST_ICON_SIZE_TYPE questIconSizeType = QUEST_ICON_SIZE_TYPE.DEFAULT, GET_TYPE getType = GET_TYPE.PAY) where T : ItemIcon { T val = parent.GetComponentInChildren <T>(); if (val == null) { Transform val2 = ResourceUtility.Realizes(prefab, parent, -1); val = val2.GetComponent <T>(); val._transform = val2; } val.SetEquipGrowLimitBG(false); _Create(val, icon_type, icon_id, rarity, parent, element, magi_enable_icon_type, num, event_name, event_data, is_new, toggle_group, is_select, icon_under_text, is_equipping, enemy_icon_id, enemy_icon_id2, disable_rarity_text, questIconSizeType, getType); return(val); }
public static ItemIcon CreateSmithCreateEquipDetailIcon(ITEM_ICON_TYPE icon_type, int icon_id, RARITY_TYPE?rarity, SmithCreateSortData item_data, SkillSlotUIData[] skill_slot_data, bool is_show_main_status, Transform parent = null, string event_name = null, int event_data = 0, ICON_STATUS icon_status = ICON_STATUS.NONE, bool is_new = false, int toggle_group = -1, bool is_select = false, bool is_equipping = false, GET_TYPE getType = GET_TYPE.PAY) { SmithCreateItemInfo smithCreateItemInfo = item_data.GetItemData() as SmithCreateItemInfo; ItemIconDetail itemIconDetail = ItemIcon.CreateIcon <ItemIconDetail>(MonoBehaviourSingleton <GlobalSettingsManager> .I.linkResources.itemIconDetailPrefab, icon_type, icon_id, rarity, parent, smithCreateItemInfo.equipTableData.GetTargetElementPriorityToTable(), null, -1, event_name, event_data, is_new, toggle_group, is_select, string.Empty, is_equipping, 0, 0, false, QUEST_ICON_SIZE_TYPE.DEFAULT, getType); EquipItemTable.EquipItemData equipTableData = item_data.createData.equipTableData; itemIconDetail.setupperEquip.Set(new object[6] { equipTableData, skill_slot_data, is_show_main_status, icon_status, -1, -1 }); return(itemIconDetail); }
public static int GetIconBGID(ITEM_ICON_TYPE icon_type, int icon_id, RARITY_TYPE?rarity) { int num; if (!icon_type.IsEquip()) { switch (icon_type) { default: num = 90000100; break; case ITEM_ICON_TYPE.QUEST_ITEM: num = -1; break; case ITEM_ICON_TYPE.ITEM: case ITEM_ICON_TYPE.ABILITY_ITEM: num = 90000101; if (rarity.HasValue && (int)rarity.Value < EQUIP_ITEM_RARITY_BG_ID.Length) { num += EQUIP_ITEM_RARITY_BG_ID[(int)rarity.Value]; } break; case ITEM_ICON_TYPE.SKILL_ATTACK: num = 90000001; break; case ITEM_ICON_TYPE.SKILL_SUPPORT: num = 90000002; break; case ITEM_ICON_TYPE.SKILL_HEAL: num = 90000003; break; case ITEM_ICON_TYPE.SKILL_PASSIVE: num = 90000004; break; case ITEM_ICON_TYPE.SKILL_GROW: num = 90000005; break; case ITEM_ICON_TYPE.CRYSTAL: num = 90000100; break; case ITEM_ICON_TYPE.UNKNOWN: num = 90000300; break; case ITEM_ICON_TYPE.COMMON: num = 90000100; break; } } else { num = (Singleton <EquipItemTable> .I.GetEquipItemData((uint)EquipItemTable.GetIdFromIconId(icon_id))?.spAttackType.GetItemIconBGId() ?? 90000100); } return(num); }
public static ItemIcon Create(ITEM_ICON_TYPE icon_type, int icon_id, RARITY_TYPE?rarity, Transform parent, ELEMENT_TYPE element = ELEMENT_TYPE.MAX, EQUIPMENT_TYPE?magi_enable_icon_type = default(EQUIPMENT_TYPE?), int num = -1, string event_name = null, int event_data = 0, bool is_new = false, int toggle_group = -1, bool is_select = false, string icon_under_text = null, bool is_equipping = false, int enemy_icon_id = 0, int enemy_icon_id2 = 0, bool disable_rarity_text = false, GET_TYPE getType = GET_TYPE.PAY) { return(CreateIcon <ItemIcon>(MonoBehaviourSingleton <GlobalSettingsManager> .I.linkResources.itemIconPrefab, icon_type, icon_id, rarity, parent, element, magi_enable_icon_type, num, event_name, event_data, is_new, toggle_group, is_select, icon_under_text, is_equipping, enemy_icon_id, enemy_icon_id2, disable_rarity_text, QUEST_ICON_SIZE_TYPE.DEFAULT, getType)); }
protected override void UpdateEquipIcon(List <CharaInfo.EquipItem> equip_set_info) { //IL_0300: Unknown result type (might be due to invalid IL or missing references) //IL_0398: Unknown result type (might be due to invalid IL or missing references) SetActive(transRoot, UI.LBL_CHANGE_MODE, isVisualMode); int i = 0; for (int num = 7; i < num; i++) { SetEvent(FindCtrl(transRoot, icons[i]), "EMPTY", 0); SetEvent(FindCtrl(transRoot, icons_btn[i]), "EMPTY", 0); SetLabelText(FindCtrl(transRoot, icons_level[i]), string.Empty); } bool flag = isVisualMode; bool flag2 = isVisualMode; bool flag3 = isVisualMode; bool flag4 = isVisualMode; if (localEquipSet != null) { int j = 0; for (int num2 = localEquipSet.item.Length; j < num2; j++) { ITEM_ICON_TYPE iTEM_ICON_TYPE = ITEM_ICON_TYPE.NONE; RARITY_TYPE? nullable = null; ELEMENT_TYPE eLEMENT_TYPE = ELEMENT_TYPE.MAX; int num3 = -1; EquipItemInfo equipItemInfo = localEquipSet.item[j]; EquipItemTable.EquipItemData equipItemData = null; if (equipItemInfo != null) { switch (equipItemInfo.tableData.type) { case EQUIPMENT_TYPE.ARMOR: flag2 = false; break; case EQUIPMENT_TYPE.HELM: flag = false; break; case EQUIPMENT_TYPE.ARM: flag3 = false; break; case EQUIPMENT_TYPE.LEG: flag4 = false; break; } equipItemData = ((!isVisualMode) ? Singleton <EquipItemTable> .I.GetEquipItemData(equipItemInfo.tableID) : GetVisualModeTargetTable(equipItemInfo.tableData.id, equipItemInfo.tableData.type, record.charaInfo)); } if (isVisualMode) { if (equipItemData != null) { iTEM_ICON_TYPE = ItemIcon.GetItemIconType(equipItemData.type); nullable = equipItemData.rarity; eLEMENT_TYPE = equipItemData.GetTargetElementPriorityToTable(); num3 = equipItemData.GetIconID(MonoBehaviourSingleton <UserInfoManager> .I.userStatus.sex); SetActive(FindCtrl(transRoot, icons_level[j]), false); } } else if (equipItemInfo != null && equipItemInfo.tableID != 0) { num3 = equipItemData.GetIconID(MonoBehaviourSingleton <UserInfoManager> .I.userStatus.sex); SetActive(FindCtrl(transRoot, icons_level[j]), true); string text = string.Format(StringTable.Get(STRING_CATEGORY.MAIN_STATUS, 1u), equipItemInfo.level.ToString()); SetLabelText(FindCtrl(transRoot, icons_level[j]), text); } Transform val = FindCtrl(transRoot, icons[j]); val.GetComponentsInChildren <ItemIcon>(true, Temporary.itemIconList); int k = 0; for (int count = Temporary.itemIconList.Count; k < count; k++) { Temporary.itemIconList[k].get_gameObject().SetActive(true); } Temporary.itemIconList.Clear(); ItemIcon itemIcon = ItemIcon.CreateEquipItemIconByEquipItemInfo(equipItemInfo, MonoBehaviourSingleton <UserInfoManager> .I.userStatus.sex, val, null, -1, "EQUIP", j, false, -1, false, null, false, false); SetLongTouch(itemIcon.transform, "DETAIL", j); SetEvent(FindCtrl(transRoot, icons_btn[j]), "DETAIL", j); itemIcon.get_gameObject().SetActive(num3 != -1); if (num3 != -1) { itemIcon.SetEquipExtInvertedColor(equipItemInfo, base.GetComponent <UILabel>((Enum)icons_level[j])); } UpdateEquipSkillButton(equipItemInfo, j); } ResetTween(transRoot, UI.OBJ_EQUIP_ROOT, 0); PlayTween(transRoot, UI.OBJ_EQUIP_ROOT, true, null, false, 0); } if (flag && record.charaInfo.hId != 0) { int index = 4; int hId = record.charaInfo.hId; EQUIPMENT_TYPE e_type = EQUIPMENT_TYPE.HELM; CharaInfo charaInfo = record.charaInfo; SetVisualModeIcon(index, hId, e_type, charaInfo); } if (flag2 && record.charaInfo.aId != 0) { int index2 = 3; int aId = record.charaInfo.aId; EQUIPMENT_TYPE e_type2 = EQUIPMENT_TYPE.ARMOR; CharaInfo charaInfo2 = record.charaInfo; SetVisualModeIcon(index2, aId, e_type2, charaInfo2); } if (flag3 && record.charaInfo.rId != 0) { int index3 = 5; int rId = record.charaInfo.rId; EQUIPMENT_TYPE e_type3 = EQUIPMENT_TYPE.ARM; CharaInfo charaInfo3 = record.charaInfo; SetVisualModeIcon(index3, rId, e_type3, charaInfo3); } if (flag4 && record.charaInfo.lId != 0) { int index4 = 6; int lId = record.charaInfo.lId; EQUIPMENT_TYPE e_type4 = EQUIPMENT_TYPE.LEG; CharaInfo charaInfo4 = record.charaInfo; SetVisualModeIcon(index4, lId, e_type4, charaInfo4); } }
protected static void _Create(ItemIcon item_icon, ITEM_ICON_TYPE icon_type, int icon_id, RARITY_TYPE?rarity, Transform parent, ELEMENT_TYPE element, EQUIPMENT_TYPE?magi_enable_icon_type, int num, string event_name, int event_data, bool is_new, int toggle_group, bool is_select, string icon_under_text, bool is_equipping, int enemy_icon_id, int enemy_icon_id2, bool disable_rarity_text, QUEST_ICON_SIZE_TYPE questIconSizeType, GET_TYPE getType) { //IL_02d6: Unknown result type (might be due to invalid IL or missing references) //IL_037b: Unknown result type (might be due to invalid IL or missing references) //IL_0396: Unknown result type (might be due to invalid IL or missing references) //IL_03ac: Unknown result type (might be due to invalid IL or missing references) //IL_03d9: Unknown result type (might be due to invalid IL or missing references) //IL_03f5: Unknown result type (might be due to invalid IL or missing references) //IL_044e: Unknown result type (might be due to invalid IL or missing references) //IL_04a9: Unknown result type (might be due to invalid IL or missing references) //IL_04fb: Unknown result type (might be due to invalid IL or missing references) //IL_0527: Unknown result type (might be due to invalid IL or missing references) if (icon_id == 24019000) { icon_type = ITEM_ICON_TYPE.SKILL_GROW; } item_icon.itemID = 0; item_icon.iconType = icon_type; if (icon_id >= 0) { int iconBGID = GetIconBGID(icon_type, icon_id, rarity); item_icon.bgID = iconBGID; item_icon.bg.mainTexture = null; item_icon.frameTexture = null; ResourceLoad.ItemIconLoadIconBGTexture(item_icon, iconBGID, delegate(ItemIcon _item_icon, Texture _tex, int _icon_id) { if (_item_icon.bgID == _icon_id) { item_icon.frameTexture = _tex; item_icon.bg.mainTexture = ((!item_icon.isVisible) ? null : item_icon.frameTexture); } }); item_icon.VisibleIcon(item_icon.isVisible, !string.IsNullOrEmpty(event_name)); item_icon.bg.set_enabled(iconBGID >= 0); SetupElementIcon(item_icon, icon_type, element); item_icon.SetRarity(icon_type, rarity, disable_rarity_text, getType); item_icon.enemyIconID = enemy_icon_id; item_icon.enemyIconItem.mainTexture = null; if (enemy_icon_id != 0) { item_icon.enemyIconItem.set_enabled(true); ResourceLoad.ItemIconLoadEnemyIconItemTexture(item_icon, enemy_icon_id, delegate(ItemIcon _item_icon, Texture _tex, int _enemy_icon_id) { if (_item_icon.enemyIconID == _enemy_icon_id) { _item_icon.enemyIconItem.mainTexture = _tex; } }); } else { item_icon.enemyIconItem.set_enabled(false); } if (!object.ReferenceEquals(item_icon.enemyIconItem2, null)) { item_icon.enemyIconID2 = enemy_icon_id2; item_icon.enemyIconItem2.mainTexture = null; if (enemy_icon_id2 != 0) { item_icon.enemyIconItem2.set_enabled(true); ResourceLoad.ItemIconLoadEnemyIconItemTexture(item_icon, enemy_icon_id2, delegate(ItemIcon _item_icon, Texture _tex, int _enemy_icon_id2) { if (_item_icon.enemyIconID2 == _enemy_icon_id2) { _item_icon.enemyIconItem2.mainTexture = _tex; } }); } else { item_icon.enemyIconItem2.set_enabled(false); } } item_icon.questIconSizeType = questIconSizeType; item_icon.LoadIconTexture(icon_type, icon_id); } else { item_icon.icon.mainTexture = null; item_icon.frameTexture = null; item_icon.bg.mainTexture = item_icon.emptyTexture; item_icon.iconTypeSprite.set_enabled(false); item_icon.rarityFrame.set_enabled(false); item_icon.rarityTextIcon.set_enabled(false); item_icon.enemyIconItem.mainTexture = null; if (!object.ReferenceEquals(item_icon.enemyIconItem2, null)) { item_icon.enemyIconItem2.mainTexture = null; } } if (num == -1) { num = 1; } item_icon.label.text = "×" + num.ToString(); item_icon.label.get_gameObject().SetActive(num > 1); if (!string.IsNullOrEmpty(event_name)) { item_icon.button.set_enabled(true); item_icon.sender.eventName = event_name; item_icon.sender.eventData = event_data; } else { item_icon.button.set_enabled(false); } if (!string.IsNullOrEmpty(icon_under_text)) { item_icon.textLabel.supportEncoding = true; item_icon.textLabel.text = icon_under_text; item_icon.textLabel.get_gameObject().SetActive(true); } else { item_icon.textLabel.get_gameObject().SetActive(false); } item_icon.equippingSprite.get_gameObject().SetActive(is_equipping); if (item_icon.favoriteSprite != null) { item_icon.favoriteSprite.get_gameObject().SetActive(false); } item_icon.gridEquippingMark = item_icon.equippingSprite.get_gameObject().GetComponentInParent <UIGrid>(); if (item_icon.gridEquippingMark != null) { item_icon.gridEquippingMark.Reposition(); } if (toggle_group < 0) { item_icon.toggleSelectFrame.set_enabled(false); item_icon.selectFrame.get_gameObject().SetActive(false); } else { if (!item_icon.toggleSelectFrame.get_enabled()) { item_icon.toggleSelectFrame.activeSprite.alpha = 0f; } item_icon.toggleSelectFrame.set_enabled(true); item_icon.selectFrame.get_gameObject().SetActive(true); item_icon.toggleSelectFrame.group = toggle_group; item_icon.toggleSelectFrame.Set(is_select); } if (is_new) { item_icon.newIcon.set_enabled(true); item_icon.newIcon.get_gameObject().SetActive(true); } else { item_icon.newIcon.set_enabled(false); item_icon.newIcon.get_gameObject().SetActive(false); } item_icon.SetSkillEnableEquipIcon(magi_enable_icon_type); item_icon.SetRewardBG(false); }
protected virtual void ShowSelectUI() { //IL_0240: Unknown result type (might be due to invalid IL or missing references) //IL_024f: Unknown result type (might be due to invalid IL or missing references) int num = (!isInGameScene && TutorialStep.HasQuestSpecialUnlocked()) ? 1 : 2; int num2 = (showMode != 0) ? num : 0; int num3 = (showMode != SHOW_MODE.QUEST) ? num : 0; int num4 = (showMode != SHOW_MODE.ORDER) ? num : 0; SetActive((Enum)UI.OBJ_DELIVERY_ROOT, showMode == SHOW_MODE.DELIVERY); SetActive((Enum)UI.OBJ_QUEST_ROOT, showMode == SHOW_MODE.QUEST); SetActive((Enum)UI.OBJ_ORDER_ROOT, showMode == SHOW_MODE.ORDER); SetButtonSprite((Enum)UI.BTN_DELIVERY, "QuestTabBtnBase" + SPR_ON_OFF[num2], true); SetSprite((Enum)UI.SPR_DELIVERY_TEXT, "QuestTabBtnText" + SPR_INDEX[0] + SPR_ON_OFF[num2]); SetSprite((Enum)UI.SPR_DELIVERY_ICON, "QuestTabBtnIcon" + SPR_INDEX[0] + SPR_ON_OFF[num2]); SetButtonSprite((Enum)UI.BTN_QUEST, "QuestTabBtnBase" + SPR_ON_OFF[num3], true); SetSprite((Enum)UI.SPR_QUEST_TEXT, "QuestTabBtnText" + SPR_INDEX[1] + SPR_ON_OFF[num3]); SetSprite((Enum)UI.SPR_QUEST_ICON, "QuestTabBtnIcon" + SPR_INDEX[1] + SPR_ON_OFF[num3]); SetButtonSprite((Enum)UI.BTN_ORDER, "QuestTabBtnBase" + SPR_ON_OFF[num4], true); SetSprite((Enum)UI.SPR_ORDER_TEXT, "QuestTabBtnText" + SPR_INDEX[2] + SPR_ON_OFF[num4]); SetSprite((Enum)UI.SPR_ORDER_ICON, "QuestTabBtnIcon" + SPR_INDEX[2] + SPR_ON_OFF[num4]); if (!TutorialStep.HasQuestSpecialUnlocked()) { SetButtonEnabled((Enum)UI.BTN_QUEST, false); SetButtonEnabled((Enum)UI.BTN_ORDER, false); SetActive((Enum)UI.BTN_EVENT, false); } if (!isInGameScene) { SetRenderNPCModel((Enum)UI.TEX_NPCMODEL, 0, MonoBehaviourSingleton <OutGameSettingsManager> .I.homeScene.questCenterNPCPos, MonoBehaviourSingleton <OutGameSettingsManager> .I.homeScene.questCenterNPCRot, MonoBehaviourSingleton <OutGameSettingsManager> .I.homeScene.questCenterNPCFOV, (Action <NPCLoader>)null); SetLabelText((Enum)UI.LBL_NPC_MESSAGE, npcText); } SetActive((Enum)UI.OBJ_NPC_MESSAGE, !isInGameScene); if (showMode == SHOW_MODE.DELIVERY) { SetActive((Enum)UI.SPR_TAB_NORMAL, UI.BTN_TAB_NORMAL == selectedTab); SetActive((Enum)UI.SPR_TAB_DAILY, UI.BTN_TAB_DAILY == selectedTab); SetActive((Enum)UI.SPR_TAB_WEEKLY, UI.BTN_TAB_WEEKLY == selectedTab); SetButtonSprite((Enum)UI.BTN_TAB_NORMAL, (selectedTab != UI.BTN_TAB_NORMAL) ? "PickeShopBtn_Normal_off" : "PickeShopBtn_Green_on", false); SetButtonSprite((Enum)UI.BTN_TAB_DAILY, (selectedTab != UI.BTN_TAB_DAILY) ? "PickeShopBtn_Normal_off" : "PickeShopBtn_Green_on", false); SetButtonSprite((Enum)UI.BTN_TAB_WEEKLY, (selectedTab != UI.BTN_TAB_WEEKLY) ? "PickeShopBtn_Normal_off" : "PickeShopBtn_Green_on", false); SetNPCMessage(selectedTab); switch (selectedTab) { case UI.BTN_TAB_NORMAL: SetDeliveryList(normalDeliveryInfo); break; case UI.BTN_TAB_DAILY: SetDeliveryList(dailyDeliveryInfo); break; case UI.BTN_TAB_WEEKLY: SetDeliveryList(weeklyDeliveryInfo); break; } } else if (showMode == SHOW_MODE.ORDER) { if (questItemAry == null && MonoBehaviourSingleton <InventoryManager> .I.questItemInventory.GetCount() > 0) { List <QuestItemInfo> list = new List <QuestItemInfo>(); MonoBehaviourSingleton <InventoryManager> .I.ForAllQuestInvetory(delegate(QuestItemInfo item) { if (item.infoData.questData.num > 0) { list.Add(item); } }); questItemAry = list.ToArray(); GetCtrl(UI.GRD_ORDER_QUEST).DestroyChildren(); } if (questItemAry == null || questItemAry.Length == 0) { SetActive((Enum)UI.BTN_SORT, false); SetActive((Enum)UI.GRD_ORDER_QUEST, false); SetActive((Enum)UI.STR_ORDER_NON_LIST, true); } else { questSortData = sortSettings.CreateSortAry <QuestItemInfo, QuestSortData>(questItemAry); SetActive((Enum)UI.GRD_ORDER_QUEST, true); SetActive((Enum)UI.STR_ORDER_NON_LIST, false); SetActive((Enum)UI.BTN_SORT, true); SetLabelText((Enum)UI.LBL_SORT, sortSettings.GetSortLabel()); SetToggle((Enum)UI.TGL_ICON_ASC, sortSettings.orderTypeAsc); SetDynamicList((Enum)UI.GRD_ORDER_QUEST, "QuestListOrderItem", questSortData.Length, false, (Func <int, bool>) null, (Func <int, Transform, Transform>) null, (Action <int, Transform, bool>) delegate(int i, Transform t, bool is_recycle) { QuestSpecialSelect questSpecialSelect2 = this; SetActive(t, true); SetEvent(t, "SELECT_ORDER", i); QuestInfoData info2 = this.questSortData[i].itemData.infoData; int num9 = (int)(info2.questData.tableData.difficulty + 1); int l = 0; for (int num10 = difficult.Length; l < num10; l++) { SetActive(t, difficult[l], l < num9); } if (!is_recycle) { ResetTween(t, UI.TWN_DIFFICULT_STAR, 0); PlayTween(t, UI.TWN_DIFFICULT_STAR, true, null, false, 0); } EnemyTable.EnemyData enemyData2 = Singleton <EnemyTable> .I.GetEnemyData((uint)info2.questData.tableData.GetMainEnemyID()); QuestSortData questSortData = this.questSortData[i]; ItemIcon itemIcon2 = ItemIcon.Create(questSortData.GetIconType(), questSortData.GetIconID(), questSortData.GetRarity(), FindCtrl(t, UI.OBJ_ENEMY), questSortData.GetIconElement(), null, -1, null, 0, false, -1, false, null, false, 0, 0, false, GET_TYPE.PAY); itemIcon2.SetEnableCollider(false); SetActive(t, UI.SPR_ELEMENT_ROOT, enemyData2.element != ELEMENT_TYPE.MAX); SetElementSprite(t, UI.SPR_ELEMENT, (int)enemyData2.element); SetElementSprite(t, UI.SPR_WEAK_ELEMENT, (int)enemyData2.weakElement); SetActive(t, UI.STR_NON_WEAK_ELEMENT, enemyData2.weakElement == ELEMENT_TYPE.MAX); SetLabelText(t, UI.LBL_QUEST_NAME, info2.questData.tableData.questText); int num11 = 1; ClearStatusQuest clearStatusQuest2 = MonoBehaviourSingleton <QuestManager> .I.clearStatusQuest.Find((ClearStatusQuest data) => info2.questData.tableData.questID == data.questId); if (clearStatusQuest2 != null) { num11 = clearStatusQuest2.questStatus; } int value2 = i + 100; SetToggleGroup(t, UI.OBJ_ICON_NEW, value2); SetToggleGroup(t, UI.OBJ_ICON_CLEARED, value2); SetToggleGroup(t, UI.OBJ_ICON_COMPLETE, value2); switch (num11) { default: SetToggle(t, UI.OBJ_ICON_NEW, false); SetToggle(t, UI.OBJ_ICON_CLEARED, false); SetToggle(t, UI.OBJ_ICON_COMPLETE, false); break; case 1: SetToggle(t, UI.OBJ_ICON_NEW, true); SetVisibleWidgetEffect(UI.SCR_ORDER_QUEST, t, UI.SPR_ICON_NEW, "ef_ui_questselect_new"); break; case 3: SetToggle(t, UI.OBJ_ICON_CLEARED, true); break; case 4: SetToggle(t, UI.OBJ_ICON_COMPLETE, true); SetVisibleWidgetEffect(UI.SCR_ORDER_QUEST, t, UI.SPR_ICON_COMPLETE, "ef_ui_questselect_complete"); break; } SetLabelText(t, UI.LBL_ORDER_NUM, info2.questData.num.ToString()); SetActive(t, UI.LBL_REMAIN, false); }); } } else if (showMode == SHOW_MODE.QUEST) { if (questInfo == null || questInfo.Length == 0) { SetActive((Enum)UI.GRD_QUEST, false); SetActive((Enum)UI.STR_QUEST_NON_LIST, true); } else { SetActive((Enum)UI.STR_QUEST_NON_LIST, false); SetActive((Enum)UI.GRD_QUEST, true); SetDynamicList((Enum)UI.GRD_QUEST, "QuestListItem", questInfo.Length, false, (Func <int, bool>) null, (Func <int, Transform, Transform>) null, (Action <int, Transform, bool>) delegate(int i, Transform t, bool is_recycle) { QuestSpecialSelect questSpecialSelect = this; SetEvent(t, "SELECT_QUEST", i); QuestInfoData info = questInfo[i]; int num5 = (int)(info.questData.tableData.difficulty + 1); int j = 0; for (int num6 = difficult.Length; j < num6; j++) { SetActive(t, difficult[j], j < num5); } if (!is_recycle) { ResetTween(t, UI.TWN_DIFFICULT_STAR, 0); PlayTween(t, UI.TWN_DIFFICULT_STAR, true, null, false, 0); } EnemyTable.EnemyData enemyData = Singleton <EnemyTable> .I.GetEnemyData((uint)info.questData.tableData.GetMainEnemyID()); if (enemyData != null) { SetActive(t, UI.OBJ_ENEMY, true); int iconId = enemyData.iconId; RARITY_TYPE?rarity = (info.questData.tableData.questType != QUEST_TYPE.ORDER) ? null : new RARITY_TYPE?(info.questData.tableData.rarity); ItemIcon itemIcon = ItemIcon.Create(ITEM_ICON_TYPE.QUEST_ITEM, iconId, rarity, FindCtrl(t, UI.OBJ_ENEMY), enemyData.element, null, -1, null, 0, false, -1, false, null, false, 0, 0, false, GET_TYPE.PAY); itemIcon.SetEnableCollider(false); SetActive(t, UI.SPR_ELEMENT_ROOT, enemyData.element != ELEMENT_TYPE.MAX); SetElementSprite(t, UI.SPR_ELEMENT, (int)enemyData.element); SetElementSprite(t, UI.SPR_WEAK_ELEMENT, (int)enemyData.weakElement); SetActive(t, UI.STR_NON_WEAK_ELEMENT, enemyData.weakElement == ELEMENT_TYPE.MAX); } else { SetActive(t, UI.OBJ_ENEMY, false); SetElementSprite(t, UI.SPR_WEAK_ELEMENT, 6); SetActive(t, UI.STR_NON_WEAK_ELEMENT, true); } SetLabelText(t, UI.LBL_QUEST_NUM, string.Empty); SetLabelText(t, UI.LBL_QUEST_NAME, info.questData.tableData.questText); if (!info.isExistMission) { SetActive(t, UI.OBJ_MISSION_INFO_ROOT, false); } else { SetActive(t, UI.OBJ_MISSION_INFO_ROOT, true); int k = 0; for (int num7 = info.missionData.Length; k < num7; k++) { SetActive(t, ui_top_crown[k], info.missionData[k] != null); if (info.missionData[k] != null) { SetActive(t, ui_crown[k], info.missionData[k].state >= CLEAR_STATUS.CLEAR); } } } int num8 = 1; ClearStatusQuest clearStatusQuest = MonoBehaviourSingleton <QuestManager> .I.clearStatusQuest.Find((ClearStatusQuest data) => info.questData.tableData.questID == data.questId); if (clearStatusQuest != null) { num8 = clearStatusQuest.questStatus; } int value = i + 100; SetToggleGroup(t, UI.OBJ_ICON_NEW, value); SetToggleGroup(t, UI.OBJ_ICON_CLEARED, value); SetToggleGroup(t, UI.OBJ_ICON_COMPLETE, value); switch (num8) { default: SetToggle(t, UI.OBJ_ICON_NEW, false); SetToggle(t, UI.OBJ_ICON_CLEARED, false); SetToggle(t, UI.OBJ_ICON_COMPLETE, false); break; case 1: SetToggle(t, UI.OBJ_ICON_NEW, true); SetVisibleWidgetEffect(UI.SCR_NORMAL_QUEST, t, UI.SPR_ICON_NEW, "ef_ui_questselect_new"); break; case 3: SetToggle(t, UI.OBJ_ICON_CLEARED, true); break; case 4: SetToggle(t, UI.OBJ_ICON_COMPLETE, true); SetVisibleWidgetEffect(UI.SCR_NORMAL_QUEST, t, UI.SPR_ICON_COMPLETE, "ef_ui_questselect_complete"); break; } }); } } }
public static void GetIconShowData(REWARD_TYPE reward_type, uint id, out int icon_id, out ITEM_ICON_TYPE icon_type, out RARITY_TYPE?rarity, out ELEMENT_TYPE element, out EQUIPMENT_TYPE?magi_enable_icon_type, out int enemy_icon_id, out int enemy_icon_id2, out GET_TYPE getType, int exceed_cnt = 0) { icon_type = ITEM_ICON_TYPE.NONE; icon_id = -1; rarity = null; element = ELEMENT_TYPE.MAX; magi_enable_icon_type = null; enemy_icon_id = 0; enemy_icon_id2 = 0; getType = GET_TYPE.PAY; switch (reward_type) { case REWARD_TYPE.CRYSTAL: icon_id = 1; icon_type = ITEM_ICON_TYPE.CRYSTAL; break; case REWARD_TYPE.MONEY: icon_id = 2; break; case REWARD_TYPE.EXP: icon_id = 3; break; case REWARD_TYPE.ITEM: case REWARD_TYPE.ABILITY_ITEM: { ItemTable.ItemData itemData = Singleton <ItemTable> .I.GetItemData(id); if (itemData != null) { icon_type = ((itemData.type != ITEM_TYPE.USE_ITEM) ? ITEM_ICON_TYPE.ITEM : ITEM_ICON_TYPE.USE_ITEM); icon_id = itemData.iconID; rarity = itemData.rarity; enemy_icon_id = itemData.enemyIconID; enemy_icon_id2 = itemData.enemyIconID2; } break; } case REWARD_TYPE.EQUIP_ITEM: { EquipItemTable.EquipItemData equipItemData = Singleton <EquipItemTable> .I.GetEquipItemData(id); if (equipItemData != null) { icon_type = GetItemIconType(equipItemData.type); icon_id = equipItemData.GetIconID(MonoBehaviourSingleton <UserInfoManager> .I.userStatus.sex); rarity = equipItemData.rarity; element = equipItemData.GetTargetElementPriorityToTable(); getType = equipItemData.getType; } break; } case REWARD_TYPE.SKILL_ITEM: { SkillItemTable.SkillItemData skillItemData = Singleton <SkillItemTable> .I.GetSkillItemData(id); if (skillItemData != null) { icon_type = GetItemIconType(skillItemData.type); icon_id = skillItemData.iconID; rarity = skillItemData.rarity; element = skillItemData.skillAtkType; magi_enable_icon_type = skillItemData.GetEnableEquipType(); } break; } case REWARD_TYPE.QUEST_ITEM: { QuestTable.QuestTableData questData = Singleton <QuestTable> .I.GetQuestData(id); if (questData != null) { icon_type = GetItemIconType(questData.questType); EnemyTable.EnemyData enemyData = Singleton <EnemyTable> .I.GetEnemyData((uint)questData.GetMainEnemyID()); icon_id = enemyData.iconId; rarity = questData.rarity; element = enemyData.element; } break; } case REWARD_TYPE.AVATAR: case REWARD_TYPE.COMMON: icon_type = ITEM_ICON_TYPE.COMMON; icon_id = (int)id; break; case REWARD_TYPE.STAMP: icon_type = ITEM_ICON_TYPE.STAMP; icon_id = (int)id; break; case REWARD_TYPE.DEGREE: icon_type = ITEM_ICON_TYPE.DEGREE; icon_id = (int)id; break; case REWARD_TYPE.POINT_SHOP_POINT: icon_type = ITEM_ICON_TYPE.POINT_SHOP_ICON; icon_id = (int)id; break; } }
private ItemIcon CreateItemIcon(SortCompareData dropItem, Transform o, string event_name, int i) { ITEM_ICON_TYPE iTEM_ICON_TYPE = ITEM_ICON_TYPE.NONE; RARITY_TYPE? rarity = null; ELEMENT_TYPE element = ELEMENT_TYPE.MAX; EQUIPMENT_TYPE?magi_enable_icon_type = null; int icon_id = -1; int num = -1; if (dropItem != null) { iTEM_ICON_TYPE = dropItem.GetIconType(); icon_id = dropItem.GetIconID(); rarity = dropItem.GetRarity(); element = dropItem.GetIconElement(); magi_enable_icon_type = dropItem.GetIconMagiEnableType(); num = dropItem.GetNum(); if (num == 1) { num = -1; } } bool is_new = false; switch (iTEM_ICON_TYPE) { case ITEM_ICON_TYPE.ITEM: case ITEM_ICON_TYPE.QUEST_ITEM: { ulong uniqID = dropItem.GetUniqID(); if (uniqID != 0L) { is_new = MonoBehaviourSingleton <InventoryManager> .I.IsNewItem(iTEM_ICON_TYPE, dropItem.GetUniqID()); } break; } default: is_new = true; break; case ITEM_ICON_TYPE.NONE: break; } int enemy_icon_id = 0; int enemy_icon_id2 = 0; if (iTEM_ICON_TYPE == ITEM_ICON_TYPE.ITEM) { ItemTable.ItemData itemData = Singleton <ItemTable> .I.GetItemData(dropItem.GetTableID()); enemy_icon_id = itemData.enemyIconID; enemy_icon_id2 = itemData.enemyIconID2; } ItemIcon itemIcon = null; if (dropItem.GetIconType() == ITEM_ICON_TYPE.QUEST_ITEM) { ItemIcon.ItemIconCreateParam itemIconCreateParam = new ItemIcon.ItemIconCreateParam(); itemIconCreateParam.icon_type = dropItem.GetIconType(); itemIconCreateParam.icon_id = dropItem.GetIconID(); itemIconCreateParam.rarity = dropItem.GetRarity(); itemIconCreateParam.parent = o; itemIconCreateParam.element = dropItem.GetIconElement(); itemIconCreateParam.magi_enable_equip_type = dropItem.GetIconMagiEnableType(); itemIconCreateParam.num = dropItem.GetNum(); itemIconCreateParam.enemy_icon_id = enemy_icon_id; itemIconCreateParam.enemy_icon_id2 = enemy_icon_id2; itemIconCreateParam.questIconSizeType = ItemIcon.QUEST_ICON_SIZE_TYPE.REWARD_DELIVERY_LIST; itemIcon = ItemIcon.Create(itemIconCreateParam); } else { GET_TYPE getType = dropItem.GetGetType(); itemIcon = ItemIcon.Create(iTEM_ICON_TYPE, icon_id, rarity, o, element, magi_enable_icon_type, num, event_name, i, is_new, -1, false, null, false, enemy_icon_id, enemy_icon_id2, false, getType); } itemIcon.SetRewardBG(true); itemIcon.SetRewardCategoryInfo(dropItem.GetCategory()); Transform ctrl = GetCtrl(UI.PNL_MATERIAL_INFO); MaterialInfoButton.Set(itemIcon.transform, material_info_t, dropItem.GetMaterialType(), dropItem.GetTableID(), base.sectionData.sectionName, ctrl); return(itemIcon); }
protected ItemIcon CreateSmithCreateItemIconDetail(ITEM_ICON_TYPE icon_type, int icon_id, RARITY_TYPE?rarity, SmithCreateSortData item_data, SkillSlotUIData[] skill_slot_data, bool is_show_main_status, Transform parent = null, string event_name = null, int event_data = 0, ItemIconDetail.ICON_STATUS icon_status = ItemIconDetail.ICON_STATUS.NONE, bool is_new = false, int toggle_group = -1, bool is_select = false, GET_TYPE getType = GET_TYPE.PAY) { bool registedIcon = MonoBehaviourSingleton <AchievementManager> .I.CheckEquipItemCollection(item_data.createData.equipTableData); if (InventoryUI == UI.GRD_INVENTORY) { ItemIcon itemIcon = ItemIconDetail.CreateSmithCreateEquipDetailIcon(icon_type, icon_id, rarity, item_data, skill_slot_data, is_show_main_status, parent, event_name, event_data, icon_status, is_new, toggle_group, is_select, false, getType); ItemIconDetail itemIconDetail = itemIcon as ItemIconDetail; if (itemIconDetail != null) { itemIconDetail.setupperEquip.SetRegistedIcon(registedIcon); } return(itemIcon); } ItemIcon itemIcon2 = ItemIconDetailSmall.CreateSmithCreateEquipDetailIcon(icon_type, icon_id, rarity, item_data, parent, event_name, event_data, icon_status, is_new, toggle_group, is_select, false, getType); ItemIconDetailSmall itemIconDetailSmall = itemIcon2 as ItemIconDetailSmall; if (itemIconDetailSmall != null) { itemIconDetailSmall.SetRegistedIcon(registedIcon); } return(itemIcon2); }
public static ItemIcon CreateQuestItemIcon(ITEM_ICON_TYPE icon_type, int icon_id, RARITY_TYPE?rarity, QuestSortData quest_item, bool is_show_main_status, Transform parent = null, int num = -1, string name = null, string event_name = null, int event_data = 0, int toggle_group = -1, bool is_select = false, bool is_new = false) { ItemIconDetail itemIconDetail = ItemIcon.CreateIcon <ItemIconDetail>(MonoBehaviourSingleton <GlobalSettingsManager> .I.linkResources.itemIconDetailPrefab, icon_type, icon_id, rarity, parent, quest_item.GetEnemyElement(), null, -1, event_name, event_data, is_new, toggle_group, is_select, string.Empty, false, 0, 0, false, QUEST_ICON_SIZE_TYPE.DEFAULT, GET_TYPE.PAY); itemIconDetail.setupperQuestItem.Set(new object[2] { quest_item, is_show_main_status }); return(itemIconDetail); }