- Home /
Multiple Canvases 1 World Space 1 Screen Space Overlay Events Pass Through?
Hi,
I have two root layer canvases, one screen space overlay and the other worldspace. Both have buttons within. My problem is that when the camera is positioned as such that the content on screen space is over the world space content the events pass through. I have tried adding a canvas group and messing with the sort orders to no avail. Any suggestions as to where to look on this?
Thanks.
Answer by Sebas · Jan 19, 2015 at 10:54 PM
I was banging my head against the wall for the exact same reason until I came across the above forum thread. Simply replace the world space canvas GraphicsRaycaster with the raycaster that brendan.vance posted in the above link. Set the sort order of the world space raycaster lower than the sort order of your screenspace overlay canvases and you should be good to go.
This worked for me too using multiple overlaying world space canvases.
6 years later and this solution still works on Unity 2020.3.16.
Thx for saving my day ;)
Your answer
Follow this Question
Related Questions
IPointerClickHandler error 2 Answers
Text blurred: uGUI 4.6 9 Answers
Set Animation curve for uGUI elements 0 Answers
Remove Focus From InputField 2 Answers
ugui 4.6 Slider automatic reset 2 Answers