Disable Dialogue System Input During Game Pause
Posted: Mon Dec 11, 2023 6:08 pm
Hello, all.
Currently, my pause system works by listening for a key press, which then opens activates a Canvas Game Object that has various images and buttons as child Game Objects. (e.g.: Return to Game, Quit Game, etc.) The intent is that when the pause menu is open, the Dialogue System does not listen for/act on player input, but it's fine if things like animated dialogue portraits and such continue playing.
I've tried a variety of things (found in other forum threads and with PlayMaker), but no matter what I try, I can't seem to get the Dialogue System to ignore input when the game is in the 'pause' state. (The 'failure mode' here is that, while the pause menu is up, the player can still advance conversations by hitting the key I have mapped to a general 'interact' action.)
Here is what I've tried (and what hasn't worked):
* Using the PlayMaker Action 'Pause' that's part of the Dialogue System set of PlayMaker actions. (It didn't seem to do anything.)
* Trying to use the PlayMaker Action 'EnableBehavior' to turn off the InputDeviceManager behavior on the main Dialogue Manager Game Object.
* Adding a script (whenever the Pause Menu is active) to the Dialogue Manager that contains the following:
Thanks for the help!
Currently, my pause system works by listening for a key press, which then opens activates a Canvas Game Object that has various images and buttons as child Game Objects. (e.g.: Return to Game, Quit Game, etc.) The intent is that when the pause menu is open, the Dialogue System does not listen for/act on player input, but it's fine if things like animated dialogue portraits and such continue playing.
I've tried a variety of things (found in other forum threads and with PlayMaker), but no matter what I try, I can't seem to get the Dialogue System to ignore input when the game is in the 'pause' state. (The 'failure mode' here is that, while the pause menu is up, the player can still advance conversations by hitting the key I have mapped to a general 'interact' action.)
Here is what I've tried (and what hasn't worked):
* Using the PlayMaker Action 'Pause' that's part of the Dialogue System set of PlayMaker actions. (It didn't seem to do anything.)
* Trying to use the PlayMaker Action 'EnableBehavior' to turn off the InputDeviceManager behavior on the main Dialogue Manager Game Object.
* Adding a script (whenever the Pause Menu is active) to the Dialogue Manager that contains the following:
- PixelCrushers.UIPanel.monitorSelection = false; // Don't allow dialogue UI to steal back input focus.
PixelCrushers.UIButtonKeyTrigger.monitorInput = false; // Disable hotkeys.
PixelCrushers.DialogueSystem.DialogueManager.Pause(); // Stop DS timers (e.g., sequencer commands).
Thanks for the help!