Exemplo n.º 1
0
        public SequenceContext Prepare(SequenceBehaviour sequence = null, TickMode mode = TickMode.Auto)
        {
            m_Mode = mode;

            if (m_Context != null)
            {
                m_Context.Dispose();
                m_Context = null;
            }

            if (sequence != null)
            {
                m_Sequence = sequence;
            }

            if (m_Sequence == null)
            {
                return(null);
            }

            m_Context = m_Sequence.CreateContext(Blackboard);
            return(m_Context);
        }
Exemplo n.º 2
0
 public void Dispose()
 {
     m_Context?.Dispose();
     m_Context = null;
 }