Author Topic: 2D UI and 3D UI Menu items are disabled under NGUI menu?  (Read 11584 times)

paulygon

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 11
    • View Profile
Re: 2D UI and 3D UI Menu items are disabled under NGUI menu?
« Reply #15 on: September 19, 2014, 10:59:18 AM »
Thanks for sharing that. Most of my projects that use NGUI (meaning all of them ;) look like ArenMook's example. I spent a ton of time just now trying to justify my current project's organizational method. I still can't find a compelling reason to rebuild it all just to bury everything under the same root. My project would be the same mess, i'd just have to open the now singular root it's under to see it all. Of course I'm worried that half way through rebuilding I would run into problems that I can't predict until I've tried it, versus now, everything works great. Again, what would that gain except having to open one root object to see what amounts to the entire game's content?

Nicki

  • Global Moderator
  • Hero Member
  • *****
  • Thank You
  • -Given: 33
  • -Receive: 141
  • Posts: 1,768
    • View Profile
Re: 2D UI and 3D UI Menu items are disabled under NGUI menu?
« Reply #16 on: September 19, 2014, 06:59:25 PM »
A single place for setting fairly basic values (UIRoot) is in itself a good reduction of error potential. Generally, I would load things dynamically instead of having everything loaded from the start though, but that's not necessarily needed depending on the complexity of the menu. It's a classic DRY issue - if you need to change your root values now, you're in for a headache. You'll also have to check each and every root in your project to make sure they're all the same, because otherwise none of the pixel values will correspond properly to each other. So there's repeated overhead in your setup, with no real added value other than 1 level of hierarchy saved for organization.

I see no compelling reason for it, based on what I see here, and honestly if you were one of the programmers on my team I would bonk you on the head with a paper and make you change it. :)

If you have significant changes, then you can potentially justify it; say an entirely different camera set up, or something like that. Right now, it seems to just be for saving 10 pixels on the x-axis in the hierarchy view, which seems to be a big headache for not very much gain.

Assuming that all the roots are identical anyway, then changing it is nothing more than dragging the content into your "main" root and cutting out all the other stuff.


paulygon

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 11
    • View Profile
Re: 2D UI and 3D UI Menu items are disabled under NGUI menu?
« Reply #17 on: September 19, 2014, 08:34:28 PM »
LOL, point taken Nicki. As you said, it might not be as bad a switch as I imagine. I'll have to experiment to see.