Fixed so that saving throw damage mitigation works again (#1555)

This commit is contained in:
WBHarry 2026-01-21 02:52:42 +01:00 committed by GitHub
parent 4ce8fbb84c
commit 6e5d7fb34c
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
3 changed files with 3 additions and 2 deletions

View file

@ -241,6 +241,7 @@ export default class DHBaseAction extends ActionMixin(foundry.abstract.DataModel
hasHealing: this.hasHealing,
hasEffect: this.hasEffect,
hasSave: this.hasSave,
onSave: this.save?.damageMod,
isDirect: !!this.damage?.direct,
selectedRollMode: game.settings.get('core', 'rollMode'),
data: this.getRollData(),

View file

@ -607,7 +607,7 @@ export default class DhpActor extends Actor {
if (!updates.length) return;
const hpDamage = updates.find(u => u.key === CONFIG.DH.GENERAL.healingTypes.hitPoints.id);
if (hpDamage) {
if (hpDamage?.value) {
hpDamage.value = this.convertDamageToThreshold(hpDamage.value);
if (
this.type === 'character' &&

View file

@ -179,7 +179,7 @@ export default class DhpChatMessage extends foundry.documents.ChatMessage {
config = foundry.utils.deepClone(this.system);
config.event = event;
if (this.system.onSave) {
if (config.hasSave) {
const pendingingSaves = targets.filter(t => t.saved.success === null);
if (pendingingSaves.length) {
const confirm = await foundry.applications.api.DialogV2.confirm({