Example #1
0
 public void Clear()
 {
     _events.Clear();
     CurrentEvent.InterruptEvent();
     CurrentEvent = null;
 }
Example #2
0
 public void AddAction(Action action)
 {
     _events.Add(action);
 }
Example #3
0
 public bool RemoveAction(Action action)
 {
     return _events.Remove(action);
 }
Example #4
0
        protected IEnumerator StartNextAction()
        {
            if (_events.Count > 0)
            {
                CurrentEvent = _events[0];
                _events.RemoveAt(0);
            }
            else
            {
                CurrentEvent = new EmptyAction();
            }

            return CurrentEvent.NextFrame().GetEnumerator();
        }