public void StopJiFenTime() { if (Time.realtimeSinceStartup - TimeStartVal < 8f) { Debug.Log("Unity:" + "StopJiFenTime -> TimeStartVal was wrong!"); return; } if (IsMakeJiFenStop) { return; } IsMakeJiFenStop = true; IsShowFinishTask = false; JiFenJieMianObj.SetActive(false); Debug.Log("Unity:" + "StopJiFenTime..."); if (GameOverCtrl.IsShowGameOver) { XkGameCtrl.LoadingGameMovie(); return; } CountJiFenOpen++; #if CREAT_GAME_SCENE //动态加载下一关的游戏场景预制文件. XkGameCtrl.GetInstance().m_CreatSceneCom.CreatGameScene(CountJiFenOpen); #endif #if USE_LOADING_NEXT_SCENE //直接加载下一关的游戏场景. if (Application.loadedLevel < 4) { Application.LoadLevel(Application.loadedLevel + 1); } else { Application.LoadLevel(0); } #endif //CountJiFenOpen = 4; //test. if (CountJiFenOpen < 4) { XKBossXueTiaoCtrl.IsWuDiPlayer = false; XKTriggerStopMovePlayer.IsActiveTrigger = false; GameTimeCtrl.GetInstance().OpenGameTime(); CoinPlayerCtrl.GetInstanceOne().ShwoPlayerCoin(); CoinPlayerCtrl.GetInstanceTwo().ShwoPlayerCoin(); CoinPlayerCtrl.GetInstanceThree().ShwoPlayerCoin(); CoinPlayerCtrl.GetInstanceFour().ShwoPlayerCoin(); DaoJuCtrl.GetInstance().ShowAllPlayerDaoJu(); XKPlayerScoreCtrl.ShowPlayerScore(PlayerEnum.Null); } else { QuanBuTongGuanCtrl.GetInstance().ShowQuanBuTongGuan(); } }
void OnFinishTaskAlphaToEnd() { VRCameraObj.SetActive(false); if (SceneManager.GetActiveScene().buildIndex < (int)GameLevel.Scene_2 && SceneManager.GetActiveScene().buildIndex < (Application.levelCount - 1) && !GameOverCtrl.IsShowGameOver) { int loadLevel = SceneManager.GetActiveScene().buildIndex + 1; Debug.Log("loadLevel *** " + loadLevel); XkGameCtrl.IsLoadingLevel = true; if (NetCtrl.GetInstance() != null) { NetCtrl.GetInstance().ResetGameInfo(); } LoadingGameCtrl.ResetLoadingInfo(); if (!XkGameCtrl.IsGameOnQuit) { System.GC.Collect(); SceneManager.LoadScene(loadLevel); } } else { //loading movie scene. XkGameCtrl.LoadingGameMovie(); } }
public void StopJiFenTime() { if (Time.realtimeSinceStartup - TimeStartVal < 8f) { Debug.Log("Unity:" + "StopJiFenTime -> TimeStartVal was wrong!"); return; } if (IsMakeJiFenStop) { return; } IsMakeJiFenStop = true; IsShowFinishTask = false; JiFenJieMianObj.SetActive(false); Debug.Log("Unity:" + "StopJiFenTime..."); if (GameOverCtrl.IsShowGameOver) { XkGameCtrl.LoadingGameMovie(); return; } CountJiFenOpen++; //CountJiFenOpen = 4; //test. if (CountJiFenOpen < 4) { XKBossXueTiaoCtrl.IsWuDiPlayer = false; XKTriggerStopMovePlayer.IsActiveTrigger = false; if (GameTimeCtrl.GetInstance() != null) { GameTimeCtrl.GetInstance().OpenGameTime(); } CoinPlayerCtrl.GetInstanceOne().ShwoPlayerCoin(); CoinPlayerCtrl.GetInstanceTwo().ShwoPlayerCoin(); CoinPlayerCtrl.GetInstanceThree().ShwoPlayerCoin(); CoinPlayerCtrl.GetInstanceFour().ShwoPlayerCoin(); DaoJuCtrl.GetInstance().ShowAllPlayerDaoJu(); XKPlayerScoreCtrl.ShowPlayerScore(PlayerEnum.Null); } else { if (QuanBuTongGuanCtrl.GetInstance() != null) { QuanBuTongGuanCtrl.GetInstance().ShowQuanBuTongGuan(); } } }
public void StopJiFenTime() { if (IsInvoking("DelayStopJiFenPanel")) { CancelInvoke("DelayStopJiFenPanel"); } if (Time.realtimeSinceStartup - TimeStartVal < 8f) { Debug.Log("StopJiFenTime -> TimeStartVal was wrong!"); return; } if (IsMakeJiFenStop) { return; } IsMakeJiFenStop = true; //GameOverCtrl.IsShowGameOver = true; //test if (SceneManager.GetActiveScene().buildIndex < (int)GameLevel.Scene_4 //if (SceneManager.GetActiveScene().buildIndex < XkGameCtrl.TestGameEndLv //test && SceneManager.GetActiveScene().buildIndex < (SceneManager.sceneCountInBuildSettings - 1) && !GameOverCtrl.IsShowGameOver) { MakeOtherPortStopJiFenTime(); int loadLevel = SceneManager.GetActiveScene().buildIndex + 1; Debug.Log("loadLevel *** " + loadLevel); XkGameCtrl.IsLoadingLevel = true; if (NetCtrl.GetInstance() != null) { NetCtrl.GetInstance().ResetGameInfo(); } LoadingGameCtrl.ResetLoadingInfo(); if (!XkGameCtrl.IsGameOnQuit) { System.GC.Collect(); SceneManager.LoadScene(loadLevel); } } else { XkGameCtrl.LoadingGameMovie(); } }
public void StopJiFenTime() { if (IsInvoking("DelayStopJiFenPanel")) { CancelInvoke("DelayStopJiFenPanel"); } if (Time.realtimeSinceStartup - TimeStartVal < 8f) { Debug.Log("StopJiFenTime -> TimeStartVal was wrong!"); return; } if (IsMakeJiFenStop) { return; } IsMakeJiFenStop = true; //GameOverCtrl.IsShowGameOver = true; //test if (Application.loadedLevel < (int)GameLevel.Scene_4 //if (Application.loadedLevel < XkGameCtrl.TestGameEndLv //test && Application.loadedLevel < (Application.levelCount - 1) && !GameOverCtrl.IsShowGameOver) { MakeOtherPortStopJiFenTime(); int loadLevel = Application.loadedLevel + 1; Debug.Log("loadLevel *** " + loadLevel); XkGameCtrl.IsLoadingLevel = true; if (NetCtrl.GetInstance() != null) { NetCtrl.GetInstance().ResetGameInfo(); } LoadingGameCtrl.ResetLoadingInfo(); if (!XkGameCtrl.IsGameOnQuit) { System.GC.Collect(); Application.LoadLevel(loadLevel); } } else { XkGameCtrl.LoadingGameMovie(); } }
/// <summary> /// 包月支付返回. /// </summary> /// <param name="s">#号隔开 返回结果码#结果</param> public void OnMonthPayFinish(string s) { Debug.Log("Unity: OnMonthPayFinish:" + s); OnReceivedMiGuPayMsg("包月支付返回消息:" + s); //包月支付界面已经关闭. IsDisplayMiGuPayUI = false; //咪咕电视游戏包月查询完毕. IsQueryGameBaoYueState = false; string[] msgArray = s.Split('#'); MonthPayState type = MonthPayState.Failed; if (msgArray[0] == "1") { //咪咕电视游戏包月支付订购成功. type = MonthPayState.Succeess; } switch (type) { case MonthPayState.Succeess: { //游戏包月成功或游戏已经进行过包月. IsHaveBaoYueGame = true; break; } case MonthPayState.Failed: { //游戏包月失败. //使游戏返回循环动画入口界面. XkGameCtrl.IsLoadingLevel = false; XkGameCtrl.LoadingGameMovie(); break; } } OnReceivedMiGuPayMsg("MonthPayState == " + type); }
private void ClickTVYaoKongEnterBtEvent(ButtonState val) { if (m_ExitType == DlgEnum.QuXiao) { switch (val) { case ButtonState.DOWN: { SetQuXiaoUITexture(1); break; } case ButtonState.UP: { SetQuXiaoUITexture(0); Debug.Log("Unity:" + "Player close SSGameBaoYueDlg ui..."); if (XkGameCtrl.GetInstance() != null && XkGameCtrl.GetInstance().m_GameUICom != null) { XkGameCtrl.GetInstance().m_GameUICom.RemoveGameBaoYuePanel(); } if (pcvr.GetInstance().m_SSMiGuTvCheck != null) { //关闭游戏包月检测. pcvr.GetInstance().m_SSMiGuTvCheck.CloseQueryGameBaoYueState(); } //使游戏返回循环动画入口界面. XkGameCtrl.IsLoadingLevel = false; XkGameCtrl.LoadingGameMovie(); break; } } } if (m_ExitType == DlgEnum.QueDing) { switch (val) { case ButtonState.DOWN: { SetQueDingUITexture(1); break; } case ButtonState.UP: { SetQueDingUITexture(0); Debug.Log("Unity:" + "Player select baoYue zhiFu..."); if (XkGameCtrl.GetInstance() != null && XkGameCtrl.GetInstance().m_GameUICom != null) { XkGameCtrl.GetInstance().m_GameUICom.RemoveGameBaoYuePanel(); } //打开安卓包月支付界面. if (pcvr.GetInstance() != null) { pcvr.GetInstance().OpenMiGuBaoYueZhiFuPanel(); } break; } } } }
void DelayClientLoadingGameMovie() { XkGameCtrl.LoadingGameMovie(1); }
void DelayServerLoadingGameMovie() { XkGameCtrl.LoadingGameMovie(); }
void DelayLoadingGameMovie() { GameOverObj.SetActive(false); XkGameCtrl.LoadingGameMovie(); //Back Movie Scene. }
void OnFinishTaskAlphaToEnd() { VRCameraObj.SetActive(false); //loading movie scene. XkGameCtrl.LoadingGameMovie(); }