Author Topic: Hiding/Showing UI Components  (Read 3476 times)

pushxtonotdie

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 14
    • View Profile
Hiding/Showing UI Components
« on: May 16, 2012, 08:55:27 PM »
Hello,

First off, thanks for making my life easier. Its been about 3-4 hours of using NGUI and I really don't know why Unity's normal GUI doesn't work like this. I'm a Unity n00b but I'm used to using bitmap fonts, sliced graphics etc. so I just fit right in to using NGUI. I also appreciate the wealth of documentation. Very professional overall.

So my question relates to hiding/showing or creating/removing guis. I have a couple guis that are 'in-game' (imagine sound menu/ingame help/etc.) and when clicking the button this will essentially

* pause game state
* hide the in-game gui
* display the appropriate gui

And when that gui is done, I would
* hide(delete?) the current gui
* show the in-game gui
* resume game

Like I said I'm new to Unity. I'm thinking that I could create all my menus, hide them all except the in-game menu, then toggle the visibility/enabled-ness of them as needed. I just worry that doing this would have a negative impact on perf/memory (i'm targeting iOS).

Does this sound like a reasonable plan? Or is there a more preferred method?

Thanks!


ArenMook

  • Administrator
  • Hero Member
  • *****
  • Thank You
  • -Given: 337
  • -Receive: 1171
  • Posts: 22,128
  • Toronto, Canada
    • View Profile
Re: Hiding/Showing UI Components
« Reply #1 on: May 16, 2012, 09:19:20 PM »
Disabled UIs don't affect performance at all, so you have nothing to worry about.