Esempio n. 1
0
 public void OnHidBark(TextMeshProBarkUI barkUI)
 {
     if (barkUI == null)
     {
         return;
     }
     StopAllCoroutines();
     StartCoroutine(FadeOut(barkUI.textMeshPro));
 }
 public void OnShowedBark(TextMeshProBarkUI barkUI)
 {
     if (barkUI == null)
     {
         return;
     }
     CheckShowHideController();
     showHideController.ClearTrigger(animationTransitions.hideTrigger);
     showHideController.Show(animationTransitions.showTrigger, false, null);
     isVisible = true;
 }
 public void Start()
 {
     barkUI = GetComponent <TextMeshProBarkUI>();
     if (barkUI == null || barkUI.textMeshPro == null)
     {
         if (DialogueDebug.LogWarnings)
         {
             Debug.LogWarning(string.Format("{0}: No TextMeshProBarkUI found on '{1}'. Not connecting TextMeshProBarkUIAnimator.",
                                            new object[] { DialogueDebug.Prefix, name }), this);
         }
     }
     else
     {
         barkUI.ShowedBark += OnShowedBark;
         barkUI.HidBark    += OnHidBark;
     }
 }
 public void OnHidBark(TextMeshProBarkUI barkUI)
 {
     if (barkUI == null)
     {
         return;
     }
     ShowControls();
     CheckShowHideController();
     showHideController.ClearTrigger(animationTransitions.showTrigger);
     if (isVisible)
     {
         showHideController.Hide(animationTransitions.hideTrigger, HideControls);
     }
     else
     {
         HideControls();
     }
 }