Author Topic: UIRoot freeze  (Read 2353 times)

Undeadpunk

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 2
    • View Profile
UIRoot freeze
« on: August 04, 2014, 08:22:12 AM »
Hello, i faced the folowing problem. I created menu, and when i'm pressing button, active panel should disable and another have to enable, i did it by using gameObject.SetActive(), but it makes UIPanel on UIRoot freeze on 5-7 ms as like as UICamera. What am i doing wrong?

Undeadpunk

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 2
    • View Profile
Re: UIRoot freeze
« Reply #1 on: August 04, 2014, 10:00:36 AM »
Nobody knows?

ArenMook

  • Administrator
  • Hero Member
  • *****
  • Thank You
  • -Given: 337
  • -Receive: 1171
  • Posts: 22,128
  • Toronto, Canada
    • View Profile
Re: UIRoot freeze
« Reply #2 on: August 04, 2014, 11:13:01 AM »
When UI elements are enabled they have to register themselves with a panel and perform some other logic. If you have a lot of widgets, this may take some time. You can achieve the same effect by keeping your UI present and simply changing the Alpha.