[Feature] Advantage/Disadvantage Tooltips (#362)

* Added advantage/disadvantageSource to Character model. It's shown from a tooltip icon on rolls

* Added support for beastform advantageOn
This commit is contained in:
WBHarry 2025-07-17 19:01:15 +02:00 committed by GitHub
parent ad9e0aa558
commit d7e024be02
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
6 changed files with 36 additions and 0 deletions

View file

@ -98,6 +98,9 @@
<span><i class="fa-regular fa-circle"></i></span>
{{/if}}
<span class="label">{{localize "DAGGERHEART.GENERAL.Advantage.full"}}</span>
{{#if @root.rollConfig.data.advantageSources.length}}
<span class="advantage-chip-tooltip" data-tooltip="{{concat "#advantage#" @root.rollConfig.source.actor}}"><i class="fa-solid fa-circle-info"></i></span>
{{/if}}
</button>
<button class="disadvantage-chip flex1 {{#if (eq advantage -1)}}selected{{/if}}" data-action="updateIsAdvantage" data-advantage="-1">
{{#if (eq advantage -1)}}
@ -106,6 +109,9 @@
<span><i class="fa-regular fa-circle"></i></span>
{{/if}}
<span class="label">{{localize "DAGGERHEART.GENERAL.Disadvantage.full"}}</span>
{{#if @root.rollConfig.data.disadvantageSources.length}}
<span class="advantage-chip-tooltip" data-tooltip="{{concat "#disadvantage#" @root.rollConfig.source.actor}}"><i class="fa-solid fa-circle-info"></i></span>
{{/if}}
</button>
</div>
{{#unless (eq @root.rollType 'D20Roll')}}