Esempio n. 1
0
 private void ClearActionData()
 {
     //Reset any variables that were to do with the actions that have just been finished.
     currentAction           = null;
     currentActionsCoroutine = null;
     CurrentTargets          = new List <ITargetable>();
 }
Esempio n. 2
0
        private IEnumerator DoActions(List <AbilityAction> abilityActions)
        {
            //Loop through all of the actions for the useable.
            foreach (AbilityAction abilityAction in abilityActions)
            {
                //Cache the current action
                currentAction = abilityAction;

                //Pause execution here until the current action's "Trigger" coroutine is complete.
                yield return(abilityAction.Trigger(abilityCastData));
            }

            ClearActionData();
        }