Tasharen Entertainment Forum

Support => NGUI 3 Support => Topic started by: Lando100 on September 02, 2013, 06:20:20 AM

Title: Different layouts for different devices
Post by: Lando100 on September 02, 2013, 06:20:20 AM
Hey gui peeps,

Wondering if anyone had any advice for me about making completely separate UI's for different devices but they have the same functionality. For instance on iphone a pop up window which comes in full screen when a button is pressed and has a scroll view in side of it, and on ipad this same panel comes in only 1/4 screen and has a transparent background.

Was wondering if anyone had any genius solutions apart from on each component saying if ipad do this, if iphone do this....... is it even worth making completely different scenes for each device?!?!

Thanks
Lando
Title: Re: Different layouts for different devices
Post by: ArenMook on September 02, 2013, 05:57:01 PM
Is it worth it? I'd say no, but it depends on how much time you have and how picky you are.
Title: Re: Different layouts for different devices
Post by: LightSky on September 02, 2013, 11:51:11 PM
I'd say your best bet would be to make a "smart script" that would take into consideration the size of the screen and do what you want with it.  Overall it would be better than making several different scenes for each device.
Title: Re: Different layouts for different devices
Post by: Lando100 on September 03, 2013, 03:41:55 AM
yeah i think a smart script is the best solution, do i think its worth it? NO! Got to give the clients what they want tho ;)
Title: Re: Different layouts for different devices
Post by: sisso on September 03, 2013, 07:01:38 AM
My advices are:

- Use prefabas and load it when necessary for target device.
- Learn how to have a SD/HD version in same build.
- Don't mix logic and interface code (MVC like)