mirror of
https://github.com/Foundryborne/daggerheart.git
synced 2026-01-13 12:11:07 +01:00
Added effects for Weapon and Armor traits
This commit is contained in:
parent
b7ea925276
commit
b8482da848
13 changed files with 573 additions and 51 deletions
|
|
@ -129,7 +129,8 @@ export class DHBaseAction extends foundry.abstract.DataModel {
|
|||
|
||||
async use(event) {
|
||||
if (this.roll.type && this.roll.trait) {
|
||||
const modifierValue = this.actor.system.traits[this.roll.trait].value;
|
||||
const modifierValue =
|
||||
this.actor.system.traits[this.roll.trait].value + (this.actor.system.bonuses.attack ?? 0);
|
||||
const config = {
|
||||
event: event,
|
||||
title: this.item.name,
|
||||
|
|
|
|||
|
|
@ -23,7 +23,7 @@ export class DHActionDiceData extends foundry.abstract.DataModel {
|
|||
getFormula(actor) {
|
||||
return this.custom.enabled
|
||||
? this.custom.formula
|
||||
: `${actor.system[this.multiplier] ?? 1}${this.dice}${this.bonus ? (this.bonus < 0 ? ` - ${Math.abs(this.bonus)}` : ` + ${this.bonus}`) : ''}`;
|
||||
: `${actor.system[this.multiplier]?.total ?? 1}${this.dice}${this.bonus ? (this.bonus < 0 ? ` - ${Math.abs(this.bonus)}` : ` + ${this.bonus}`) : ''}`;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue