Some automatisations on advancements

Added xp cost for technique
This commit is contained in:
Vlyan
2020-12-27 12:19:43 +01:00
parent 65be83dc14
commit c874caec1a
14 changed files with 200 additions and 44 deletions

View File

@@ -8,7 +8,7 @@
{{!-- Attributes Tab --}}
<article class="attributes" data-group="primary" data-tab="attributes">
<!-- TODO j'ai mis tous les attributs en vrac, à réorganiser -->
<select name="data.advancement_type">
<select name="data.advancement_type" id="advancement_type">
{{#select item.data.advancement_type}}
{{#each item.data.subTypesList as |type|}}
<option value="{{type}}">{{type}}</option>
@@ -16,12 +16,8 @@
{{/select}}
</select>
{{#ifCond item.data.advancement_type '==' 'advantage' }}
<!-- TODO zone de drag n drop de l'item sélectionné ? -->
{{/ifCond}}
{{#ifCond item.data.advancement_type '==' 'ring' }}
<select name="data.ring">
<select name="data.ring" id="advancement_ring">
{{#select item.data.ring}}
{{#each item.data.ringsList as |obj|}}
<option value="{{obj.id}}">{{obj.label}}</option>
@@ -31,7 +27,7 @@
{{/ifCond}}
{{#ifCond item.data.advancement_type '==' 'skill' }}
<select name="data.skill">
<select name="data.skill" id="advancement_skill">
<option value="none">{{localize 'l5r5e.twenty_questions.choosef'}}</option>
{{#select item.data.skill}}
{{#each item.data.skillsList as |skills catId|}}

View File

@@ -26,6 +26,10 @@
<input type="checkbox" name="data.in_curriculum" {{checked item.data.in_curriculum}} />
{{ localize 'l5r5e.advancements.curriculum' }}
</label>
<label class="attribute">
{{ localize 'l5r5e.advancements.cost' }}
<input type="text" name="data.xp_cost" value="{{item.data.xp_cost}}" data-dtype="Number" placeholder="0"/>
</label>
<label class="attribute">
{{ localize 'l5r5e.advancements.spent' }}
<input type="text" name="data.xp_used" value="{{item.data.xp_used}}" data-dtype="Number" placeholder="0"/>