Example #1
0
 // Use this for initialization
 void Start()
 {
     rt            = GetComponent <RectTransform>();
     shouldBe      = rt.anchoredPosition;
     home          = shouldBe;
     cont          = ContState.MAIN;
     role          = RoleState.NONE;
     up            = transform.FindChild("Up").gameObject.GetComponent <Image>();
     left          = transform.FindChild("Left").gameObject.GetComponent <Image>();
     right         = transform.FindChild("Right").gameObject.GetComponent <Image>();
     down          = transform.FindChild("Down").gameObject.GetComponent <Image>();
     up.enabled    = false;
     left.enabled  = false;
     right.enabled = false;
     down.enabled  = false;
 }
Example #2
0
 public void Home()
 {
     shouldBe = home;
     cont     = ContState.MAIN;
 }