Author Topic: UI Root contents rendered in world location  (Read 2355 times)

Ratboy

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 1
    • View Profile
UI Root contents rendered in world location
« on: July 02, 2014, 01:07:00 AM »
Hi, I'm using NGUI with the "Realistic FPS" plugin from the asset store, and I've got a UI Camera attached to the main camera and weapon camera in the player prefab.  I also have a UI Root with a few buttons, and a model in the game with a button script attached to it.  I'm able to interact with all buttons and character controller just fine, but the buttons in the UI Root are rendering in game both on the player hud, AND in their world position from the scene view, and they are visible through the terrain I placed them behind also.  Is this a panel problem?  A layer problem?  I had to put the whole UI Root in the "gun" layer to make it visible to the weapon camera in the player controller prefab.  I'm not sure what to look for here.  Thanks!

ArenMook

  • Administrator
  • Hero Member
  • *****
  • Thank You
  • -Given: 337
  • -Receive: 1171
  • Posts: 22,128
  • Toronto, Canada
    • View Profile
Re: UI Root contents rendered in world location
« Reply #1 on: July 02, 2014, 05:47:28 AM »
Modify the culling mask on your cameras. Main camera should not be drawing the UI.