void Awake() { _slider = this.transform.Find("HpBar").gameObject.GetComponent <Slider>(); _name = this.transform.Find("Name").gameObject.GetComponent <MTextFormat>(); _hpText = this.transform.Find("HpText").gameObject.GetComponent <MTextFormat>(); _canvas = GameObject.Find("Canvas").GetComponent <Canvas>(); StartCoroutine(EndOfFrameHandler()); }
public void OnEnable() { mTextFormat = target as MTextFormat; text = mTextFormat.gameObject.GetComponentInChildren <Text>(); outline = mTextFormat.gameObject.GetComponentInChildren <Outline>(); }