Tasharen Entertainment Forum

Support => NGUI 3 Support => Topic started by: xiaoniaojjj on October 17, 2012, 03:03:35 AM

Title: How to change the Panel depth ?
Post by: xiaoniaojjj on October 17, 2012, 03:03:35 AM
If i have a few panel in one "UI Root (3D)UI", I want to adjust the panel depth , like i want the target panel show the top layer!
Title: Re: How to change the Panel depth ?
Post by: Nicki on October 17, 2012, 06:10:17 AM
Read this first http://www.tasharen.com/forum/index.php?topic=1858.0
Title: Re: How to change the Panel depth ?
Post by: xiaoniaojjj on October 17, 2012, 10:01:45 AM
Thanks reply, I almost understand it, But my problem is, I have 2 panels, sames Atlas,Fonts,Layers, Z value of Panels A is -1, value of Panel B is 0, It looks right in Scene Window(0.jpg), but  error in Game Wiindow(1.jpg).  In fact, The B received Event before A.  I try to set Z value of A is -10. Everything is ok.
My trouble is, i don't know how to control the Z value of Panel accurate ,  Right now i just can try the Z value to correct.
Title: Re: How to change the Panel depth ?
Post by: ArenMook on October 17, 2012, 10:14:28 AM
Adjusting depth also moves widgets along the Z a little, so -1 may have been too small. -10 is noticeable, so that's why it works. In Windward my panels have depth ranging from 10 (background HUD) to -100 (modal dialog window).