public static void EnterDialogue(NPC npc, bool fromQueue = false) { Hitstop.Interrupt(); if (dialogueOpen) { queuedNPCs.Enqueue(npc); return; } if (!pc.IsFacing(npc.gameObject)) { pc.ForceFlip(); } pc.EndCombatStanceCooldown(); if (!fromQueue) { dialogueUI.Open(); } currentNPC = npc; dialogueOpenedThisFrame = true; dialogueUI.ShowNameAndPicture(npc.GetCurrentLine()); if (npc.centerCameraInDialogue) { playerFollower.LookAtPoint(npc.gameObject); } pc.EnterCutscene(); }
virtual public void Open() { if ((exclusive && GlobalController.openUIs > 0)) { return; } if (!open) { GlobalController.openUIs += 1; } this.open = true; Hitstop.Interrupt(); if (interactSound) { SoundManager.InteractSound(); } GlobalController.pc.EnterCutscene(invincible: invincibleDuring); if (targetUI != null) { targetUI.SetActive(true); } if (stopTime) { Time.timeScale = 0f; } if (soloUISound) { SoundManager.SoloUIAudio(); } }
public static void EnterDialogue(NPC npc) { Hitstop.Interrupt(); if (dialogueOpen) { queuedNPCs.Enqueue(npc); return; } dialogueUI.Show(); pc.EnterDialogue(); currentNPC = npc; dialogueOpenedThisFrame = true; dialogueUI.ShowNameAndPicture(npc.GetCurrentLine()); }
public static void Pause() { if (pc.inCutscene) { return; } Hitstop.Interrupt(); pc.Freeze(); pc.inCutscene = true; pauseUI.SetBool("Shown", true); //manually first select pauseUI.transform.Find("EventSystem").GetComponent <EventSystem>().SetSelectedGameObject(pauseUI.transform.Find("Resume").gameObject); paused = true; SoundManager.InteractSound(); Time.timeScale = 0f; }
public static void EnterSlowMotion() { Hitstop.Interrupt(); Time.timeScale = 0.3f; }