Current Target Save & Action without roll chat message (#528)

This commit is contained in:
Dapoulp 2025-08-02 21:29:11 +02:00 committed by GitHub
parent 73a19fc0bb
commit 2f39e04da5
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
14 changed files with 224 additions and 205 deletions

View file

@ -1,13 +1,13 @@
<div class="roll-part target-section dice-roll" data-action="expandRoll">
<div class="roll-part-header"><div><span>Target</span></div></div>
{{#if (and targets.length (or (or (gt targetShort.hit 0) (gt targetShort.miss 0)) (and hasSave pendingSaves)))}}
{{#if (or (and targets.length (or (gt targetShort.hit 0) (gt targetShort.miss 0))) (and hasSave pendingSaves))}}
<div class="roll-part-extra on-reduced">
<div class="wrapper">
{{#if (or (gt targetShort.hit 0) (gt targetShort.miss 0))}}
<div class="target-hit-status">{{targetShort.hit}} {{#if (gt targetShort.hit 1)}}{{localize "DAGGERHEART.GENERAL.hit.single"}}{{else}}{{localize "DAGGERHEART.GENERAL.hit.plural"}}{{/if}}</div>
<div class="target-hit-status is-miss">{{targetShort.miss}} {{#if (gt targetShort.miss 1)}}{{localize "DAGGERHEART.GENERAL.miss.single"}}{{else}}{{localize "DAGGERHEART.GENERAL.miss.plural"}}{{/if}}</div>
{{/if}}
{{#if (and hasSave pendingSaves)}}<div class="target-pending-saves{{#if hasRoll}} is-absolute{{/if}}" data-tooltip="{{localize "DAGGERHEART.UI.Tooltip.pendingSaves"}}" data-tooltip-direction="UP"><i class="fa-solid fa-shield fa-lg fa-beat"></i></div>{{/if}}
{{#if (and hasSave pendingSaves)}}<div class="target-pending-saves" data-tooltip="{{localize "DAGGERHEART.UI.Tooltip.pendingSaves"}}" data-tooltip-direction="UP"><i class="fa-solid fa-shield fa-lg fa-beat"></i></div>{{/if}}
</div>
</div>
{{/if}}
@ -24,7 +24,7 @@
<div class="roll-part-header"><div></div></div>
</div>
{{/if}}
{{#if (and hasSave @root.targetSelection pendingSaves)}}<div class="roll-part-extra roll-all-save-button">Reaction Roll All Targets<i class="fa-solid fa-shield fa-lg"></i></div>{{/if}}
{{#if (and hasSave currentTargets.length)}}<div class="roll-part-extra roll-all-save-button">Reaction Roll All Targets<i class="fa-solid fa-shield fa-lg"></i></div>{{/if}}
{{#each currentTargets}}
<div class="roll-target" data-token="{{id}}">
<img class="target-img" src="{{img}}">
@ -40,7 +40,7 @@
</div>
{{/if}}
</div>
{{#if (and ../hasSave hit @root.targetSelection)}}
{{#if (and ../hasSave (or hit (not @root.targetSelection)))}}
<div class="target-save{{#if saved.result includeZero=true}} is-rolled{{/if}}" data-perm-id="{{actorId}}">
<i class="fa-solid {{#if saved.result includeZero=true}}{{#if saved.success}}fa-check{{else}}fa-xmark{{/if}}{{else}}fa-shield{{/if}} fa-lg"></i>
</div>