Page 1 of 1

Unable to click anything.

Posted: Mon Nov 09, 2015 9:56 am
by Saehn
When using the non-legacy Unity UI Dialogue UI's, I am completely unable to click anything in the conversation. I cannot click the continue button or any of the options. The only thing that works is the ESC button for skip.

I have a Dialogue Manager. I have a canvas child which has the UI as a child. The UI is configured in the dialogue manager. I have an Event System in the hierarchy. I have absolutely nothing else in my seen nor any scripts involving the mouse. The problem persists whether I have the UI auto generated from selecting the prefab or putting them in myself. I haven't touched any project settings.

I've been searching all day and can't find a single thread on it. I watched a video using the non-legacy UI and it works fine. The examples using the SF Unity UI Dialogue UI also work fine.

I really have no idea what is happening. Does anyone have an idea?

Re: Unable to click anything.

Posted: Mon Nov 09, 2015 10:30 am
by Tony Li
It sounds like your UI's Canvas isn't receiving input events. Here are some things to check: (Also please check your email; I replied.)
  • If the Canvas is World Space or Screen Space - Camera, assign your camera to it.
  • Check that the Canvas's Receive Events checkbox is ticked, and that the Canvas GameObject has a Graphic Raycaster.
  • Make sure your EventSystem has a Standalone Input Module.
  • From your description, I don't think there's another Canvas sitting on top of your dialogue UI Canvas and blocking input, but that's something to check.
  • Can you structure your Dialogue Manager like the scenes in Examples/Unity UI Examples? That structure is:

Code: Select all

Dialogue Manager
     Canvas
          GameObject with UnityUIDialogueUI script
               Dialogue Panel
                    etc.
It's probably already structured like this, but I thought I'd double check. You can use other structures, too, but this is a solid, basic setup. The speech bubble example in 1.5.7a demonstrates a different setup with world space canvases above each actor's head.

Please also feel free to send an example project or scene that demonstrates the issue to tony (at) pixelcrushers.com, and let me know what version of Unity to use. I'll be happy to take a look!

Re: Unable to click anything.

Posted: Mon Nov 09, 2015 3:34 pm
by Saehn
Ah, that's the issue. After going to check my EventSystem at run time, it wasn't there. My one EventSystem was being destroyed along with a previous canvas from a prior scene. I've now given each scene their own event system.

Well that's a mistake I'll never make again, I lost plenty of work time over this. Thank you very much :)

Re: Unable to click anything.

Posted: Mon Nov 09, 2015 3:40 pm
by Tony Li
Glad you got it figured out! Those EventSystem issues sometimes have me pulling my hair out, too.

This might be in the category "too little, too late," but version 1.5.7a now checks for an EventSystem whenever it opens the dialogue UI. If it doesn't find one, it'll automatically add one.

Re: Unable to click anything.

Posted: Mon Nov 09, 2015 3:49 pm
by Saehn
Ah yes, that would have helped. However I suppose it's best I learned about the actual issue so it doesn't happen later on in another project.

The good part is that this fixes another huge issue I was having with an Audio() event not allowing the UI to show at all. I was so focused on why the audio wasn't working all of a previous day that I didn't even realise the UI itself wasn't in working order. Very eye opening. :)