Ejemplo n.º 1
0
 public static void SetAnchors(this RectTransform RT, MinMax anchors)
 {
     RT.anchorMin = anchors.min;
     RT.anchorMax = anchors.max;
 }
Ejemplo n.º 2
0
 //Helper function to restore the anchors as above
 public static void SetAnchors(this UIBehaviour ui, MinMax anchors)
 {
     RectTransform RT = ui.transform as RectTransform;
     RT.anchorMin = anchors.min;
     RT.anchorMax = anchors.max;
 }