Tasharen Entertainment Forum

Support => NGUI 3 Support => Topic started by: poolts on May 13, 2014, 11:07:42 AM

Title: Grouping UI Elements
Post by: poolts on May 13, 2014, 11:07:42 AM
I've heard a few schools of thought on this:

I'm currently doing option 1 and just wanted to make sure that's the correct way to go.

P.S. I know this is a pretty simple question, but I searched the forums and found a few different answers, so wasn't really sure which is best.
Title: Re: Grouping UI Elements
Post by: ArenMook on May 14, 2014, 05:26:22 AM
Depends on what you're doing.

Generally you will want to have a panel container for each new window you create as moving panels is very efficient, while moving widgets is not. For regular grouping, an empty game object is perfectly fine. However if you want to be able to move the object in the scene view like a widget, then you will need to place a UIWidgetContainer on it. Using a widget is great if you are making good use of the layout system (anchoring), or if you want to control the alpha of a group of widgets (as widget alpha is cumulative).