mirror of
https://github.com/Foundryborne/daggerheart.git
synced 2026-07-21 18:09:54 +02:00
Sheet fixes
This commit is contained in:
parent
ce47c63ce6
commit
1f12a98c63
4 changed files with 20 additions and 26 deletions
|
|
@ -73,7 +73,7 @@ export default class DHAttackAction extends DHDamageAction {
|
|||
if (range) labels.push(game.i18n.localize(`DAGGERHEART.CONFIG.Range.${range}.short`));
|
||||
|
||||
const useAltDamage = this.actor?.effects?.find(x => x.type === 'horde')?.active;
|
||||
for (const { value, valueAlt, type } of damage.parts) {
|
||||
for (const { value, valueAlt, type } of [damage.main, ...damage.resources]) {
|
||||
const usedValue = useAltDamage ? valueAlt : value;
|
||||
const damageString = Roll.replaceFormulaData(usedValue.getFormula(), this.actor?.getRollData() ?? {});
|
||||
const str = damageString
|
||||
|
|
|
|||
|
|
@ -84,13 +84,11 @@ export default class DhpAdversary extends DhCreature {
|
|||
type: 'attack'
|
||||
},
|
||||
damage: {
|
||||
parts: {
|
||||
hitPoints: {
|
||||
type: ['physical'],
|
||||
applyTo: 'hitPoints',
|
||||
value: {
|
||||
multiplier: 'flat'
|
||||
}
|
||||
main: {
|
||||
type: ['physical'],
|
||||
applyTo: 'hitPoints',
|
||||
value: {
|
||||
multiplier: 'flat'
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -104,15 +104,13 @@ export default class DhCharacter extends DhCreature {
|
|||
trait: 'strength'
|
||||
},
|
||||
damage: {
|
||||
parts: {
|
||||
hitPoints: {
|
||||
type: ['physical'],
|
||||
applyTo: 'hitPoints',
|
||||
value: {
|
||||
custom: {
|
||||
enabled: true,
|
||||
formula: '@profd4'
|
||||
}
|
||||
main: {
|
||||
type: ['physical'],
|
||||
applyTo: 'hitPoints',
|
||||
value: {
|
||||
custom: {
|
||||
enabled: true,
|
||||
formula: '@profd4'
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -67,13 +67,11 @@ export default class DHWeapon extends AttachableItem {
|
|||
type: 'attack'
|
||||
},
|
||||
damage: {
|
||||
parts: {
|
||||
hitPoints: {
|
||||
type: ['physical'],
|
||||
value: {
|
||||
multiplier: 'prof',
|
||||
dice: 'd8'
|
||||
}
|
||||
main: {
|
||||
type: ['physical'],
|
||||
value: {
|
||||
multiplier: 'prof',
|
||||
dice: 'd8'
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -230,7 +228,7 @@ export default class DHWeapon extends AttachableItem {
|
|||
game.i18n.localize(`DAGGERHEART.CONFIG.Burden.${burden}`)
|
||||
];
|
||||
|
||||
for (const { value, type } of attack.damage.parts) {
|
||||
for (const { value, type } of [attack.damage.main, ...attack.damage.resources]) {
|
||||
const parts = value.custom.enabled ? [game.i18n.localize('DAGGERHEART.GENERAL.custom')] : [value.dice];
|
||||
if (!value.custom.enabled && value.bonus) parts.push(value.bonus.signedString());
|
||||
|
||||
|
|
@ -258,7 +256,7 @@ export default class DHWeapon extends AttachableItem {
|
|||
if (roll.trait) labels.push(game.i18n.localize(`DAGGERHEART.CONFIG.Traits.${roll.trait}.short`));
|
||||
if (range) labels.push(game.i18n.localize(`DAGGERHEART.CONFIG.Range.${range}.short`));
|
||||
|
||||
for (const { value, type } of damage.parts) {
|
||||
for (const { value, type } of [damage.main, ...damage.resources]) {
|
||||
const str = Roll.replaceFormulaData(value.getFormula(), this.actor?.getRollData() ?? {});
|
||||
|
||||
const icons = Array.from(type)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue