Tasharen Entertainment Forum
Support => NGUI 3 Support => Topic started by: singh029 on February 22, 2016, 02:22:24 AM
-
I was wondering if theres a way to get the layer name of the widget that is clicked.
Im using playmaker to call a void method on click of outside area (not panel) to disable a panel. But everytime i click the panel it keeps closing. The click keeps falling through to the widget below it, so it closes. How do i prevent that?
Im setting UI Camera depth on layers but that doesnt seem to help.
Please save mee!
-
These links might help:
http://answers.unity3d.com/questions/585108/how-do-you-access-sorting-layers-via-scripting.html
http://forum.unity3d.com/threads/list-of-sorting-layers.210683/
Cheers.
-
These links might help:
http://answers.unity3d.com/questions/585108/how-do-you-access-sorting-layers-via-scripting.html
http://forum.unity3d.com/threads/list-of-sorting-layers.210683/
Cheers.
thank you for your help but i just solved it by putting a box collider on the panel so it absorbs the clicks. :)
I apologize, I didn't ask the correct questions.
-
For Popup dialogs/GUIs that are widgets, I have the same solution of adding a "ClickBlocker" widget.
Anchors to the background widget and stretches out to size of dialog/GUI.
You will run into a problem when you disable buttons.
It will disable the collider and click events will go through disabled buttons to what is underneath.
Yes your users are going to click disabled buttons.
For me it was a map that accepted click.
I argued with him over it but got nowhere.