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); }
private void ToggleAllTarget() { if (_cursorType == CursorGroup.AllEnemy || _cursorType == CursorGroup.AllPlayer) { if (ButtonGroupState.ActiveButton) { ButtonGroupState.SetButtonAnimation(ButtonGroupState.ActiveButton, true); } else { foreach (GONavigationButton button in _targetPanel.AllTargets) { ButtonGroupState.SetButtonAnimation(button, true); } ButtonGroupState.ActiveButton = ButtonGroupState.GetCursorStartSelect(TargetGroupButton); } _cursorType = CursorGroup.Individual; _targetPanel.ActivateButtons(false); } else { ButtonGroupState.SetButtonAnimation(ButtonGroupState.ActiveButton, false); Singleton <PointerManager> .Instance.RemovePointerFromGameObject(ButtonGroupState.ActiveButton); _cursorType = _currentTargetIndex >= HonoluluBattleMain.EnemyStartIndex ? CursorGroup.AllEnemy : CursorGroup.AllPlayer; _targetPanel.ActivateButtons(true); } SetTargetHelp(); DisplayTargetPointer(); }
public static void SetButtonEnable(GameObject go, Boolean isEnable) { go.GetComponent <ButtonGroupState>().enabled = isEnable; go.GetComponent <BoxCollider>().enabled = isEnable; go.GetComponent <UIButton>().enabled = isEnable; go.GetComponent <UIKeyNavigation>().enabled = isEnable; ButtonGroupState.SetButtonAnimation(go, isEnable); }
private void SetCancelButton(Boolean isEnable) { if (isEnable) { this.CancelSubMenu.GetChild(1).GetComponent <UILabel>().color = FF9TextTool.White; ButtonGroupState.SetButtonAnimation(this.CancelSubMenu, true); } else { this.CancelSubMenu.GetChild(1).GetComponent <UILabel>().color = FF9TextTool.Gray; ButtonGroupState.SetButtonAnimation(this.CancelSubMenu, false); } }