Pathfinder 1e for Foundry VTT
    Preparing search index...

    Base item

    From which all other item documents inherit from.

    Hierarchy (View Summary)

    Index

    Constructors

    • Parameters

      • data: CreateData

        Initial data from which to construct the Item

      • Optionalcontext: ConstructionContext

        Construction context options

      Returns ItemBasePF

    Accessors

    • get isActive(): boolean

      Is the item is fully functional.

      This returns composite result of if the item is equipped, has quantity, is not disabled, is not out of charges, etc. and is not representative if the item can be set active or not via setActive.

      Returns boolean

    Methods

    • For supporting actions and changes in fromUuid()

      Synced with Foundry v12.331

      Parameters

      • embeddedName: any
      • id: any
      • options: any

      Returns any

    • Item name

      Parameters

      • OptionalforcePlayerPerspective: boolean = false

        If true, return value players see.

      Returns string

      • Item name
    • Prepare a data object which defines the data schema used by dice roll commands against this Item

      Parameters

      • options: any

      Returns any

      defaults to this.system, but provided as object for flexible overrides

    • Set item's active state.

      Parameters

      • active: boolean

        Active state

      • Optionalcontext: object

        Optional update context

      Returns Promise<ItemBasePF>

      • Update promise if item type supports the operation.
      • If item does not support the operation.
    • Internal

      Collect information on supplemental items and create them

      Parameters

      • items: Item<"base" | ModuleSubType>[]

        Array of items to draw supplemental data from

      • actor: Actor<"base" | ModuleSubType>

        Owner

      Returns Promise<void>

    • On-Create Operation

      Post-create processing so awaiting the original operation has all secondary updates completed when it returns.

      Parameters

      • documents: Document[]

        Documents

      • operation: any

        Operations and context data

      • user: User

        Triggering user

      Returns Promise<void>

    • On-Delete Operation

      Post-delete processing so awaiting the original operation has all secondary updates completed when it returns.

      Parameters

      • documents: Document[]

        Documents

      • operation: any

        Operations and context data

      • user: User

        Triggering user

      Returns Promise<void>

    • On-Update Operation

      Post-update processing so awaiting the original operation has all secondary updates completed when it returns.

      Parameters

      • documents: Document[]

        Documents

      • operation: any

        Operations and context data

      • user: User

        Triggering user

      Returns Promise<void>

    • Item create dialog.

      Parameters

      • data: object = {}

        Initial item data

      • createOptions: {} = {}
      • __namedParameters: {} = {}

      Returns Promise<null | Item<"base" | ModuleSubType>>

      Synchronized with Foundry VTT v13.347

    • Override to provide naming by subType potential.

      Parameters

      • context: {
            pack?: null | string;
            parent?: null | Document;
            subType?: string;
            type?: string;
        } = {}

        Context where the name would be used

        • Optionalpack?: null | string

          Pack this would be within

        • Optionalparent?: null | Document

          Parent document

        • OptionalsubType?: string

          Document subtype. Nonstandard option.

        • Optionaltype?: string

          Type

      Returns string

      Synced with Foundry v12.331