private void SetNextSlide() { if (m_iterator.MoveNext()) { m_currentData = (EndingSlidesStaticData)m_iterator.Current; if (LegacyLogic.Instance.WorldManager.IsShowingEndingSequences && m_currentData.DLC) { ContextManager.ChangeContext(EContext.CreditsScreen); return; } if (CheckCondition(m_currentData)) { m_text.text = LocaManager.GetText(m_currentData.TextKey); Texture texture = Helper.ResourcesLoad <Texture>("EndingSlides/" + m_currentData.Image); if (m_texture.mainTexture != texture) { Texture mainTexture = m_texture.mainTexture; m_texture.mainTexture = texture; if (mainTexture != null) { mainTexture.UnloadAsset(); } } m_state.ChangeState(EState.FADEIN_BACKGROUND); } else { SetNextSlide(); } } else { ContextManager.ChangeContext(EContext.Diploma); } }
private void BackToMainMenu() { LegacyLogic.Instance.WorldManager.ClearAndDestroy(); LegacyLogic.Instance.WorldManager.SaveGameName = String.Empty; LegacyLogic.Instance.WorldManager.IsSaveGame = false; ContextManager.ChangeContext(EContext.Mainmenu); }
private void Start() { m_SkipableByUser = (PlayerPrefs.GetInt("SkipDevIntro", 0) != 0); if (!m_SkipableByUser) { PlayerPrefs.SetInt("SkipDevIntro", 1); } EVideoDecoder videoDecoder = ConfigManager.Instance.Options.VideoDecoder; if (videoDecoder == EVideoDecoder.System) { m_AVProMovie.enabled = true; if (m_AVProMovie.LoadMovie()) { m_AVProMovie.Play(); } else { ContextManager.ChangeContext(EContext.Mainmenu); } } else { ContextManager.ChangeContext(EContext.Mainmenu); } }
public void OnPartyCreationDone() { LegacyLogic.Instance.WorldManager.PartyCreator.FinalizePartyCreation(); LegacyLogic.Instance.WorldManager.PartyCreator.GiveStartSetup(); LegacyLogic.Instance.WorldManager.CheckPassableOnMovement = false; Cleanup(); ContextManager.ChangeContext(EContext.Intro); }
private Boolean CheckChangeContext() { if (m_changeContext != EContext.None) { AudioListener.volume = 1f; AudioController.StopMusic(); ContextManager.ChangeContext(m_changeContext); return(true); } return(false); }
public void OnCancel(Object p_sender, HotkeyEventArgs p_args) { if (LegacyLogic.Instance.WorldManager.IsShowingEndingSequences) { ContextManager.ChangeContext(EContext.Game); } else { ContextManager.ChangeContext(EContext.Mainmenu); } }
private IEnumerator PreLoadAsset() { AudioManager.Instance.RequestMainController(); while (!AudioManager.Instance.MainControllerIsLoaded) { yield return(null); } Texture2D cur = Helper.ResourcesLoad <Texture2D>("Cursor/CUR_interact"); Cursor.SetCursor(cur, default(Vector2), CursorMode.Auto); ContextManager.ChangeContext(m_StartContextID); yield break; }
public void OnContinueButtonClick() { Dictionary <String, SaveGameMeta> allSaveGames = LegacyLogic.Instance.WorldManager.SaveGameManager.GetAllSaveGames(false); List <SaveGameMeta> list = new List <SaveGameMeta>(allSaveGames.Values); if (list.Count > 0) { list.Sort(new Comparison <SaveGameMeta>(SortSaveGamesByDate)); LegacyLogic.Instance.WorldManager.LoadedFromStartMenu = true; LegacyLogic.Instance.WorldManager.IsSaveGame = true; LegacyLogic.Instance.WorldManager.SaveGameName = list[0].Name; ContextManager.ChangeContext(EContext.Game); } }
private void Update() { if (Input.anyKeyDown && m_SkipableByUser) { m_AVProMovie.Pause(); m_AVProMovie.View.enabled = false; ContextManager.ChangeContext(EContext.Mainmenu); enabled = false; } if (m_AVProMovie.IsError || m_AVProMovie.IsFinishedPlaying) { ContextManager.ChangeContext(EContext.Mainmenu); } }
private void OnCloseKeyPressed(Object sender, HotkeyEventArgs e) { String text = GamePaths.UserGamePath + "/ScreenShots"; Directory.CreateDirectory(text); DateTime utcNow = DateTime.UtcNow; Application.CaptureScreenshot(String.Format("{0}/{1:D04}{2:D02}{3:D02}_{4:D02}{5:D02}{6:D02}_{7}_Diploma.png", new Object[] { text, utcNow.Year, utcNow.Month, utcNow.Day, utcNow.Hour, utcNow.Minute, utcNow.Second, utcNow.Millisecond })); ContextManager.ChangeContext(EContext.Game); }
public void OnStartButtonClick() { ContextManager.ChangeContext(EContext.Mainmenu); }
public void OnCreditsButtonClick() { ContextManager.ChangeContext(EContext.CreditsScreen); }
public void OnStartButtonClick() { ContextManager.ChangeContext(EContext.PartyCreation); }
private void HandleOnLoadSaveGame(Object sender, EventArgs e) { ContextManager.ChangeContext(EContext.Game); }
public void OnBackClick() { LegacyLogic.Instance.WorldManager.ClearAndDestroy(); Cleanup(); ContextManager.ChangeContext(EContext.Mainmenu); }
private void FinishIntro() { ContextManager.ChangeContext(EContext.Game); }
public void OnClickedToMainMenu(GameObject p_sender) { ContextManager.ChangeContext(EContext.Mainmenu); }