-
Notifications
You must be signed in to change notification settings - Fork 25
Pivot
Jeppe Zapp edited this page Feb 13, 2014
·
1 revision
Sets the pivot of widgets
Variable | Type | |
---|---|---|
x | RelativeX |
Pivot on the x-axis |
y | RelativeY |
Pivot on the y-axis |
// UnityScript
var btn : OGButton;
function Start () {
// This widget should be centered
btn.pivot.x = RelativeX.Center;
btn.pivot.y = RelativeY.Center;
}
// C#
OGButton btn;
void Start () {
// This widget should be centered
btn.pivot.x = RelativeX.Center;
btn.pivot.y = RelativeY.Center;
}