コード例 #1
0
        public void Hide(bool skipAnimation = false)
        {
            if (skipAnimation)
            {
                closeEvent.Complete(this);
                OnCloseAnimationCompleteCallback();
                return;
            }

            if (animationCoroutine != null)
            {
                StopCoroutine(animationCoroutine);
            }
            animationCoroutine = StartCoroutine(
                closeEvent.RunAnimation(this, OnCloseAnimationCompleteCallback));
        }
コード例 #2
0
        public void Show(bool skipAnimation = false)
        {
            gameObject.SetActive(true);
            if (skipAnimation)
            {
                openEvent.Complete(this);
                OnOpenAnimationCompleteCallback();
                return;
            }

            if (animationCoroutine != null)
            {
                StopCoroutine(animationCoroutine);
            }
            animationCoroutine = StartCoroutine(
                openEvent.RunAnimation(this, OnOpenAnimationCompleteCallback));
        }