public override void OnContentDisplay() { base.OnContentDisplay(); DisplayPlayers(); wrapContent.GetComponent <UICenterOnChild>().onFinished = OnChildSelected; CombatUnitManager mgr = CombatUnitManager.Instance; }
// Use this for initialization void OnEnable() { tempBool = action = false; centerOnChild = WrapContent.GetComponent <UICenterOnChild>(); // scrollviewOffsetX = Panel.transform.localPosition.x; Panel.GetComponent <UIScrollView>().ResetPosition(); // Panel.transform.localPosition = new Vector3(scrollviewOffsetX,Panel.transform.localPosition.y,Panel.transform.localPosition.z); }
protected override void OnStart() { base.OnStart(); if (ScrollView == null) { ScrollView = ItemContainer.GetComponent <UIScrollView>(); } }