private void OnEnable() { if (text == null) { text = GetComponent <TextMeshProUGUI>(); } if (Color != null) { Color.AddHandler(OnChangeValue); } OnChangeValue(); }
private void OnEnable() { if (Sprite == null) { Sprite = GetComponent <Image>(); } if (Color != null) { Color.AddHandler(OnChangeValue); } OnChangeValue(); }
private void OnEnable() { if (Button == null) { Button = GetComponent <Button>(); } if (NormalColor != null) { NormalColor.AddHandler(OnChangeNormalValue); } OnChangeNormalValue(); if (DisabledColor != null) { DisabledColor.AddHandler(OnChangeDisableValue); } OnChangeDisableValue(); }