Levelup Followup (#126)

* Levelup applies bonuses to character

* Added visualisation of domain card levels

* Fixed domaincard level max for selections in a tier

* A trait can now only be level up once within the same tier
This commit is contained in:
WBHarry 2025-06-13 14:15:02 +02:00 committed by GitHub
parent f840dc2553
commit ec3aecfe99
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
23 changed files with 566 additions and 202 deletions

View file

@ -7,19 +7,19 @@
{{#each this.attributes as |attribute key|}}
<div class="attribute">
<div class="attribute-banner">
<img class="attribute-roll" data-action="attributeRoll" data-attribute="{{key}}" data-value="{{attribute.value}}" src="icons/svg/d12-grey.svg" />
<img class="attribute-roll" data-action="attributeRoll" data-attribute="{{key}}" data-value="{{attribute.total}}" src="icons/svg/d12-grey.svg" />
<div class="attribute-text">{{key}}</div>
</div>
<div class="attribute-image">
{{#if ../editAttributes}}
<select class="attribute-value{{#if (lt attribute.value 0)}} negative{{/if}}{{#if (and (not attribute.value) (not ../abilityScoresFinished))}} unselected{{/if}}" data-attribute="{{key}}">
{{#if (not (eq attribute.value 0))}}<option value="">{{attribute.value}}</option>{{/if}}
<select class="attribute-value{{#if (lt attribute.total 0)}} negative{{/if}}{{#if (and (not attribute.total) (not ../abilityScoresFinished))}} unselected{{/if}}" data-attribute="{{key}}">
{{#if (not (eq attribute.total 0))}}<option value="">{{attribute.total}}</option>{{/if}}
{{#each ../abilityScoreArray as |option|}}
<option value="{{option.value}}">{{option.name}}</option>
<option value="{{option.total}}">{{option.name}}</option>
{{/each}}
</select>
{{else}}
<div class="attribute-text {{#if (lt attribute.value 0)}}negative{{/if}}">{{attribute.value}}</div>
<div class="attribute-text {{#if (lt attribute.total 0)}}negative{{/if}}">{{attribute.total}}</div>
{{/if}}
<img src="systems/daggerheart/assets/AttributeShield.svg" />
<div>