public void Update()
 {
     if (RectTransformBroadcaster != null && rectTransform != null)
     {
         RectTransformBroadcaster.Apply(rectTransform);
     }
 }
Ejemplo n.º 2
0
 protected override void EnsureTextComponent()
 {
     if (TextMeshObserver == null)
     {
         RectTransformBroadcaster srt           = new RectTransformBroadcaster();
         RectTransform            rectTransform = GetComponent <RectTransform>();
         srt.Copy(rectTransform);
         TextMeshObserver = ComponentExtensions.EnsureComponent <TextMeshProUGUI>(gameObject);
         srt.Apply(rectTransform);
     }
 }