Quantcast
Channel: Latest Questions on Unity Answers
Viewing all articles
Browse latest Browse all 171066

Line Renderer not working at all with Layer and Culling Mask when created in script

$
0
0
I have a Line Renderer with the layer set to one I made called GUI. I have two cameras, Main Camera and GUI Camera. One persp, one ortho. Main has its Culling Mask set to all except GUI. GUI has its culling mask set to GUI only. I have an object called "Selection Box". It has a LineRenderer that I add in script. Its layer is set to GUI. My LineRenderer is drawing on the Main Camera, and *not* drawing on the GUI Camera. This is backwards. I got past this by creating the line renderer in the editor instead of in script. If I do that, it draws on the right layer.

Viewing all articles
Browse latest Browse all 171066

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>