mirror of
https://github.com/Foundryborne/daggerheart.git
synced 2026-01-16 13:41:07 +01:00
. (#1545)
This commit is contained in:
parent
78c6f3bf48
commit
d626285a88
1 changed files with 10 additions and 1 deletions
|
|
@ -194,7 +194,16 @@ export default class DhpChatMessage extends foundry.documents.ChatMessage {
|
|||
return ui.notifications.info(game.i18n.localize('DAGGERHEART.UI.Notifications.noTargetsSelectedOrPerm'));
|
||||
|
||||
this.consumeOnSuccess();
|
||||
this.system.action?.workflow.get('applyDamage')?.execute(config, targets, true);
|
||||
if (this.system.action) this.system.action.workflow.get('applyDamage')?.execute(config, targets, true);
|
||||
else {
|
||||
for (const target of targets) {
|
||||
const actor = await foundry.utils.fromUuid(target.actorId);
|
||||
if (!actor) continue;
|
||||
|
||||
if (this.system.hasHealing) actor.takeHealing(this.system.damage);
|
||||
else actor.takeDamage(this.system.damage);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
async onRollSave(event) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue