protected override bool Init() { if (!this.isKeyControlDisable) { this.keyController.IsRun = true; } this.IndexChange = 0; this.swipeWait = false; this.SwipeEvent = this.CommandMenu.get_transform().FindChild("AreaInfoBG").GetComponent <UIDisplaySwipeEventRegion>(); this.SwipeEvent.SetOnSwipeActionJudgeCallBack(new UIDisplaySwipeEventRegion.SwipeJudgeDelegate(this.CheckSwipe)); this.LogicMng = StrategyTopTaskManager.GetLogicManager(); this.CommandMenu.SetActive(true); Util.FindParentToChild(ref this.CommandMenu.Menus, this.CommandMenu.get_transform(), "Menus"); this.sttm = StrategyTaskManager.GetStrategyTop(); this.areaID = SingletonMonoBehaviour <AppInformation> .Instance.CurrentAreaID; this.areaModel = StrategyTopTaskManager.GetLogicManager().Area.get_Item(this.areaID); this.sceneChange = true; this.DeckEnableCheck(); this.CommandMenu.MenuEnter((int)this.currentMenu); this.keyController.Index = (int)this.currentMenu; KeyControlManager.Instance.KeyController = this.keyController; this.isInfoOpenEnable = true; if (SingletonMonoBehaviour <PortObjectManager> .Instance.GetTutorialGuide() != null) { SingletonMonoBehaviour <PortObjectManager> .Instance.GetTutorialGuide().Hide(); } return(true); }
protected override bool Init() { if (!isKeyControlDisable) { keyController.IsRun = true; } IndexChange = 0; swipeWait = false; SwipeEvent = ((Component)CommandMenu.transform.FindChild("AreaInfoBG")).GetComponent <UIDisplaySwipeEventRegion>(); SwipeEvent.SetOnSwipeActionJudgeCallBack(CheckSwipe); LogicMng = StrategyTopTaskManager.GetLogicManager(); CommandMenu.SetActive(isActive: true); Util.FindParentToChild(ref CommandMenu.Menus, CommandMenu.transform, "Menus"); sttm = StrategyTaskManager.GetStrategyTop(); areaID = SingletonMonoBehaviour <AppInformation> .Instance.CurrentAreaID; areaModel = StrategyTopTaskManager.GetLogicManager().Area[areaID]; sceneChange = true; DeckEnableCheck(); CommandMenu.MenuEnter((int)currentMenu); keyController.Index = (int)currentMenu; KeyControlManager.Instance.KeyController = keyController; isInfoOpenEnable = true; if (SingletonMonoBehaviour <PortObjectManager> .Instance.GetTutorialGuide() != null) { SingletonMonoBehaviour <PortObjectManager> .Instance.GetTutorialGuide().Hide(); } return(true); }
public void sailSelectFirstInit() { shipIconManager = StrategyTopTaskManager.Instance.ShipIconManager; infoManager = StrategyTopTaskManager.Instance.GetInfoMng(); areaManager = StrategyTopTaskManager.Instance.GetAreaMng(); TileFocusColor = new Color(25f, 227f, 143f, 1f); sttm = StrategyTaskManager.GetStrategyTop(); DeckSelectController = new KeyControl(0, StrategyTopTaskManager.GetLogicManager().UserInfo.DeckCount - 1); DeckSelectController.setChangeValue(0f, 1f, 0f, -1f); DeckSelectController.KeyInputInterval = 0.2f; DeckSelectController.SilentChangeIndex(SingletonMonoBehaviour <AppInformation> .Instance.CurrentDeckID); Live2DModel = SingletonMonoBehaviour <Live2DModel> .Instance; int currentAreaID = SingletonMonoBehaviour <AppInformation> .Instance.CurrentAreaID; KeyControlManager.Instance.KeyController.Index = currentAreaID; shipIconManager.setShipIcons(StrategyTopTaskManager.GetLogicManager().UserInfo.GetDecks()); SingletonMonoBehaviour <AppInformation> .Instance.prevStrategyDecks = null; FirstPlayVoice = delegate { StrategyTopTaskManager.Instance.UIModel.Character.PlayVoice(SingletonMonoBehaviour <AppInformation> .Instance.CurrentDeck); }; isEnableCharacterEnter = true; prevDeckID = SingletonMonoBehaviour <AppInformation> .Instance.CurrentDeckID; }
protected override void Start() { sttm = StrategyTaskManager.GetStrategyTop(); TaskSailSelect = StrategyTopTaskManager.GetSailSelect(); shipIconManager = StrategyTopTaskManager.Instance.ShipIconManager; }
protected override bool Init() { isAnimationStarted = false; mDisplaySwipeRegion.SetEventCatchCamera(mCamera); mDisplaySwipeRegion.SetOnSwipeActionJudgeCallBack(OnSwipeAction); Transform transform = mStageSelectRoot; Vector3 localPosition = mCamera.transform.localPosition; float x = localPosition.x; Vector3 localPosition2 = mCamera.transform.localPosition; transform.localPosition = new Vector3(x, localPosition2.y); mAreaId = StrategyTopTaskManager.Instance.TileManager.FocusTile.areaID; mStrategyTopTaskManager = StrategyTaskManager.GetStrategyTop(); mIsFinishedAnimation = false; mMapModels = StrategyTopTaskManager.GetLogicManager().SelectArea(mAreaId).Maps; mSortieManager = StrategyTopTaskManager.GetLogicManager().SelectArea(mAreaId); mKeyController = new KeyControl(); mKeyController.isLoopIndex = true; mKeyController.IsRun = false; TweenAlpha.Begin(GameObject.Find("Information Root"), 0.3f, 0f); TweenAlpha.Begin(GameObject.Find("Map_BG"), 0.3f, 0f); GameObject gameObject = StrategyTopTaskManager.Instance.TileManager.Tiles[mAreaId].getSprite().gameObject; mTransform_AnimationTile = Util.Instantiate(gameObject, GameObject.Find("Map Root").gameObject, addParentPos: true).transform; mAnimation_MapObjects = ((Component)mTransform_StageCovers).GetComponent <Animation>(); StartCoroutine(StartSeaAnimationCoroutine()); IEnumerator routine = StartSeaAnimationCoroutine(); StartCoroutine(routine); mTransform_StageCovers.SetActive(isActive: true); ((Component)mTransform_StageCovers.Find("UIStageCovers")).GetComponent <UIWidget>().alpha = 0.001f; SelectedHexAnimation(delegate { StartCoroutine(InititalizeStageCovers(delegate { ((Component)mTransform_StageCovers).GetComponent <Animation>().Play("SortieAnimation"); ShowMaps(mMapModels); })); }); if (mAreaId == 2 || mAreaId == 4 || mAreaId == 5 || mAreaId == 6 || mAreaId == 7 || mAreaId == 10 || mAreaId == 14) { mTexture_sallyBGsky.mainTexture = (Resources.Load("Textures/Strategy/sea2_Sunny_sky") as Texture); mTexture_sallyBGclouds.mainTexture = (Resources.Load("Textures/Strategy/sea2_Sunny_clouds") as Texture); mTexture_sallyBGcloudRefl.mainTexture = (Resources.Load("Textures/Strategy/sea2_Sunny_clouds") as Texture); mTexture_sallyBGcloudRefl.height = 91; mTexture_sallyBGcloudRefl.alpha = 0.25f; mTexture_bgSea.mainTexture = (Resources.Load("Textures/Strategy/sea2_Sunny_sea") as Texture); mTexture_snow.mainTexture = null; } else if (mAreaId == 3 || mAreaId == 13) { mTexture_sallyBGsky.mainTexture = (Resources.Load("Textures/Strategy/sea3_Sunny_sky") as Texture); mTexture_sallyBGclouds.mainTexture = (Resources.Load("Textures/Strategy/sea3_Sunny_clouds") as Texture); mTexture_sallyBGcloudRefl.mainTexture = (Resources.Load("Textures/Strategy/sea3_Sunny_clouds") as Texture); mTexture_sallyBGcloudRefl.height = 90; mTexture_sallyBGcloudRefl.alpha = 0.75f; mTexture_bgSea.mainTexture = (Resources.Load("Textures/Strategy/sea3_Sunny_sea") as Texture); mTexture_snow.mainTexture = (Resources.Load("Textures/Strategy/sea3_snow") as Texture); } else if (mAreaId == 15 || mAreaId == 16 || mAreaId == 17) { mTexture_sallyBGsky.mainTexture = (Resources.Load("Textures/Strategy/sea4_Sunny_sky2") as Texture); mTexture_sallyBGclouds.mainTexture = (Resources.Load("Textures/Strategy/sea4_Sunny_clouds") as Texture); mTexture_sallyBGcloudRefl.mainTexture = (Resources.Load("Textures/Strategy/sea4_Sunny_clouds") as Texture); mTexture_sallyBGcloudRefl.height = 120; mTexture_sallyBGcloudRefl.alpha = 0.25f; mTexture_bgSea.mainTexture = (Resources.Load("Textures/Strategy/sea4_Sunny_sea") as Texture); mTexture_snow.mainTexture = null; } else { mTexture_sallyBGsky.mainTexture = (Resources.Load("Textures/Strategy/sea1_Sunny_sky") as Texture); mTexture_sallyBGclouds.mainTexture = (Resources.Load("Textures/Strategy/sea1_Sunny_clouds") as Texture); mTexture_sallyBGcloudRefl.mainTexture = (Resources.Load("Textures/Strategy/sea1_Sunny_clouds") as Texture); mTexture_sallyBGcloudRefl.height = 140; mTexture_sallyBGcloudRefl.alpha = 0.25f; mTexture_bgSea.mainTexture = (Resources.Load("Textures/Strategy/sea1_Sunny_sea") as Texture); mTexture_snow.mainTexture = null; } return(true); }
protected override bool Init() { this.isAnimationStarted = false; this.mDisplaySwipeRegion.SetEventCatchCamera(this.mCamera); this.mDisplaySwipeRegion.SetOnSwipeActionJudgeCallBack(new UIDisplaySwipeEventRegion.SwipeJudgeDelegate(this.OnSwipeAction)); this.mStageSelectRoot.set_localPosition(new Vector3(this.mCamera.get_transform().get_localPosition().x, this.mCamera.get_transform().get_localPosition().y)); this.mAreaId = StrategyTopTaskManager.Instance.TileManager.FocusTile.areaID; this.mStrategyTopTaskManager = StrategyTaskManager.GetStrategyTop(); this.mIsFinishedAnimation = false; this.mMapModels = StrategyTopTaskManager.GetLogicManager().SelectArea(this.mAreaId).Maps; this.mSortieManager = StrategyTopTaskManager.GetLogicManager().SelectArea(this.mAreaId); this.mKeyController = new KeyControl(0, 0, 0.4f, 0.1f); this.mKeyController.isLoopIndex = true; this.mKeyController.IsRun = false; TweenAlpha.Begin(GameObject.Find("Information Root"), 0.3f, 0f); TweenAlpha.Begin(GameObject.Find("Map_BG"), 0.3f, 0f); GameObject gameObject = StrategyTopTaskManager.Instance.TileManager.Tiles[this.mAreaId].getSprite().get_gameObject(); this.mTransform_AnimationTile = Util.Instantiate(gameObject, GameObject.Find("Map Root").get_gameObject(), true, false).get_transform(); this.mAnimation_MapObjects = this.mTransform_StageCovers.GetComponent <Animation>(); base.StartCoroutine(this.StartSeaAnimationCoroutine()); IEnumerator enumerator = this.StartSeaAnimationCoroutine(); base.StartCoroutine(enumerator); this.mTransform_StageCovers.SetActive(true); this.mTransform_StageCovers.Find("UIStageCovers").GetComponent <UIWidget>().alpha = 0.001f; this.SelectedHexAnimation(delegate { base.StartCoroutine(this.InititalizeStageCovers(delegate { this.mTransform_StageCovers.GetComponent <Animation>().Play("SortieAnimation"); this.ShowMaps(this.mMapModels); })); }); if (this.mAreaId == 2 || this.mAreaId == 4 || this.mAreaId == 5 || this.mAreaId == 6 || this.mAreaId == 7 || this.mAreaId == 10 || this.mAreaId == 14) { this.mTexture_sallyBGsky.mainTexture = (Resources.Load("Textures/Strategy/sea2_Sunny_sky") as Texture); this.mTexture_sallyBGclouds.mainTexture = (Resources.Load("Textures/Strategy/sea2_Sunny_clouds") as Texture); this.mTexture_sallyBGcloudRefl.mainTexture = (Resources.Load("Textures/Strategy/sea2_Sunny_clouds") as Texture); this.mTexture_sallyBGcloudRefl.height = 91; this.mTexture_sallyBGcloudRefl.alpha = 0.25f; this.mTexture_bgSea.mainTexture = (Resources.Load("Textures/Strategy/sea2_Sunny_sea") as Texture); this.mTexture_snow.mainTexture = null; } else if (this.mAreaId == 3 || this.mAreaId == 13) { this.mTexture_sallyBGsky.mainTexture = (Resources.Load("Textures/Strategy/sea3_Sunny_sky") as Texture); this.mTexture_sallyBGclouds.mainTexture = (Resources.Load("Textures/Strategy/sea3_Sunny_clouds") as Texture); this.mTexture_sallyBGcloudRefl.mainTexture = (Resources.Load("Textures/Strategy/sea3_Sunny_clouds") as Texture); this.mTexture_sallyBGcloudRefl.height = 90; this.mTexture_sallyBGcloudRefl.alpha = 0.75f; this.mTexture_bgSea.mainTexture = (Resources.Load("Textures/Strategy/sea3_Sunny_sea") as Texture); this.mTexture_snow.mainTexture = (Resources.Load("Textures/Strategy/sea3_snow") as Texture); } else if (this.mAreaId == 15 || this.mAreaId == 16 || this.mAreaId == 17) { this.mTexture_sallyBGsky.mainTexture = (Resources.Load("Textures/Strategy/sea4_Sunny_sky2") as Texture); this.mTexture_sallyBGclouds.mainTexture = (Resources.Load("Textures/Strategy/sea4_Sunny_clouds") as Texture); this.mTexture_sallyBGcloudRefl.mainTexture = (Resources.Load("Textures/Strategy/sea4_Sunny_clouds") as Texture); this.mTexture_sallyBGcloudRefl.height = 120; this.mTexture_sallyBGcloudRefl.alpha = 0.25f; this.mTexture_bgSea.mainTexture = (Resources.Load("Textures/Strategy/sea4_Sunny_sea") as Texture); this.mTexture_snow.mainTexture = null; } else { this.mTexture_sallyBGsky.mainTexture = (Resources.Load("Textures/Strategy/sea1_Sunny_sky") as Texture); this.mTexture_sallyBGclouds.mainTexture = (Resources.Load("Textures/Strategy/sea1_Sunny_clouds") as Texture); this.mTexture_sallyBGcloudRefl.mainTexture = (Resources.Load("Textures/Strategy/sea1_Sunny_clouds") as Texture); this.mTexture_sallyBGcloudRefl.height = 140; this.mTexture_sallyBGcloudRefl.alpha = 0.25f; this.mTexture_bgSea.mainTexture = (Resources.Load("Textures/Strategy/sea1_Sunny_sea") as Texture); this.mTexture_snow.mainTexture = null; } return(true); }