Options
All
  • Public
  • Public/Protected
  • All
Menu

The client-side Macro document which extends the common BaseMacro model.

mixes

ClientDocumentMixin

see

Macros The world-level collection of Macro documents

see

MacroConfig The Macro configuration application

Hierarchy

  • any
    • Macro

Index

Constructors

  • Returns Macro

Accessors

  • get isAuthor(): boolean
  • Is the current User the author of this macro?

    Returns boolean

  • get canExecute(): boolean
  • Test whether the current user is capable of executing a Macro script

    Returns boolean

  • get thumbnail(): string
  • Provide a thumbnail image path used to represent this document.

    Returns string

Methods

  • execute(scope?: { actor: Actor; token: Token }): any
  • Execute the Macro command.

    Parameters

    Returns any

    A created ChatMessage from chat macros or returned value from script macros

  • _onClickDocumentLink(event: any): any
  • inheritdoc

    Parameters

    • event: any

    Returns any

  • #executeChat(): void
  • Execute the command as a chat macro. Chat macros simulate the process of the command being entered into the Chat Log input textarea.

    Returns void

  • #executeScript([scope={}]?: { actor: Actor; token: Token }): any
  • Execute the command as a script macro. Script Macros are wrapped in an async IIFE to allow the use of asynchronous commands and await statements.

    Parameters

    • [scope={}]: { actor: Actor; token: Token } = {}

      Macro execution scope which is passed to script macros

    Returns any