示例#1
0
 private void Update()
 {
     if (mKeyController == null || !base.enabled || animating)
     {
         return;
     }
     if (mKeyController.IsLeftDown())
     {
         ChangeFocusButton(mButton_Negative);
     }
     else if (mKeyController.IsRightDown())
     {
         ChangeFocusButton(mButton_Positive);
     }
     else if (mKeyController.IsMaruDown())
     {
         if (mButtonCurrentFocus.Equals(mButton_Negative))
         {
             Back();
         }
         else if (mButtonCurrentFocus.Equals(mButton_Positive))
         {
             Forward();
         }
     }
     else if (mKeyController.IsBatuDown())
     {
         Back();
     }
 }
 private void Update()
 {
     if (mKeyController != null && base.mState == ListState.Waiting)
     {
         if (mKeyController.IsUpDown())
         {
             PrevFocus();
         }
         else if (mKeyController.IsDownDown())
         {
             NextFocus();
         }
         else if (mKeyController.IsLeftDown())
         {
             PrevPageOrHeadFocus();
         }
         else if (mKeyController.IsRightDown())
         {
             NextPageOrTailFocus();
         }
         else if (mKeyController.IsBatuDown())
         {
             Back();
         }
         else if (mKeyController.IsMaruDown())
         {
             Select();
         }
     }
 }
 private void Update()
 {
     if (mKeyController != null)
     {
         if (mKeyController.keyState[14].down)
         {
             ChangeFocusButton(mButton_ShipAlbum);
         }
         else if (mKeyController.keyState[10].down)
         {
             ChangeFocusButton(mButton_SlotItemAlbum);
         }
         else if (mKeyController.keyState[1].down)
         {
             OnSelectCurrentFocus();
         }
         else if (mKeyController.IsRDown())
         {
             SingletonMonoBehaviour <PortObjectManager> .Instance.BackToStrategy();
         }
         else if (mKeyController.IsBatuDown())
         {
             SingletonMonoBehaviour <PortObjectManager> .Instance.BackToActiveScene();
         }
     }
 }
示例#4
0
 private void Update()
 {
     if (mKeyController != null && mStateManager != null && mStateManager.CurrentState == State.CategoryTabSelect)
     {
         if (mKeyController.IsRightDown())
         {
             tabManager.NextTab();
         }
         else if (mKeyController.IsLeftDown())
         {
             tabManager.PrevTab();
         }
         else if (mKeyController.IsMaruDown())
         {
             OnDesideTabListener();
         }
         else if (mKeyController.IsBatuDown())
         {
             RequestMoveToPort();
         }
         else if (mKeyController.IsRSLeftDown())
         {
             RequestMoveToInterior();
         }
     }
 }
 protected override void OnUpdate()
 {
     if (mKeyController != null && base.mState == ListState.Waiting && isShown)
     {
         if (mKeyController.IsShikakuDown())
         {
             SwitchLockItem();
         }
         else if (mKeyController.IsDownDown())
         {
             NextFocus();
         }
         else if (mKeyController.IsUpDown())
         {
             PrevFocus();
         }
         else if (mKeyController.IsLeftDown())
         {
             PrevPageOrHeadFocus();
         }
         else if (mKeyController.IsRightDown())
         {
             NextPageOrTailFocus();
         }
         else if (mKeyController.IsBatuDown())
         {
             Back();
         }
         else if (mKeyController.IsMaruDown())
         {
             Select();
         }
     }
 }
 private void Update()
 {
     if (Input.GetKeyDown(KeyCode.P))
     {
         PlaySlotInAnimation();
     }
     if (mKeyController != null && base.mState == ListState.Waiting)
     {
         if (mKeyController.IsUpDown())
         {
             PrevFocus();
         }
         else if (mKeyController.IsDownDown())
         {
             NextFocus();
         }
         else if (mKeyController.IsMaruDown())
         {
             mKeyController.ClearKeyAll();
             mKeyController.firstUpdate = true;
             Select();
         }
         else if (mKeyController.IsBatuDown())
         {
             SingletonMonoBehaviour <PortObjectManager> .Instance.BackToActiveScene();
         }
     }
 }
 private void Update()
 {
     if (mKeyController == null || !base.enabled || !isShown)
     {
         return;
     }
     if (mKeyController.IsUpDown())
     {
         if (mCurrentFocusTargetShipSlot == null)
         {
             ChangeFocusSlot(mUIRemodeModernzationTargetShip_TargetShips[mUIRemodeModernzationTargetShip_TargetShips.Length - 1]);
             mButton_Start.SetState(UIButtonColor.State.Normal, immediate: true);
             return;
         }
         int num  = Array.IndexOf(mUIRemodeModernzationTargetShip_TargetShips, mCurrentFocusTargetShipSlot);
         int num2 = num - 1;
         if (0 <= num2)
         {
             ChangeFocusSlot(mUIRemodeModernzationTargetShip_TargetShips[num2]);
         }
     }
     else if (mKeyController.IsDownDown() || _CursorDown != 0)
     {
         do
         {
             if (!(mCurrentFocusTargetShipSlot == null))
             {
                 int num3 = Array.IndexOf(mUIRemodeModernzationTargetShip_TargetShips, mCurrentFocusTargetShipSlot);
                 int num4 = num3 + 1;
                 if (num4 < mUIRemodeModernzationTargetShip_TargetShips.Length)
                 {
                     ChangeFocusSlot(mUIRemodeModernzationTargetShip_TargetShips[num4], (_CursorDown != 0) ? true : false);
                 }
                 else if (num4 == mUIRemodeModernzationTargetShip_TargetShips.Length && CanModernize())
                 {
                     ChangeFocusSlot(null, (_CursorDown != 0) ? true : false);
                     mButton_Start.SetState(UIButtonColor.State.Hover, immediate: true);
                 }
             }
         }while (--_CursorDown > 0);
         _CursorDown = 0;
     }
     else if (mKeyController.IsMaruDown())
     {
         if (mCurrentFocusTargetShipSlot != null)
         {
             Forward4Select();
         }
         else
         {
             Forward4Confirm();
         }
     }
     else if (mKeyController.IsBatuDown())
     {
         Back();
     }
 }
示例#8
0
 private void TopModeRun()
 {
     if (key.IsChangeIndex)
     {
         if (key.prevIndex == 4 && key.IsDownDown())
         {
             key.Index = 4;
             return;
         }
         if (key.prevIndex == 1 && key.IsUpDown())
         {
             key.Index = 1;
             return;
         }
         BannerFocusAnim(isEnable: false);
         FocusBanner = ShipStates[key.Index];
         BannerFocusAnim(isEnable: true);
         SoundUtils.PlaySE(SEFIleInfos.CommonCursolMove, null);
     }
     else if (key.IsMaruDown())
     {
         GotoOrganize();
         SoundUtils.PlaySE(SEFIleInfos.CommonEnter1, null);
     }
     else if (key.IsShikakuDown())
     {
         GotoSupplyConfirm();
     }
     else if (key.IsSankakuDown() && FocusBanner.ShipModel != null)
     {
         GotoRepairConfirm();
     }
     else if (key.IsBatuDown())
     {
         BackToSailSelect();
     }
     else if (key.IsRSRightDown())
     {
         ChangeDeck(isNext: true);
     }
     else if (key.IsRSLeftDown())
     {
         ChangeDeck(isNext: false);
     }
 }
 private void OnUpdateSlotItemDestroyConfirm()
 {
     if (KeyController.IsLeftDown())
     {
         RequestBackTransitionFromSlotItemDestroyConfirm();
     }
     else if (KeyController.IsMaruDown())
     {
         CommonPopupDialog.Instance.StartPopup("廃棄は □ボタンで行います");
     }
     else if (KeyController.IsBatuDown())
     {
         RequestBackTransitionFromShipDestroyConfirm();
     }
     else if (KeyController.IsShikakuDown() && mStateManager.CurrentState == State.SlotItemDestroyConfirm)
     {
         StartHaiki(mArsenalManager);
     }
 }
示例#10
0
 private void Update()
 {
     if (key != null)
     {
         key.Update();
         if (key.IsMaruDown() || key.IsBatuDown() || key.IsShikakuDown() || key.IsSankakuDown())
         {
             NextPage();
         }
     }
 }
示例#11
0
 private void Update()
 {
     if (mKeyController != null && base.enabled && isShown)
     {
         if (mKeyController.IsMaruDown())
         {
             Forward();
         }
         else if (mKeyController.IsBatuDown())
         {
             Back();
         }
     }
 }
示例#12
0
 protected override bool Run()
 {
     if (isEnd)
     {
         if (changeState == "list")
         {
             OrganizeTaskManager.ReqPhase(OrganizeTaskManager.OrganizePhase.List);
         }
         else if (changeState == "top")
         {
             OrganizeTaskManager.ReqPhase(OrganizeTaskManager.OrganizePhase.Phase_ST);
         }
         return(false);
     }
     if (KeyController.IsLeftDown())
     {
         if (!ship.IsLocked())
         {
             detailManager.buttons.LockSwitch.MoveLockBtn();
         }
     }
     else if (KeyController.IsRightDown())
     {
         if (ship.IsLocked())
         {
             detailManager.buttons.LockSwitch.MoveLockBtn();
         }
     }
     else if (KeyController.IsShikakuDown())
     {
         detailManager.buttons.LockSwitch.MoveLockBtn();
     }
     else if (KeyController.IsMaruDown())
     {
         if (!isEnd)
         {
             ChangeButtonEL(null);
         }
     }
     else if (KeyController.IsBatuDown())
     {
         BackDataEL(null);
     }
     if (KeyController.IsRDown())
     {
         SingletonMonoBehaviour <PortObjectManager> .Instance.BackToStrategy();
     }
     return(true);
 }
 protected void Update()
 {
     if (!controllable || keyController == null)
     {
         return;
     }
     if ((keyController.keyState[12].holdTime > 1.5f || keyController.keyState[8].holdTime > 1.5f) && keyController.KeyInputInterval == defaultIntervalTime)
     {
         keyController.KeyInputInterval /= 3f;
     }
     else
     {
         keyController.KeyInputInterval = defaultIntervalTime;
     }
     if (keyController.IsUpDown())
     {
         if (!swipeBounceBackAnimating)
         {
             MovePrev();
         }
     }
     else if (keyController.IsDownDown())
     {
         if (!swipeBounceBackAnimating)
         {
             MoveNext();
         }
     }
     else if (keyController.IsMaruDown())
     {
         if ((UnityEngine.Object) this.currentChild != (UnityEngine.Object)null)
         {
             View currentChild = this.currentChild;
             currentChild.OnClick();
         }
     }
     else if (keyController.IsBatuDown())
     {
         handler.OnCancel();
         BounceBack();
         View viewByModelIndex = GetViewByModelIndex(rollCount);
         viewByModelIndex.DoSelect();
     }
     else if (keyController.IsSankakuDown())
     {
         OnPressSankaku();
     }
 }
示例#14
0
 private void InheritTypeSelectRun()
 {
     if (key.IsUpDown())
     {
         TypeSelectBtnMng.movePrevButton();
     }
     else if (key.IsDownDown())
     {
         TypeSelectBtnMng.moveNextButton();
     }
     else if (key.IsMaruDown())
     {
         TypeSelectBtnMng.Decide();
     }
     else if (key.IsBatuDown())
     {
         ModeProc.ChangeMode(1);
     }
 }
示例#15
0
 private void Update()
 {
     if (keyController == null || !base.enabled || !isShown)
     {
         return;
     }
     if (validShip && keyController.IsUpDown())
     {
         int num  = Array.IndexOf(slots, currentFocusItem);
         int num2 = num - 1;
         if (0 <= num2)
         {
             Debug.Log("PrevIndex::" + num2);
             ChangeFocusItem(slots[num2]);
         }
     }
     else if (validShip && keyController.IsDownDown())
     {
         int num3 = Array.IndexOf(slots, currentFocusItem);
         int num4 = num3 + 1;
         int num5 = (ship.Level >= 30) ? 1 : 0;
         if (num4 < ship.SlotitemList.Count + num5)
         {
             Debug.Log("NextIndex::" + num4);
             ChangeFocusItem(slots[num4]);
         }
     }
     else if (validShip && keyController.IsMaruDown())
     {
         forward();
     }
     else if (keyController.IsBatuDown())
     {
         back();
     }
     else if (validUnsetAll && keyController.IsShikakuDown())
     {
         UnsetAll();
         SoundUtils.PlayOneShotSE(SEFIleInfos.SE_009);
     }
 }
 protected override bool Run()
 {
     if (isEnd)
     {
         if (changeState == "top")
         {
             OrganizeTaskManager.Instance.GetTopTask()._state2 = TaskOrganizeTop.OrganizeState.Top;
             OrganizeTaskManager.ReqPhase(OrganizeTaskManager.OrganizePhase.Phase_ST);
         }
         else if (changeState == "list")
         {
             OrganizeTaskManager.Instance.GetTopTask()._state2 = TaskOrganizeTop.OrganizeState.List;
             OrganizeTaskManager.ReqPhase(OrganizeTaskManager.OrganizePhase.List);
         }
         return(false);
     }
     if (KeyController.IsLeftDown())
     {
         detailManager.buttons.UpdateButton(isLeft: true);
     }
     else if (KeyController.IsRightDown())
     {
         detailManager.buttons.UpdateButton(isLeft: false);
     }
     else if (KeyController.IsMaruDown())
     {
         detailManager.buttons.Decide();
     }
     else if (KeyController.IsBatuDown())
     {
         BackMaskEL(null);
     }
     if (KeyController.IsRDown())
     {
         SingletonMonoBehaviour <PortObjectManager> .Instance.BackToStrategy();
     }
     return(true);
 }
示例#17
0
 private void Update()
 {
     if (!needUpdate)
     {
         return;
     }
     _set_arrow();
     if (!_firstUpdate)
     {
         _firstUpdate = false;
         base.gameObject.transform.localScale = Vector3.one;
     }
     if (ItemSelectController != null)
     {
         ItemSelectController.Update();
     }
     if (ItemSelectController.keyState[8].down)
     {
         Pressed_Button_L(null);
     }
     if (ItemSelectController.keyState[12].down)
     {
         Pressed_Button_R(null);
     }
     if (ItemSelectController.IsRDown())
     {
         _Xpressed  = true;
         needUpdate = false;
         if (_isScene)
         {
             GoToStrategy();
         }
     }
     else if (ItemSelectController.IsBatuDown())
     {
         SingletonMonoBehaviour <PortObjectManager> .Instance.BackToActiveScene();
     }
 }
示例#18
0
 protected bool StateKeyControl_Banner()
 {
     if (_isDragDrop)
     {
         return(true);
     }
     deckSwitchManager.keyControlEnable = true;
     if (KeyController.IsMaruDown())
     {
         _bannerManager[BannerIndex - 1].DetailEL(null);
         return(true);
     }
     if (KeyController.IsRDown())
     {
         SingletonMonoBehaviour <PortObjectManager> .Instance.BackToStrategy();
     }
     else if (KeyController.IsBatuDown())
     {
         BackToPort();
     }
     else if (KeyController.IsShikakuDown())
     {
         AllUnsetBtnEL();
     }
     else if (KeyController.IsDownDown())
     {
         BannerIndex += 2;
         if (BannerIndex >= 7)
         {
             BannerIndex -= 6;
         }
         SoundUtils.PlaySE(SEFIleInfos.CommonCursolMove);
         UpdateChangeBanner();
     }
     else if (KeyController.IsUpDown())
     {
         BannerIndex -= 2;
         if (BannerIndex <= 0)
         {
             BannerIndex += 6;
         }
         SoundUtils.PlaySE(SEFIleInfos.CommonCursolMove);
         UpdateChangeBanner();
     }
     else if (KeyController.IsLeftDown())
     {
         BannerIndex--;
         SoundUtils.PlaySE(SEFIleInfos.CommonCursolMove);
         if (BannerIndex == 0)
         {
             if (IsTenderBtn() || IsAllUnsetBtn())
             {
                 SystemIndex = ((!IsTenderBtn()) ? 1 : 0);
             }
             else
             {
                 SystemIndex = 2;
             }
             UpdateSystemButtons();
             OrganizeTaskManager.Instance.GetTopTask().setControlState();
         }
         UpdateChangeBanner();
     }
     else if (KeyController.IsRightDown())
     {
         if (BannerIndex >= 6)
         {
             return(true);
         }
         BannerIndex++;
         SoundUtils.PlaySE(SEFIleInfos.CommonCursolMove);
         for (int i = 0; i < 6; i++)
         {
             bool enabled = (BannerIndex - 1 == i) ? true : false;
             _bannerManager[i].UpdateBanner(enabled);
         }
     }
     return(true);
 }
示例#19
0
 private void Update()
 {
     if (keyController == null || !base.enabled || !isShown)
     {
         return;
     }
     if (keyController.IsLeftDown())
     {
         int targetIdx = currentIdx - 1;
         if (currentIdx % 2 == 1)
         {
             changeCurrentItem(targetIdx);
         }
     }
     else if (keyController.IsRightDown())
     {
         int targetIdx2 = currentIdx + 1;
         if (currentIdx % 2 == 0)
         {
             changeCurrentItem(targetIdx2);
         }
     }
     else if (keyController.IsUpDown())
     {
         if (currentIdx == -1)
         {
             int num = Categories.Length - 1;
             while (num > 0 && !changeCurrentItem(num))
             {
                 num--;
             }
         }
         else
         {
             int num2 = currentIdx - 2;
             while (num2 >= 0 && !changeCurrentItem(num2))
             {
                 num2 -= 2;
             }
         }
     }
     else if (keyController.IsDownDown())
     {
         if (currentIdx == -1)
         {
             return;
         }
         bool flag = false;
         for (int i = currentIdx + 2; i < Categories.Length; i += 2)
         {
             if (flag = changeCurrentItem(i))
             {
                 break;
             }
         }
         if (!flag && removeItem.gameObject.activeSelf)
         {
             changeCurrentItem(-1);
         }
     }
     else if (keyController.IsMaruDown())
     {
         if (currentIdx == -1)
         {
             ProcessRemove();
         }
         else
         {
             Forward();
         }
     }
     else if (keyController.IsBatuDown())
     {
         Back();
     }
 }
示例#20
0
        private void HandleKeyController()
        {
            ScreenStatus screenStatus = status;

            if ((screenStatus == ScreenStatus.SELECT_DECK_SHIP || screenStatus == ScreenStatus.SELECT_OTHER_SHIP) && mKeyController.IsBatuDown())
            {
                Back2PortTop();
            }
            if (status != ScreenStatus.MODE_KINDAIKA_KAISHU_ANIMATION && status != ScreenStatus.MODE_KAIZO_ANIMATION && mKeyController.IsRDown())
            {
                SingletonMonoBehaviour <PortObjectManager> .Instance.BackToStrategy();
            }
        }