protected override void EquipParam()
    {
        EquipItemInfo item = EquipItem;

        EquipItemTable.EquipItemData equipItemData = (item == null) ? null : item.tableData;
        if (item != null && equipItemData != null)
        {
            SetLabelText((Enum)UI.LBL_NAME, equipItemData.name);
            SetLabelEquipItemParam(item, GetCompareItemData());
            SetActive((Enum)UI.SPR_IS_EVOLVE, item.tableData.IsEvolve());
            SetSkillIconButton(UI.OBJ_SKILL_BUTTON_ROOT, "SkillIconButton", equipItemData, GetSkillSlotData(item), "SKILL_ICON_BUTTON", 0);
            SetEquipmentTypeIcon((Enum)UI.SPR_TYPE_ICON, (Enum)UI.SPR_TYPE_ICON_BG, (Enum)UI.SPR_TYPE_ICON_RARITY, item.tableData);
            SetLabelText((Enum)UI.LBL_SELL, item.sellPrice.ToString());
            if (item.ability != null && item.ability.Length > 0)
            {
                bool empty_ability = true;
                SetTable(UI.TBL_ABILITY, "ItemDetailEquipAbilityItem", item.ability.Length, false, delegate(int i, Transform t, bool is_recycle)
                {
                    EquipItemAbility equipItemAbility = item.ability[i];
                    if (equipItemAbility.id == 0)
                    {
                        SetActive(t, false);
                    }
                    else
                    {
                        empty_ability = false;
                        SetActive(t, true);
                        if (item.IsFixedAbility(i))
                        {
                            SetActive(t, UI.OBJ_ABILITY, false);
                            SetActive(t, UI.OBJ_FIXEDABILITY, true);
                            SetLabelText(t, UI.LBL_FIXEDABILITY, equipItemAbility.GetName());
                            SetLabelText(t, UI.LBL_FIXEDABILITY_NUM, equipItemAbility.GetAP());
                        }
                        else
                        {
                            SetLabelText(t, UI.LBL_ABILITY, equipItemAbility.GetName());
                            SetLabelText(t, UI.LBL_ABILITY_NUM, equipItemAbility.GetAP());
                        }
                        SetEvent(t, "ABILITY", i);
                    }
                });
                if (empty_ability)
                {
                    SetActive((Enum)UI.STR_NON_ABILITY, true);
                }
                else
                {
                    SetActive((Enum)UI.STR_NON_ABILITY, false);
                }
            }
            else
            {
                SetActive((Enum)UI.STR_NON_ABILITY, true);
            }
        }
    }
Esempio n. 2
0
 public string GetAP()
 {
     if (object.ReferenceEquals(ability, null))
     {
         return("+0");
     }
     return(ability.GetAP());
 }
    private void SetAbilityData(int index, EquipItemAbility ability)
    {
        UI uI  = UI.LBL_NAME_1;
        UI uI2 = UI.LBL_POINT_1;
        UI uI3 = UI.LBL_DESC_1;

        UI[] array = new UI[6]
        {
            UI.LBL_NAME_1,
            UI.LBL_NAME_2,
            UI.LBL_NAME_3,
            UI.LBL_NAME_4,
            UI.LBL_NAME_5,
            UI.LBL_NAME_6
        };
        UI[] array2 = new UI[6]
        {
            UI.LBL_POINT_1,
            UI.LBL_POINT_2,
            UI.LBL_POINT_3,
            UI.LBL_POINT_4,
            UI.LBL_POINT_5,
            UI.LBL_POINT_6
        };
        UI[] array3 = new UI[6]
        {
            UI.LBL_DESC_1,
            UI.LBL_DESC_2,
            UI.LBL_DESC_3,
            UI.LBL_DESC_4,
            UI.LBL_DESC_5,
            UI.LBL_DESC_6
        };
        if (0 <= index && 5 >= index)
        {
            uI  = array[index];
            uI2 = array2[index];
            uI3 = array3[index];
        }
        AbilityDataTable.AbilityData abilityData = Singleton <AbilityDataTable> .I.GetAbilityData(ability.id, ability.ap);

        if (abilityData == null)
        {
            abilityData = Singleton <AbilityDataTable> .I.GetMinimumAbilityData(ability.id);
        }
        SetLabelText((Enum)uI, ability.GetName());
        SetLabelText((Enum)uI2, ability.GetAP());
        SetLabelText((Enum)uI3, abilityData.description);
    }
 public void SetAbilityDetailText(EquipItemAbility ability)
 {
     SetAbilityDetailText(ability.GetName(), ability.GetAP(), ability.GetDescription());
 }
Esempio n. 5
0
    public override void UpdateUI()
    {
        SetActive((Enum)UI.OBJ_FRAME_BG, IsShowFrameBG());
        detailBase = SetPrefab(GetCtrl(UI.OBJ_DETAIL_ROOT), "ItemDetailEquipBase", true);
        SetFontStyle(detailBase, UI.STR_TITLE_ITEM_INFO, 2);
        SetFontStyle(detailBase, UI.STR_TITLE_STATUS, 2);
        SetFontStyle(detailBase, UI.STR_TITLE_SKILL_SLOT, 2);
        SetFontStyle(detailBase, UI.STR_TITLE_ABILITY, 2);
        SetFontStyle(detailBase, UI.STR_TITLE_SELL, 2);
        SetFontStyle(detailBase, UI.STR_TITLE_ATK, 2);
        SetFontStyle(detailBase, UI.STR_TITLE_ELEM_ATK, 2);
        SetFontStyle(detailBase, UI.STR_TITLE_DEF, 2);
        SetFontStyle(detailBase, UI.STR_TITLE_ELEM_DEF, 2);
        SetFontStyle(detailBase, UI.STR_TITLE_HP, 2);
        EquipItemInfo equip = detailItemData as EquipItemInfo;

        SetActive((Enum)UI.BTN_CHANGE, localEquipSetData != null && CanSmithSection(callSection));
        SetActive((Enum)UI.BTN_CREATE, CanSmithSection(callSection));
        SetActive((Enum)UI.BTN_GROW, CanSmithSection(callSection));
        SetActive((Enum)UI.BTN_GROW_OFF, CanSmithSection(callSection));
        SetActive((Enum)UI.BTN_ABILITY, CanSmithSection(callSection));
        SetActive((Enum)UI.BTN_ABILITY_OFF, CanSmithSection(callSection));
        SetActive((Enum)UI.BTN_SELL, IsEnableDispSellButton(callSection) && MonoBehaviourSingleton <ItemExchangeManager> .I.IsExchangeScene());
        if (equip != null)
        {
            int exceed = equip.exceed;
            SetActive((Enum)UI.BTN_EXCEED, equip.tableData.exceedID != 0);
            SetActive((Enum)UI.SPR_COUNT_0_ON, exceed > 0);
            SetActive((Enum)UI.SPR_COUNT_1_ON, exceed > 1);
            SetActive((Enum)UI.SPR_COUNT_2_ON, exceed > 2);
            SetActive((Enum)UI.SPR_COUNT_3_ON, exceed > 3);
            EquipParam(equip);
            SetSkillIconButton(detailBase, UI.OBJ_SKILL_BUTTON_ROOT, "SkillIconButton", equip.tableData, equipAttachSkill, "SKILL_ICON_BUTTON", 0);
            SetSprite((Enum)UI.SPR_SP_ATTACK_TYPE, (!equip.tableData.IsWeapon()) ? string.Empty : equip.tableData.spAttackType.GetBigFrameSpriteName());
            AbilityItemInfo abilityItem = equip.GetAbilityItem();
            bool            flag        = abilityItem != null;
            if ((equip.ability != null && equip.ability.Length > 0) || flag)
            {
                bool   empty_ability      = true;
                int    validAbilityLength = equip.GetValidAbilityLength();
                string allAbilityName     = string.Empty;
                string allAp          = string.Empty;
                string allAbilityDesc = string.Empty;
                SetTable(detailBase, UI.TBL_ABILITY, "ItemDetailEquipAbilityItem", equip.ability.Length + (flag ? 1 : 0), false, delegate(int i, Transform t, bool is_recycle)
                {
                    //IL_0302: Unknown result type (might be due to invalid IL or missing references)
                    //IL_0312: Expected O, but got Unknown
                    if (i < equip.ability.Length)
                    {
                        EquipItemAbility equipItemAbility2 = equip.ability[i];
                        if (equipItemAbility2.id == 0)
                        {
                            SetActive(t, false);
                        }
                        else
                        {
                            SetActive(t, true);
                            if (equipItemAbility2.IsNeedUpdate())
                            {
                                SetActive(t, UI.OBJ_ABILITY, false);
                                SetActive(t, UI.OBJ_FIXEDABILITY, false);
                                SetActive(t, UI.OBJ_NEED_UPDATE_ABILITY, true);
                                SetLabelText(t, UI.LBL_NEED_UPDATE_ABILITY, StringTable.Get(STRING_CATEGORY.ABILITY, 0u));
                                SetButtonEnabled(t, false);
                            }
                            else if (!equipItemAbility2.IsActiveAbility())
                            {
                                SetActive(t, UI.OBJ_ABILITY, false);
                                SetActive(t, UI.OBJ_FIXEDABILITY, false);
                                SetActive(t, UI.OBJ_NEED_UPDATE_ABILITY, true);
                                SetLabelText(t, UI.LBL_NEED_UPDATE_ABILITY, StringTable.Get(STRING_CATEGORY.ABILITY, 1u));
                                SetButtonEnabled(t, false);
                            }
                            else if (equip.IsFixedAbility(i))
                            {
                                SetActive(t, UI.OBJ_ABILITY, false);
                                SetActive(t, UI.OBJ_FIXEDABILITY, true);
                                SetActive(t, UI.OBJ_NEED_UPDATE_ABILITY, false);
                                SetLabelText(t, UI.LBL_FIXEDABILITY, Utility.TrimText(equipItemAbility2.GetName(), FindCtrl(t, UI.LBL_FIXEDABILITY).GetComponent <UILabel>()));
                                SetLabelText(t, UI.LBL_FIXEDABILITY_NUM, equipItemAbility2.GetAP());
                            }
                            else
                            {
                                empty_ability = false;
                                SetActive(t, UI.OBJ_NEED_UPDATE_ABILITY, false);
                                SetLabelText(t, UI.LBL_ABILITY, Utility.TrimText(equipItemAbility2.GetName(), FindCtrl(t, UI.LBL_ABILITY).GetComponent <UILabel>()));
                                SetLabelText(t, UI.LBL_ABILITY_NUM, equipItemAbility2.GetAP());
                            }
                            SetAbilityItemEvent(t, i, touchAndReleaseButtons);
                            allAbilityName += equipItemAbility2.GetName();
                            allAp          += equipItemAbility2.GetAP();
                            allAbilityDesc += equipItemAbility2.GetDescription();
                        }
                    }
                    else
                    {
                        SetActive(t, UI.OBJ_ABILITY, false);
                        SetActive(t, UI.OBJ_ABILITY_ITEM, true);
                        SetLabelText(t, UI.LBL_ABILITY_ITEM, abilityItem.GetName());
                        SetTouchAndRelease(t.GetComponentInChildren <UIButton>().get_transform(), "ABILITY_ITEM_DATA_POPUP", "RELEASE_ABILITY", t);
                        allAbilityName += abilityItem.GetName();
                        allAbilityDesc += abilityItem.GetDescription();
                    }
                });
                PreCacheAbilityDetail(allAbilityName, allAp, allAbilityDesc);
                if (empty_ability)
                {
                    SetActive(detailBase, UI.STR_NON_ABILITY, 0 == validAbilityLength);
                    SetActive((Enum)UI.BTN_ABILITY, false);
                    SetActive((Enum)UI.BTN_ABILITY_OFF, CanSmithSection(callSection));
                }
                else
                {
                    SetActive(detailBase, UI.STR_NON_ABILITY, false);
                    SetActive((Enum)UI.BTN_ABILITY_OFF, false);
                }
                if (equip.tableData.IsShadow())
                {
                    SetActive(detailBase, UI.STR_NON_ABILITY, false);
                    SetActive((Enum)UI.BTN_ABILITY, CanSmithSection(callSection));
                    SetActive((Enum)UI.BTN_ABILITY_OFF, CanSmithSection(callSection));
                }
            }
            else
            {
                SetActive(detailBase, UI.STR_NON_ABILITY, true);
                SetActive((Enum)UI.BTN_ABILITY, false);
                SetActive((Enum)UI.BTN_ABILITY_OFF, CanSmithSection(callSection));
            }
        }
        else
        {
            SetActive((Enum)UI.SPR_COUNT_0_ON, false);
            SetActive((Enum)UI.SPR_COUNT_1_ON, false);
            SetActive((Enum)UI.SPR_COUNT_2_ON, false);
            SetActive((Enum)UI.SPR_COUNT_3_ON, false);
            EquipItemTable.EquipItemData table = detailItemData as EquipItemTable.EquipItemData;
            SetActive((Enum)UI.BTN_EXCEED, table.exceedID != 0);
            EquipTableParam(table);
            SetSkillIconButton(detailBase, UI.OBJ_SKILL_BUTTON_ROOT, "SkillIconButton", table, equipAttachSkill, "SKILL_ICON_BUTTON", 0);
            SetSprite((Enum)UI.SPR_SP_ATTACK_TYPE, (!table.IsWeapon()) ? string.Empty : table.spAttackType.GetBigFrameSpriteName());
            if (table.fixedAbility.Length > 0)
            {
                string allAbilityName2 = string.Empty;
                string allAp2          = string.Empty;
                string allAbilityDesc2 = string.Empty;
                SetTable(detailBase, UI.TBL_ABILITY, "ItemDetailEquipAbilityItem", table.fixedAbility.Length, false, delegate(int i, Transform t, bool is_recycle)
                {
                    EquipItemAbility equipItemAbility = new EquipItemAbility((uint)table.fixedAbility[i].id, table.fixedAbility[i].pt);
                    SetActive(t, true);
                    SetActive(t, UI.OBJ_ABILITY, false);
                    SetActive(t, UI.OBJ_FIXEDABILITY, true);
                    SetLabelText(t, UI.LBL_FIXEDABILITY, Utility.TrimText(equipItemAbility.GetName(), FindCtrl(t, UI.LBL_FIXEDABILITY).GetComponent <UILabel>()));
                    SetLabelText(t, UI.LBL_FIXEDABILITY_NUM, equipItemAbility.GetAP());
                    SetAbilityItemEvent(t, i, touchAndReleaseButtons);
                    allAbilityName2 += equipItemAbility.GetName();
                    allAp2          += equipItemAbility.GetAP();
                    allAbilityDesc2 += equipItemAbility.GetDescription();
                });
                PreCacheAbilityDetail(allAbilityName2, allAp2, allAbilityDesc2);
                SetActive(detailBase, UI.STR_NON_ABILITY, false);
            }
            else
            {
                SetActive(detailBase, UI.STR_NON_ABILITY, true);
            }
        }
    }
    protected override void EquipTableParam()
    {
        int           exceed    = 0;
        EquipItemInfo equipData = GetEquipData();

        if (equipData != null)
        {
            exceed = equipData.exceed;
        }
        EquipItemTable.EquipItemData table_data = GetEquipTableData();
        if (table_data != null)
        {
            EquipItemExceedParamTable.EquipItemExceedParamAll equipItemExceedParamAll = table_data.GetExceedParam((uint)exceed);
            if (equipItemExceedParamAll == null)
            {
                equipItemExceedParamAll = new EquipItemExceedParamTable.EquipItemExceedParamAll();
            }
            SetLabelText((Enum)UI.LBL_NAME, table_data.name);
            SetLabelText((Enum)UI.LBL_LV_NOW, "1");
            SetLabelText((Enum)UI.LBL_LV_MAX, table_data.maxLv.ToString());
            int num     = (int)table_data.baseAtk + (int)equipItemExceedParamAll.atk;
            int elemAtk = equipItemExceedParamAll.GetElemAtk(table_data.atkElement);
            SetElementSprite((Enum)UI.SPR_ELEM, equipItemExceedParamAll.GetElemAtkType(table_data.atkElement));
            SetLabelText((Enum)UI.LBL_ATK, num.ToString());
            SetLabelText((Enum)UI.LBL_ELEM, elemAtk.ToString());
            int num2 = (int)table_data.baseDef + (int)equipItemExceedParamAll.def;
            SetLabelText((Enum)UI.LBL_DEF, num2.ToString());
            int elemDef = equipItemExceedParamAll.GetElemDef(table_data.defElement);
            SetDefElementSprite((Enum)UI.SPR_ELEM_DEF, equipItemExceedParamAll.GetElemDefType(table_data.defElement));
            SetLabelText((Enum)UI.LBL_ELEM_DEF, elemDef.ToString());
            int num3 = (int)table_data.baseHp + (int)equipItemExceedParamAll.hp;
            SetLabelText((Enum)UI.LBL_HP, num3.ToString());
            SetActive((Enum)UI.SPR_IS_EVOLVE, table_data.IsEvolve());
            SetEquipmentTypeIcon((Enum)UI.SPR_TYPE_ICON, (Enum)UI.SPR_TYPE_ICON_BG, (Enum)UI.SPR_TYPE_ICON_RARITY, table_data);
            SetLabelText((Enum)UI.LBL_SELL, table_data.sale.ToString());
            if (smithType != SmithType.EVOLVE)
            {
                SetSkillIconButton(UI.OBJ_SKILL_BUTTON_ROOT, "SkillIconButton", table_data, GetSkillSlotData(table_data, 0), null, 0);
                if (table_data.fixedAbility.Length > 0)
                {
                    string allAbilityName = string.Empty;
                    string allAp          = string.Empty;
                    string allAbilityDesc = string.Empty;
                    SetTable(UI.TBL_ABILITY, "ItemDetailEquipAbilityItem", table_data.fixedAbility.Length, false, delegate(int i, Transform t, bool is_recycle)
                    {
                        EquipItemAbility equipItemAbility = new EquipItemAbility((uint)table_data.fixedAbility[i].id, table_data.fixedAbility[i].pt);
                        SetActive(t, true);
                        SetActive(t, UI.OBJ_FIXEDABILITY, true);
                        SetActive(t, UI.OBJ_ABILITY, false);
                        SetLabelText(t, UI.LBL_FIXEDABILITY, equipItemAbility.GetName());
                        SetLabelText(t, UI.LBL_FIXEDABILITY_NUM, equipItemAbility.GetAP());
                        SetAbilityItemEvent(t, i, touchAndReleaseButtons);
                        allAbilityName += equipItemAbility.GetName();
                        allAp          += equipItemAbility.GetAP();
                        allAbilityDesc += equipItemAbility.GetDescription();
                    });
                    SetActive((Enum)UI.STR_NON_ABILITY, false);
                    PreCacheAbilityDetail(allAbilityName, allAp, allAbilityDesc);
                }
                else
                {
                    SetActive((Enum)UI.STR_NON_ABILITY, true);
                }
            }
        }
    }
 protected override void ResultEquipInfo()
 {
     if (resultData.itemData != null)
     {
         EquipItemInfo item = resultData.itemData as EquipItemInfo;
         EquipItemTable.EquipItemData tableData = item.tableData;
         bool flag = tableData.IsVisual();
         SetActive(detailBase, UI.BTN_SELL, false);
         SetActive(detailBase, UI.BTN_GROW, false);
         SetActive(detailBase, UI.BTN_GRAY, false);
         SetActive(detailBase, UI.OBJ_FAVORITE_ROOT, false);
         SetActive(detailBase, UI.SPR_IS_EVOLVE, item.tableData.IsEvolve());
         SetActive(detailBase, UI.STR_LV, !flag);
         SetActive(detailBase, UI.STR_ONLY_VISUAL, flag);
         SetupBottomButton();
         SetLabelText(detailBase, UI.LBL_NAME, tableData.name);
         SetLabelText(detailBase, UI.LBL_LV_MAX, tableData.maxLv.ToString());
         SetSprite(detailBase, UI.SPR_SP_ATTACK_TYPE, (!tableData.IsWeapon()) ? string.Empty : tableData.spAttackType.GetBigFrameSpriteName());
         if (smithType == SmithType.GROW)
         {
             string text = base.sectionData.GetText("STATUS_DIFF_FORMAT");
             SetLabelCompareParam(detailBase, UI.LBL_LV_NOW, item.level, resultData.beforeLevel, -1);
             SetLabelDiffParam(detailBase, UI.LBL_AFTER_ATK, item.atk, UI.LBL_DIFF_ATK, resultData.beforeAtk, UI.LBL_ATK, text);
             SetLabelDiffParam(detailBase, UI.LBL_AFTER_DEF, item.def, UI.LBL_DIFF_DEF, resultData.beforeDef, UI.LBL_DEF, text);
             SetLabelDiffParam(detailBase, UI.LBL_AFTER_HP, item.hp, UI.LBL_DIFF_HP, resultData.beforeHp, UI.LBL_HP, text);
             SetLabelDiffParam(detailBase, UI.LBL_AFTER_ELEM, item.elemAtk, UI.LBL_DIFF_ELEM, resultData.beforeElemAtk, UI.LBL_ELEM, text);
             SetDiffElementSprite(detailBase, item.GetElemAtkType(), resultData.beforeElemAtk, item.elemAtk, UI.SPR_ELEM, UI.SPR_DIFF_ELEM, true);
             int num  = item.elemDef;
             int num2 = resultData.beforeElemDef;
             if (item.tableData.isFormer)
             {
                 num  = Mathf.FloorToInt((float)num * 0.1f);
                 num2 = Mathf.FloorToInt((float)num2 * 0.1f);
             }
             SetLabelDiffParam(detailBase, UI.LBL_AFTER_ELEM_DEF, num, UI.LBL_DIFF_ELEM_DEF, num2, UI.LBL_ELEM_DEF, text);
             SetDiffElementSprite(detailBase, item.GetElemDefType(), resultData.beforeElemDef, item.elemDef, UI.SPR_ELEM_DEF, UI.SPR_DIFF_ELEM_DEF, false);
         }
         else
         {
             SetLabelText(detailBase, UI.LBL_LV_NOW, item.level.ToString());
             SetLabelText(detailBase, UI.LBL_ATK, item.atk.ToString());
             SetLabelText(detailBase, UI.LBL_DEF, item.def.ToString());
             SetLabelText(detailBase, UI.LBL_HP, item.hp.ToString());
             SetLabelText(detailBase, UI.LBL_ELEM, item.elemAtk.ToString());
             SetElementSprite(detailBase, UI.SPR_ELEM, item.GetElemAtkType());
             int num3 = item.elemDef;
             if (item.tableData.isFormer)
             {
                 num3 = Mathf.FloorToInt((float)num3 * 0.1f);
             }
             SetLabelText(detailBase, UI.LBL_ELEM_DEF, num3.ToString());
             SetDefElementSprite(detailBase, UI.SPR_ELEM_DEF, item.GetElemDefType());
         }
         SetSkillIconButton(detailBase, UI.OBJ_SKILL_BUTTON_ROOT, "SkillIconButton", item.tableData, GetSkillSlotData(item), "SKILL_ICON_BUTTON", 0);
         SetLabelText(detailBase, UI.LBL_SELL, tableData.sale.ToString());
         SetEquipmentTypeIcon(detailBase, UI.SPR_TYPE_ICON, UI.SPR_TYPE_ICON_BG, UI.SPR_TYPE_ICON_RARITY, item.tableData);
         AbilityItemInfo abilityItem = item.GetAbilityItem();
         bool            flag2       = abilityItem != null;
         if ((item.ability != null && item.ability.Length > 0) || flag2)
         {
             bool   empty_ability  = true;
             string allAbilityName = string.Empty;
             string allAp          = string.Empty;
             string allAbilityDesc = string.Empty;
             SetTable(detailBase, UI.TBL_ABILITY, "ItemDetailEquipAbilityItem", item.ability.Length + (flag2 ? 1 : 0), false, delegate(int i, Transform t, bool is_recycle)
             {
                 //IL_0211: Unknown result type (might be due to invalid IL or missing references)
                 //IL_0221: Expected O, but got Unknown
                 if (i < item.ability.Length)
                 {
                     EquipItemAbility equipItemAbility = item.ability[i];
                     if (equipItemAbility.id == 0)
                     {
                         SetActive(t, false);
                     }
                     else
                     {
                         empty_ability = false;
                         SetActive(t, true);
                         if (equipItemAbility.IsNeedUpdate())
                         {
                             SetActive(t, UI.OBJ_ABILITY, false);
                             SetActive(t, UI.OBJ_FIXEDABILITY, false);
                             SetActive(t, UI.OBJ_NEED_UPDATE_ABILITY, true);
                             SetButtonEnabled(t, false);
                         }
                         else if (item.IsFixedAbility(i))
                         {
                             SetActive(t, UI.OBJ_ABILITY, false);
                             SetActive(t, UI.OBJ_FIXEDABILITY, true);
                             SetLabelText(t, UI.LBL_FIXEDABILITY, equipItemAbility.GetName());
                             SetLabelText(t, UI.LBL_FIXEDABILITY_NUM, equipItemAbility.GetAP());
                         }
                         else
                         {
                             SetLabelText(t, UI.LBL_ABILITY, equipItemAbility.GetName());
                             SetLabelText(t, UI.LBL_ABILITY_NUM, equipItemAbility.GetAP());
                         }
                         SetAbilityItemEvent(t, i, touchAndReleaseButtons);
                         allAbilityName += equipItemAbility.GetName();
                         allAp          += equipItemAbility.GetAP();
                         allAbilityDesc += equipItemAbility.GetDescription();
                     }
                 }
                 else
                 {
                     SetActive(t, UI.OBJ_ABILITY, false);
                     SetActive(t, UI.OBJ_ABILITY_ITEM, true);
                     SetLabelText(t, UI.LBL_ABILITY_ITEM, abilityItem.GetName());
                     SetTouchAndRelease(t.GetComponentInChildren <UIButton>().get_transform(), "ABILITY_ITEM_DATA_POPUP", "RELEASE_ABILITY", t);
                     allAbilityName += abilityItem.GetName();
                     allAbilityDesc += abilityItem.GetDescription();
                 }
             });
             PreCacheAbilityDetail(allAbilityName, allAp, allAbilityDesc);
             if (empty_ability)
             {
                 SetActive(detailBase, UI.STR_NON_ABILITY, true);
             }
             else
             {
                 SetActive(detailBase, UI.STR_NON_ABILITY, false);
             }
         }
         else
         {
             SetActive(detailBase, UI.STR_NON_ABILITY, true);
         }
     }
 }