I am doing some black magic that can hopefully make use of the Pos Y property on uGUI elements.
I'd be SO happy if I could just return the correct value for this, but whenever I try, it doesn't work.
I am using a WorldSpace canvas.
I have tried to Debug.Log() the following:
- recTransform.rect.position.y
- rectTransform.anchoredPosition.y
- rectTransform.position.y
- rectTransform.anchoredPosition3D.y
it always returns zero like in the following example, except for anchoredPosition.y, which returns 2.0 for some reason.... wtf... what it SHOULD return is -10 :/
I hope using VerticalLayout component hasn't LOCKED my values to zero without telling me or something....
![alt text][1]
[1]: /storage/temp/41175-capture.png
↧