예제 #1
0
 void RemoveAction(IP_Action action)
 {
     if (targetSequence.m_Actions.Contains(action))
     {
         targetSequence.m_Actions.Remove(action);
     }
 }
예제 #2
0
 void MoveActionDown(IP_Action action, int index)
 {
     if (index != targetSequence.m_Actions.Count - 1 && action != null)
     {
         targetSequence.m_Actions.RemoveAt(index);
         index++;
         targetSequence.m_Actions.Insert(index, action);
     }
 }
예제 #3
0
 void MoveActionUp(IP_Action action, int index)
 {
     if (index != 0 && action != null)
     {
         targetSequence.m_Actions.RemoveAt(index);
         index--;
         targetSequence.m_Actions.Insert(index, action);
     }
 }
예제 #4
0
 public void CompletedSequence()
 {
     Debug.Log("Completed Sequence");
     completed     = true;
     currentAction = null;
     if (OnSequenceComplete != null)
     {
         OnSequenceComplete.Invoke();
     }
 }
예제 #5
0
 public void NextAction()
 {
     currentActionID++;
     if (currentActionID > m_Actions.Count - 1)
     {
         CompletedSequence();
     }
     else if (currentActionID >= 0 && currentActionID <= m_Actions.Count - 1)
     {
         currentAction = m_Actions[currentActionID];
         if (currentAction != null)
         {
             currentAction.StartAction();
         }
     }
 }
예제 #6
0
 public void ResetSequence()
 {
     currentActionID = 0;
     completed       = false;
     currentAction   = null;
 }
예제 #7
0
        void AddSimpleAction()
        {
            IP_Action curAction = new IP_Action();

            targetSequence.m_Actions.Add(curAction);
        }