diff --git a/src/module/actor/creature/data.ts b/src/module/actor/creature/data.ts index 0686311b94f..5b33e189fa3 100644 --- a/src/module/actor/creature/data.ts +++ b/src/module/actor/creature/data.ts @@ -148,7 +148,7 @@ interface CreatureAttributes extends ActorAttributes { /** The current dying level (and maximum) for this creature. */ dying: ValueAndMax & { recoveryDC: number }; /** The current wounded level (and maximum) for this creature. */ - wounded: ValueAndMax; + wounded: ValueAndMaybeMax; /** The current doomed level (and maximum) for this creature. */ doomed: ValueAndMax; diff --git a/src/module/actor/creature/document.ts b/src/module/actor/creature/document.ts index 4931aba5d71..77f370426c9 100644 --- a/src/module/actor/creature/document.ts +++ b/src/module/actor/creature/document.ts @@ -340,7 +340,7 @@ abstract class CreaturePF2e< attributes.doomed = { value: 0, max: 3 }; attributes.dying = { value: 0, max: 4, recoveryDC: 10 }; - attributes.wounded = { value: 0, max: 3 }; + attributes.wounded = { value: 0 }; // Set IWR guaranteed by traits setImmunitiesFromTraits(this); @@ -437,11 +437,10 @@ abstract class CreaturePF2e< rollOptions.all[`self:size:${sizeSlug}`] = true; // Handle caps derived from dying - attributes.wounded.max = Math.max(0, attributes.dying.max - 1); attributes.doomed.max = attributes.dying.max; // Set dying, doomed, and wounded statuses according to embedded conditions - for (const conditionSlug of ["doomed", "wounded", "dying"] as const) { + for (const conditionSlug of ["doomed", "dying"] as const) { const condition = this.conditions.bySlug(conditionSlug, { active: true }).at(0); const status = attributes[conditionSlug]; if (conditionSlug === "dying") { @@ -449,6 +448,10 @@ abstract class CreaturePF2e< } status.value = Math.min(condition?.value ?? 0, status.max); } + const woundedconditionslug = this.conditions.bySlug("wounded", { active: true }).at(0); + if (woundedconditionslug !== null && woundedconditionslug !== undefined) { + attributes.wounded.value = Math.min(woundedconditionslug.value ?? 0); + } // Clamp certain core resources const resources = this.system.resources; diff --git a/src/module/actor/creature/sheet.ts b/src/module/actor/creature/sheet.ts index 382fb51903b..e586b7efdf0 100644 --- a/src/module/actor/creature/sheet.ts +++ b/src/module/actor/creature/sheet.ts @@ -51,7 +51,6 @@ abstract class CreatureSheetPF2e extends ActorSheet dying: { maxed: actor.attributes.dying.value >= actor.attributes.dying.max, remainingDying: Math.max(actor.attributes.dying.max - actor.attributes.dying.value), - remainingWounded: Math.max(actor.attributes.wounded.max - actor.attributes.wounded.value), }, specialResources: Object.values(this.actor.synthetics.resources).map((r) => R.pick(r, ["slug", "label", "value", "max"]), @@ -506,7 +505,6 @@ interface CreatureSheetData extends ActorSheetDataP dying: { maxed: boolean; remainingDying: number; - remainingWounded: number; }; specialResources: ResourceData[]; } diff --git a/src/module/system/conditions/manager.ts b/src/module/system/conditions/manager.ts index 5fa4255db94..577c713a421 100644 --- a/src/module/system/conditions/manager.ts +++ b/src/module/system/conditions/manager.ts @@ -76,7 +76,7 @@ export class ConditionManager { await condition.delete(); } else if (actor?.isOfType("creature")) { // Cap the value if a capped condition - const cappedConditions = ["dying", "wounded", "doomed"] as const; + const cappedConditions = ["dying", "doomed"] as const; if (tupleHasValue(cappedConditions, condition.slug)) { value = Math.min(value, actor.attributes[condition.slug].max); } diff --git a/src/styles/actor/character/_sidebar.scss b/src/styles/actor/character/_sidebar.scss index a954890dcff..31e5f5462fc 100644 --- a/src/styles/actor/character/_sidebar.scss +++ b/src/styles/actor/character/_sidebar.scss @@ -306,6 +306,9 @@ aside { label { @include micro; } + h3 { + color: var(--text-light); + } i.fa-regular, i.fa-solid { diff --git a/static/templates/actors/character/partials/sidebar.hbs b/static/templates/actors/character/partials/sidebar.hbs index 0fbd53e10b3..96c4781e1b3 100644 --- a/static/templates/actors/character/partials/sidebar.hbs +++ b/static/templates/actors/character/partials/sidebar.hbs @@ -46,10 +46,9 @@ {{localize "PF2E.condition.wounded.name"}} - - {{#times data.attributes.wounded.value}}{{/times}} - {{#times dying.remainingWounded}}{{/times}} - +

+ {{data.attributes.wounded.value}} +