public override void ActionUpdate(float timekey) { if (currentAction != null) { if (currentAction.IsDone) { currentAction = null; } else { currentAction.ActionUpdate(timekey); } } if (currentAction == null) { if (actions.Count > 0) { currentAction = actions.Dequeue(); currentAction.ActionStart(character); } else { Done(); } } }
internal void PushAction(CharacterActionBase action) { if (action == null) { return; } if (_actions == null) { _actions = new Queue <CharacterActionBase>(); } _actions.Enqueue(action); }
public void PushAction(CharacterActionBase action) { actions.Enqueue(action); }