Exemplo n.º 1
0
        public void SequenceStart()
        {
            if (SequenceSafety.GetInstace().isRunning)
            {
                return;
            }

            StartCoroutine(StartSequenceCoroutine());
        }
Exemplo n.º 2
0
        private IEnumerator StartSequenceCoroutine()
        {
            SequenceSafety.GetInstace().isRunning = true;
            foreach (var s in sequences)
            {
                s.sequence.OnBeginSequence?.Invoke();
                yield return(StartCoroutine(s.sequence.Activate()));

                s.sequence.OnEndSequence?.Invoke();
            }
            SequenceSafety.GetInstace().isRunning = false;
        }