Author Topic: UI Elements Disappearing, Not sure why  (Read 5374 times)

andrew2110

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 12
    • View Profile
UI Elements Disappearing, Not sure why
« on: July 29, 2014, 02:31:33 AM »
Hello all,

I'm having an issue with certain UI elements disappearing. If I switch to scene view and back to game view it re-appears, or if I make any adjustment to the UI camera's zoom, the elements reappear then too. I'm not sure where to start looking for a cause of this / how to stop it from doing it.


http://www.blueomega.me/WeirdMovie1.mp4 Here's a quick video showing whats happening. After 10 seconds in, it's ok to skip ahead to 25 seconds in as not much interesting happens during that time.

ArenMook

  • Administrator
  • Hero Member
  • *****
  • Thank You
  • -Given: 337
  • -Receive: 1171
  • Posts: 22,128
  • Toronto, Canada
    • View Profile
Re: UI Elements Disappearing, Not sure why
« Reply #1 on: July 29, 2014, 03:40:49 AM »
You should stick to camera size of 1. I'm not sure why you are using 1.35something. NGUI was written with ortho size 1 in mind. If you want to change the size of your UI, adjust the UIRoot. Don't touch the camera.

You should also make sure you have the latest NGUI. There have been changes related to game/scene view recently. It wasn't possible to determine the size properly when the game view was hidden.

andrew2110

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 12
    • View Profile
Re: UI Elements Disappearing, Not sure why
« Reply #2 on: July 29, 2014, 08:04:54 AM »
Thank you :) I'm not sure why the cameras size wasn't 1, I have fixed that. The problem still occurred but if I stopped my "moves panel" from reaching an alpha level of 0 and just disabled the game object when it was about to reach 0, buttons stopped disappearing. Not too sure why it happens still, but this workaround is acceptable for me right now.