diff --git a/module/data/fields/actorField.mjs b/module/data/fields/actorField.mjs index 1399fb32..76c24319 100644 --- a/module/data/fields/actorField.mjs +++ b/module/data/fields/actorField.mjs @@ -82,6 +82,24 @@ class ResourcesField extends fields.TypedObjectField { } return data; } + + /** + * Foundry bar attributes are unable to handle finding the schema field nor the label normally. + * This returns the element if its a valid resource key and overwrites the element's label for that retrieval. + */ + _getField(path) { + if ( path.length === 0 ) return this; + const first = path.shift(); + if (first === this.element.name) return this.element_getField(path); + + const resources = CONFIG.DH.RESOURCE[this.actorType].all; + if (first in resources) { + this.element.label = resources[first].label; + return this.element._getField(path); + } + + return undefined; + } } export { attributeField, ResourcesField, stressDamageReductionRule, bonusField }; diff --git a/src/packs/items/weapons/weapon_Knuckle_Blades_U8gfyvxoHm024inM.json b/src/packs/items/weapons/weapon_Knuckle_Blades_U8gfyvxoHm024inM.json index 6bc27412..a5d00ff4 100644 --- a/src/packs/items/weapons/weapon_Knuckle_Blades_U8gfyvxoHm024inM.json +++ b/src/packs/items/weapons/weapon_Knuckle_Blades_U8gfyvxoHm024inM.json @@ -33,7 +33,7 @@ "tier": 2, "equipped": false, "secondary": false, - "burden": "oneHanded", + "burden": "twoHanded", "weaponFeatures": [ { "value": "brutal", diff --git a/system.json b/system.json index b8c4955b..4bd0f863 100644 --- a/system.json +++ b/system.json @@ -2,7 +2,7 @@ "id": "daggerheart", "title": "Daggerheart", "description": "An unofficial implementation of the Daggerheart system", - "version": "1.9.1", + "version": "1.9.2", "compatibility": { "minimum": "13.346", "verified": "13.351", diff --git a/templates/sheets/global/partials/inventory-item-V2.hbs b/templates/sheets/global/partials/inventory-item-V2.hbs index 86d2e2d3..a758a28f 100644 --- a/templates/sheets/global/partials/inventory-item-V2.hbs +++ b/templates/sheets/global/partials/inventory-item-V2.hbs @@ -40,23 +40,20 @@ Parameters: {{!-- Name & Tags --}}