Author Topic: UIPanel, New Anchoring system, Resizing of game window, and NaN problems  (Read 4576 times)

drawmaster77

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 21
    • View Profile
I am using a UIPanel with a scroll view script. Panel is anchored on top and bottom to the UIRoot. That way when window is resized, panel clipping is updated and its contents are clipped properly:


If I dont resize window or reize it making it bigger, everything works fine, however if I size it down panel clipping values set to NaN and everything breaks down requiring to restart game. This happens with both Alpha and Soft Clip settings.

ArenMook

  • Administrator
  • Hero Member
  • *****
  • Thank You
  • -Given: 337
  • -Receive: 1171
  • Posts: 22,128
  • Toronto, Canada
    • View Profile
Re: UIPanel, New Anchoring system, Resizing of game window, and NaN problems
« Reply #1 on: January 09, 2014, 07:28:24 PM »
That seems like a bug of some kind. Have you tried anchoring to the camera instead of the UIRoot?

drawmaster77

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 21
    • View Profile
Re: UIPanel, New Anchoring system, Resizing of game window, and NaN problems
« Reply #2 on: January 13, 2014, 01:08:39 AM »
That seems like a bug of some kind. Have you tried anchoring to the camera instead of the UIRoot?

No I haven't. After some more testing I found out that this happens only with collapsible categories (like in your Quest demo). However in my case they are a little more complex as they contain UITable themselves. There were a number of other odd things happening using the tweening to hide/show things inside (like UITable that was inside the tween not sorting properly), so I just took the collapsible category feature out and it seems to work well otherwise.