public void RegisterRunning(TreeTask <TBb> task) { CurrentlyRunning.Add(task); // We remove it here to spare some cycles later on. if (task.PreviousTickState == TaskState.Running) { PreviouslyRunning.Remove(task); } // The first one to report running is the deepest running one if (RunningTask == null) { RunningTask = task; } }
public void RegisterNoLongerRunning(TreeTask <TBb> task) { PreviouslyRunning.Remove(task); }