ScreenSpace canvas not working
Hi, I am upgrading the UI of my program, but it seems like I cannot work with screen space canvas (either camera or overlay). Objects in world space canvases work fine. GameObjects show in my "Game" screen, so I am a bit confused as to what the problem may be. To be clear: objects show in the "Game" screen, but not when I press the "play" button.
I attach a composite screenshot with information about one of the objects, the canvases and the camera.
Thanks a lot!
Pablo
Answer by uncronopio · Jun 08, 2016 at 07:15 AM
I think I now understand what the problem is. Apparently screen-space canvases (either overlay or camera) can ONLY work with UI-specific game objects. I still do not know why other sorts of elements can be added as children of these canvases (and specially why they correctly show in the Game-preview screen!)
Even if I am missing something deeper here, using elements from the UI folder works where others don't. I thought perhaps someone could find that useful.
I have similar problem. But I didn't understand your solution.
Answer by zingzingzingbah · Mar 01, 2019 at 07:22 AM
also, if like me you only have an image on your canvas, make sure the image colour alpha is not 0!
Answer by AlanMattano · May 20, 2020 at 01:44 AM
I found this after an update. And the solution was:
Go to your Event System Game Object
Notice that (in Unity 2018) the Event System component script is not attached
Add the Event System component.
And Activate the StandaloneInputModule component.
Your answer
Follow this Question
Related Questions
Prevent World Space canvas render mode to overlay other game objects 0 Answers
Screen Space - Camera for Mobile (Android) not working 0 Answers
RectTransform.localPosition = Vector3 Not setting correctly 0 Answers
Unity 2017.1 p4 - Unity Screen-space camera canvas - Graphics Raycaster fails 1 Answer
Take XYZ of GameObject and convert that to canvas co-ordinates? 0 Answers