mirror of
https://github.com/Foundryborne/daggerheart.git
synced 2026-07-22 02:19:54 +02:00
feat: add resource automatic cost modification on attack or action
Signed-off-by: Gergely Brautigam <182850+Skarlso@users.noreply.github.com>
This commit is contained in:
parent
eccab6ad64
commit
e9e8d2bd59
7 changed files with 25 additions and 4 deletions
|
|
@ -5,6 +5,9 @@ export default class WeaponSheet extends ItemAttachmentSheet(DHBaseItemSheet) {
|
|||
/**@inheritdoc */
|
||||
static DEFAULT_OPTIONS = {
|
||||
classes: ['weapon'],
|
||||
actions: {
|
||||
configureAttack: WeaponSheet.#configureAttack
|
||||
},
|
||||
tagifyConfigs: [
|
||||
{
|
||||
selector: '.features-input',
|
||||
|
|
@ -46,6 +49,13 @@ export default class WeaponSheet extends ItemAttachmentSheet(DHBaseItemSheet) {
|
|||
return context;
|
||||
}
|
||||
|
||||
/**
|
||||
* Open the action configuration sheet for the weapon's base attack.
|
||||
*/
|
||||
static #configureAttack() {
|
||||
this.document.system.attack.sheet.render({ force: true });
|
||||
}
|
||||
|
||||
/**
|
||||
* Callback function used by `tagifyElement`.
|
||||
* @param {Array<Object>} selectedOptions - The currently selected tag objects.
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue