Type Parameters

Hierarchy

Implements

Constructors

Properties

event: IEventEmitter<default<A, E, R, CU, AV>, ActionExecutorEvents> = ...

Accessors

  • get executor(): E
  • Returns E

  • get hasSetCanUse(): boolean
  • Check if the action has setup CanUse logic

    Returns boolean

Methods

  • The items passed to this method will be registered as items potentially to be damaged when the action completes.

    Parameters

    • Rest ...addItems: (undefined | default)[]

    Returns default<A, E, R, CU, AV>

  • Parameters

    • Rest ...skills: [SkillType, number?, number?, true?][]

    Returns default<A, E, R, CU, AV>

  • Parameters

    • skill: SkillType
    • Optional amount: number
    • Optional actionTier: number
    • Optional bypass: true

    Returns default<A, E, R, CU, AV>

  • Check if an action can be used. When used within an action, the result will automatically be processed. So it will send a message to the executor / check for mobs depending on the result.

    Returns CU | IActionNotUsable

  • Parameters

    Returns CU | IActionNotUsable

  • Parameters

    • executor: E
    • Rest ...args: AV

    Returns CU | IActionNotUsable

  • Alternate version of canUse that allows you to specify the facing point. Use with caution as this probably won't work for some actions

    Parameters

    Returns CU | IActionNotUsable

  • Parameters

    • executor: E

    Returns Promise<boolean>

  • Parameters

    • actionApiOrExecutor: E | IActionApi<E, CU>
    • Rest ...args: AV

    Returns R | Promise<R>

  • Parameters

    Returns Promise<boolean>

  • Parameters

    • executor: E
    • Rest ...args: AV

    Returns undefined | IActionExample

  • Returns the items registered for this action via addItems.

    Returns readonly default[]

  • Parameters

    Returns void

  • Check if a creature on a tile and blocking the execution of the action

    Returns

    When checking before the action is being executed: true if a creature is on a tile and that creature is not hidden, false otherwise

    When checking when the action is being execute true if a creature is on a tile, false otherwise

    Parameters

    Returns boolean

  • Removes all items added via addItems

    Parameters

    • Rest ...items: (undefined | default)[]

    Returns default<A, E, R, CU, AV>

  • Parameters

    • delay: number
    • Optional replace: boolean

    Returns default<A, E, R, CU, AV>

  • Parameters

    • used: boolean = true

    Returns default<A, E, R, CU, AV>

  • Parameters

    • updateFov: boolean = false

    Returns default<A, E, R, CU, AV>

  • Returns default<A, E, R, CU, AV>

  • Gets an action by its description. If you're using the Action class for constructing the descriptions, just pass the action instance.

    Note: Prefer IActionApi.get if you're calling this from within another action.

    Type Parameters

    Parameters

    • action: D

    Returns D extends IActionDescription<A, E, R, CU, AV> ? default<A, E, R, CU, AV> : never

Generated using TypeDoc