tickCommands method

void tickCommands(
  1. int timeDelta
)

Tick all commandNextRuns.

This method is called by tick.

Implementation

void tickCommands(final int timeDelta) {
  for (final nextRun in commandNextRuns) {
    nextRun.runAfter += timeDelta;
    final command = nextRun.value;
    final interval = command.interval!;
    if (nextRun.runAfter >= interval) {
      runCommand(command);
    }
  }
}