If I disable/enable my canvas (pause game menu), controller navigation in the canvas stops to work?
I have two canvases. One for a pause menu. One for a settings menu. The pause menu has two buttons: continue game (disable canvas and open settings (disable canvas, enable settings canvas). While they are enabled the game is frozen (timescale 0f). The settings menu has several buttons. I can navigate them all perfectly fine using my controller (using EventSystem's Input Manager) with each canvas having a button as its selected item. The moment I close both canvases and return to the game (timescale 1f), then pause the game again (enable pause menu canvas), I can no longer navigate the canvases with a controller. A selected item will still be selected and so I can press the A button to continue the game, but I can no longer navigate (go up and down) across the buttons with the controller like before.
Is there anything obvious I'm doing wrong? I realise it's finicky with multiple canvases, adjusting timescale, etc.
Thanks.
Answer by Holt5 · Mar 13, 2020 at 10:26 PM
To be clear navigation etc. works perfectly fine, but then if I disable then reenable my canvas the controller is stuck on a selected item (button) and can no longer navigate as it could before prior to disabling the canvases. EDIT: Sorry, I have one canvas (always active) but two panels, not two canvases.
Your answer
Follow this Question
Related Questions
OnPointerEnter blocked by something 2 Answers
EventSystem raycasting on World Canvas gameobject always returning worldPosition of zero 2 Answers
EventSystem.current is returning null 0 Answers
UI buttons don't work with Canvas Render Mode: Screen Space - Camera. 2 Answers
How do I press an UI button with Gamepad controls? 0 Answers