Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - Dean

Pages: [1]
1
NGUI 3 Support / Set the anchors type
« on: April 18, 2015, 10:08:23 AM »
Hellow, help me please with this problem:
How can I set Anchors type to "Unified" by code?
And also in the box "Right" put "Target's left" or in the "Bottom" -> "Target's top" by code to?



Upd. I found a solution for the 1st quiestion:
SetAnchor(GameObject.Find("Camera"), 0, 0, 0, 0);

Upd2. Found and for the 2nd:
GetComponent<UIWidget>().leftAnchor.Set(0, int offset); - Target's left;
GetComponent<UIWidget>().leftAnchor.Set(1, int offset); - Target's right

the same for top/bot

2
NGUI 3 Support / Re: NGUI ScrollView doesn't hide sub elements
« on: April 17, 2015, 07:20:29 AM »
Well, I've solved my problem: i should have chosen "UI" in the Event type of UICamera


3
NGUI 3 Support / Re: Text appearing outside of UILabel bounds
« on: April 16, 2015, 01:04:41 PM »
Try using NGUITools.MarkParentAsChanged(gameObject); after all changes

4
NGUI 3 Support / NGUI ScrollView doesn't hide sub elements
« on: April 16, 2015, 01:01:29 PM »
Hello, help me please, i have a problem: I created an UI Panel + UIScrollView, put inside an UIGrid, after that, inside I put several elements as UIDragDropItems.

UIPanel + UIScrollView
- UIGrid
- - item
- - item1
- - item2

But when i scroll down my UIPanel and theese items come invisible, I stiil can hover on them mouse cursor and click them, drag an so on, as they were visible.
I tried to change depth, z.position, but nothing happens. How can i fix it?




Pages: [1]