Home > other >  Unity3D how to solve the problem of the UI "through"?
Unity3D how to solve the problem of the UI "through"?

Time:09-18

Novice to learn Unity3D, found a problem in the demo, describe not to come out, as the chart


On another page, has been completely can't see the button, click on the button position, however, still can trigger the click event, this is how to return a responsibility?

Do you have any similar mask layer? Z - the index? This thing? How to avoid this kind of "penetration" click?

CodePudding user response:


Open the gray background of the UI radiation monitoring this will block the lower UI radiation monitoring

CodePudding user response:

reference 1st floor NewWorld_ response:

Open the gray background of the UI rays that would block the lower UI ray monitoring


Hello, I see a gray background of the UI using NGUI Texture is not the radiation monitoring

In another way to solve this now penetrated, is to add a collision on the prefabricated body, then the size adjustment of large

Is to be able to solve the problem of penetration, but don't know if the right way

CodePudding user response:

UICamera hoverObject!=null point is the NGUI

CodePudding user response:

wrong, you don't block the following interface, the pop-up interface to add a full-screen collision

CodePudding user response:

Write their own script inherit ngui had the function of the script, modify the ray would like to change event code, written in his subclass to replace the original script, another method, have a special plug-in, to solve the problem of the company directly

CodePudding user response:

NGUI, adjust the hierarchy problem well

CodePudding user response:

Change background image transparent, collision detection area covers the whole UI interface

CodePudding user response:

If it is NGUI: adjust the levels to go; If it is UGUI: the Raycast Target box
  • Related