This commit is contained in:
Dapoolp 2025-08-16 13:38:03 +02:00
parent 180c4d2a53
commit ed3c4a9da2
4 changed files with 27 additions and 3 deletions

View file

@ -1,6 +1,8 @@
const fields = foundry.data.fields;
export default class EffectsField extends fields.ArrayField {
static order = 100;
constructor(options = {}, context = {}) {
const element = new fields.SchemaField({
_id: new fields.DocumentIdField(),
@ -8,4 +10,14 @@ export default class EffectsField extends fields.ArrayField {
});
super(element, options, context);
}
static async execute(config) {
if(!this.hasRoll) {
const roll = new CONFIG.Dice.daggerheart.DHRoll('');
roll._evaluated = true;
await CONFIG.Dice.daggerheart.DHRoll.toMessage(roll, config);
} else {
return;
}
}
}