OptionalarmorOptionalchangeOptionalchangesCaster Level
OptionalcontextOptionallanguagesOptionalpriceOptionalshowShow item in combat tab.
OptionalshowDisplay item and its actions in quick actions and token HUD.
OptionalsubOptionaltagOptionalweaponOptionalcontents?: numberWeight of contained items and currency, in lbs
Weight of this item, converted to the current unit system
Optionalcurrency?: numberEffective weight of contained currency for containers, in lbs
The effective total weight of the item (including quantity and contents), in lbs
The weight of a single item instance, in lbs
Active state as per what setActive would correspond with.
The item's material addons.
Consumes are adds charges by default.
Base material
Can equip currently?
Is this item usable at base level, disregarding per-action details.
ExperimentalRemaining charges
The default spell school of this items aura, if any
Effective caster level of this item.
Finite charges
Is Active
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.
Broken state
Tests both explicit broken override and current health.
Is the item destroyed?
AbstractisIs this a physical item?
AbstractisThe item's actual material.
Should current user see identified info
StaticisIs this a physical item?
Internal ExperimentalReturn active state change from data if present
This is a hack to allow item-type agnostic active state change detection.
InternalHandle charge update sanity checking, constraining them to reasonable values, and propagating to parent items if charges are shared.
Changed data
Context
InternalFinalize data after actor and other items are ready.
Called at end of Item#prepareDerivedData() which is after TypeDataModel#prepareDerivedData()
Protected_ProtectedFinalize weight calculation effects
Protected_ProtectedDescription Data
Required to be async due to spell associated class map building.
Additional options
OptionalactionId?: stringID of an action. Default action is used if undefined.
Optionalisolated?: booleanInclude extra data to reflect it not being so easily available in context.
OptionalrollData?: objectRoll data instance
Prepare data dependent on other items
Called in actor.prepareDerivedData() when all items are guaranteed to be prepared.
InternalProtected_ProtectedPrepare this item's WeightData
Protected_ProtectedUpdate action limited uses
{@inheritDoc ItemPF.recharge}
TODO: Move this to the action itself.
Options
Exact time period only
Optionalperiod?: stringRecharge only if matching this time period
OptionalrollData?: objectRoll data
Protected_ProtectedRecharges item's uses, if any.
Options
Optionalexact?: booleanMatch only exact time period
Optionalmaximize?: booleanMaximize instead of using recharge formula
Optionalperiod?: stringRecharge only if it matches this time period
OptionalrollData?: objectRoll data instance
Optionalvalue?: numberSet charges to specific value
Reset charges when quantity is changed to simulate a stack.
Changed data
InternalAdjust HP value by item size.
In reference to rules established at Table 7-12 of CRB p. 175
InternalUpdate Charge Linking
InternalUpdate this item's charges based on provided item.
Charge source
ProtectedgetProtectedGenerates ChatData for this item, either in a default configuration or for a specific action.
Optionaloptions: {Options affecting how descriptions are enriched.
OptionalactionId?: stringThe ID of an action on this item to generate chat data for, defaults to ItemPF.defaultAction
Optionalbody?: booleanInclude main description
Optionalchatcard?: booleanIs this actually for chat card.
Optionalextended?: booleanInclude extended information that may not be useful in all circumstances.
Optionalfooter?: booleanInclude footer if it exists
Optionalheader?: booleanInclude header if it exists
Optionalinteractive?: booleanWas this from user interaction (allowing farther interactions)
OptionalrollData?: objectDefaults to Action#getRollData/ItemPF#getRollData.
The chat data for this item (+action)
AbstractgetItem model specific conditional targets.
Key to target mapping.
Return cost multiplier affecting this item.
Such as item size dictating how costly an armor is.
Get default charge cost for all actions.
Optionaloptions: { rollData?: object } = {}Additional options
OptionalrollData?: objectRoll data instance
Number for default cost.
Default charge formula.
Get full description.
Item type dependant options for rendering the description.
Visible item name
If true, return value players see.
AbstractgetDataModel specific roll data
Roll data
Returns the displayed value of an item according to multiple options
Optionaloptions: {Various optional parameters affecting value calculations
Optionalbase?: booleanReturn only base value. This forces single & maximized to true.
OptionalforceUnidentified?: booleanOverride whether the value should use the unidentified price
Optionalidentical?: booleanTreat all items in stack as identical (same number of charges).
OptionalinLowestDenomination?: booleanWhether the value should be returned in the lowest denomination. Standard denomination otherwise.
Optionalmaximized?: booleanPretend as if the items were fresh (full charges)
Optionalrecursive?: booleanWhether the value of contained items should be included
Optionalsell?: booleanReturn estimated sell value instead of actual value.
Optionalsingle?: booleanReturn value of singular item instead of the actual stack. Disables recursive option.
Optionaltype?: "resale" | nullType of value to return. Default is full value if not specified.
The item's value
Return weight multiplier affecting this item.
Such as item size dictating how heavy an armor is.
InternalPrepare hardness and hit points
Recharges item's uses, if any.
Options
Optionalcommit?: booleanCommit update directly. If false, returns the update data instead.
Optionalcontext?: objectUpdate context
Optionalexact?: booleanUse exact time period. Otherwise "week" for example will also recharge items with "day" period.
Optionalmaximize?: booleanRecharge to full regardless of recharge formula.
Optionalperiod?: "round" | "minute" | "hour" | "day" | "week" | "any"Recharge period. Use "any" to ignore item's configuration.
OptionalrollData?: objectRoll data instance to use for formulas.
Optionalvalue?: numberRecharge to specific value, respecting maximum and minimum bounds.
Protected Static Abstract_ProtectedAdjust temporary item before creation
Optionalitem: ItemPF<BaseItemModel>Temporary document
Optionaldata: objectCreation data
Optionaloverride: boolean = falseOverride values even if defined
Static AbstractmigrateParent datamodel (item document) migration
AVOID USING THIS
Document source data
Staticprune
Abstract model for physical items.