Class CommandBaseAbstract

A command base class. Used to circumvent TypeScript abstract/interface weirdness by providing a version of Command which can be extended with attributes and constructors.

Hierarchy

Implements

Constructors

Properties

Accessors

Methods

Constructors

Properties

_requirements: Set<object> = ...

Accessors

  • get requirements(): Set<object>
  • The set of objects that this command requires to execute. Used to place mutexes on common resources to ensure they don't receive multiple inputs at once.

    Returns Set<object>

Methods

  • A utility method for adding multiple requirements at once.

    Parameters

    • reqs: object[]

    Returns void

  • Decorates the command with a "time point" - if the command finishes in less than the given duration, it will wait until this number of seconds has elapsed before continuing.

    Parameters

    • seconds: number

      The number of seconds that the command will execute for, at minimum.

    Returns Command

Generated using TypeDoc