Exemple #1
0
    private void DisplayKeyItemDetail(Transform item, ListDataTypeBase data, Int32 index, Boolean isInit)
    {
        FieldKeyItemListData fieldKeyItemListData = (FieldKeyItemListData)data;
        KeyItemDetailHUD     keyItemDetailHud     = new KeyItemDetailHUD(item.gameObject);

        if (isInit)
        {
            DisplayWindowBackground(item.gameObject, null);
        }
        if (fieldKeyItemListData.KeyItemId == FF9FITEM_RARE_NONE)
        {
            keyItemDetailHud.Button.Help.Enable       = false;
            keyItemDetailHud.NewIconSprite.spriteName = String.Empty;
            keyItemDetailHud.NewIconLabelSprite.gameObject.SetActive(false);
            keyItemDetailHud.NameLabel.gameObject.SetActive(false);
        }
        else
        {
            keyItemDetailHud.NameLabel.gameObject.SetActive(true);
            keyItemDetailHud.NameLabel.text = FF9TextTool.ImportantItemName(fieldKeyItemListData.KeyItemId);
            if (ff9item.FF9Item_IsUsedImportant(fieldKeyItemListData.KeyItemId))
            {
                keyItemDetailHud.NewIconSprite.spriteName = String.Empty;
                keyItemDetailHud.NewIconLabelSprite.gameObject.SetActive(false);
            }
            else
            {
                keyItemDetailHud.NewIconSprite.spriteName = "icon_new_exclamation";
                keyItemDetailHud.NewIconLabelSprite.gameObject.SetActive(true);
            }
            keyItemDetailHud.Button.Help.Enable = true;
            keyItemDetailHud.Button.Help.Text   = FF9TextTool.ImportantItemHelpDescription(fieldKeyItemListData.KeyItemId);
        }
    }
Exemple #2
0
    private void DisplayItemDetail(Transform item, ListDataTypeBase data, Int32 index, Boolean isInit)
    {
        FieldItemListData fieldItemListData = (FieldItemListData)data;
        ItemDetailHUD     itemDetailHud     = new ItemDetailHUD(item.gameObject);

        if (isInit)
        {
            UIEventListener uiEventListener = UIEventListener.Get(itemDetailHud.ManualButton.gameObject);
            uiEventListener.Select += itemDetailHud.Self.GetComponent <ScrollItemKeyNavigation>().OnOtherObjectSelect;
            DisplayWindowBackground(item.gameObject, null);
        }
        if (ButtonGroupState.ActiveGroup == ItemArrangeGroupButton)
        {
            if (_currentItemIndex == index && !_switchingItem)
            {
                if (isInit)
                {
                    ButtonGroupState.HoldActiveStateOnGroup(item.gameObject, ItemGroupButton);
                }
                ButtonGroupState.SetButtonAnimation(item.gameObject, false);
                ButtonGroupState.SetOutsideLimitRectBehavior(PointerManager.LimitRectBehavior.Hide, ItemGroupButton);
            }
            else
            {
                ButtonGroupState.SetButtonAnimation(item.gameObject, true);
            }
        }
        FF9UIDataTool.DisplayItem(fieldItemListData.ItemId, itemDetailHud.IconSprite, itemDetailHud.NameLabel, fieldItemListData.Enable);
        itemDetailHud.NumberLabel.text         = fieldItemListData.ItemCount.ToString();
        itemDetailHud.NumberLabel.color        = !fieldItemListData.Enable ? FF9TextTool.Gray : FF9TextTool.White;
        itemDetailHud.Button.Help.Enable       = true;
        itemDetailHud.Button.Help.Text         = FF9TextTool.ItemHelpDescription(fieldItemListData.ItemId);
        itemDetailHud.ManualButton.Help.Enable = true;
        itemDetailHud.ManualButton.Help.Text   = FF9TextTool.ItemHelpDescription(fieldItemListData.ItemId);
    }