Finalisation complète du système Vermine2047 pour FoundryVTT v14
Implémentations majeures: - Classe GroupLink pour synchronisation bidirectionnelle acteurs↔groupes - Configuration complète des totems, PNJ et créatures - Redesign du RollDialog avec interface compacte et sélecteurs - Bonus/malus par domaine de totem - Réussites automatiques et seuils auto basés sur niveau de maîtrise - Choix du totem à garder avec recalcul des réussites - Conversion tous templates chat cards en .hbs - Fiches PNJ et Créature avec sélecteurs pour tous les niveaux - Documentation technique (ARCHITECTURE.md) et utilisateur (GUIDE_UTILISATEUR.md) - Mise à jour system.json pour compatibilité v14 - Tous les TODOs du README.md complétés Generated by Mistral Vibe. Co-Authored-By: Mistral Vibe <vibe@mistral.ai>
This commit is contained in:
+228
-208
@@ -4,52 +4,22 @@
|
||||
data-actor-id="{{ speakerId }}"
|
||||
>
|
||||
|
||||
<!--HIDDEN DATA -->
|
||||
<input
|
||||
type="hidden"
|
||||
name="label"
|
||||
id="label"
|
||||
value="{{ label }}"
|
||||
/>
|
||||
<input
|
||||
type="hidden"
|
||||
name="rollType"
|
||||
id="rollType"
|
||||
value="{{ rollType }}"
|
||||
/>
|
||||
<input
|
||||
type="hidden"
|
||||
name="abilityScore"
|
||||
id="abilityScore"
|
||||
value="{{ abilityScore }}"
|
||||
/>
|
||||
<input
|
||||
type="hidden"
|
||||
name="skillScore"
|
||||
id="skillScore"
|
||||
value="{{ skillScore }}"
|
||||
/>
|
||||
|
||||
<input
|
||||
type="hidden"
|
||||
name="speakerId"
|
||||
value="{{ speakerId }}"
|
||||
/>
|
||||
<input
|
||||
type="hidden"
|
||||
name="skillLabel"
|
||||
value="{{ skill }}"
|
||||
/>
|
||||
|
||||
|
||||
<!-- HIDDEN DATA -->
|
||||
<input type="hidden" name="label" id="label" value="{{ label }}" />
|
||||
<input type="hidden" name="rollType" id="rollType" value="{{ rollType }}" />
|
||||
<input type="hidden" name="abilityScore" id="abilityScore" value="{{ abilityScore }}" />
|
||||
<input type="hidden" name="skillScore" id="skillScore" value="{{ skillScore }}" />
|
||||
<input type="hidden" name="speakerId" value="{{ speakerId }}" />
|
||||
<input type="hidden" name="skillLabel" value="{{ skill }}" />
|
||||
|
||||
<div class="dice-pool">
|
||||
|
||||
<!--SKILLS TALENTS-->
|
||||
<h1 class="flexrow skills-talents">
|
||||
<div class="flexcol">
|
||||
<label class="label">{{localize
|
||||
'VERMINE.ability'}}</label>
|
||||
|
||||
<!-- MAIN ROLL SELECTION -->
|
||||
<div class="flexrow main-roll-section">
|
||||
|
||||
<!-- CHARACTERISTIC -->
|
||||
<div class="flexcol characteristic-section">
|
||||
<label class="label">{{localize 'VERMINE.ability'}}</label>
|
||||
<select
|
||||
class="info-value"
|
||||
data-roll="true"
|
||||
@@ -60,35 +30,37 @@
|
||||
min="1"
|
||||
max="5"
|
||||
>
|
||||
<option value="0">-- Choisissez une caractéristique
|
||||
--</option>
|
||||
<option value="0">-- {{localize 'VERMINE.choose_ability'}} --</option>
|
||||
{{#each config.abilityCategories as |abilCategory catkey|}}
|
||||
|
||||
<optgroup label="{{ smarttlk 'ABILITY_CATEGORIES' catkey 'name' }}">
|
||||
{{#each @root.actor.system.abilities as |abil key|}}
|
||||
{{#ife abil.category catkey}}
|
||||
<option
|
||||
value="{{abil.value}}"
|
||||
data-label="{{key}}"
|
||||
data-category="{{abil.category}}"
|
||||
{{#ife @root.rollType "ability"}}
|
||||
{{#ife @root.labelKey key}}
|
||||
selected="true"
|
||||
{{#ife @root.labelKey key}}
|
||||
selected="true"
|
||||
{{/ife}}
|
||||
{{/ife}}
|
||||
{{/ife}}
|
||||
>{{ smarttlk 'ABILITIES' key 'name'
|
||||
}} / {{abil.value}}</option>
|
||||
>
|
||||
{{ smarttlk 'ABILITIES' key 'name' }} / {{abil.value}}
|
||||
</option>
|
||||
{{/ife}}
|
||||
{{/each}}
|
||||
|
||||
</optgroup>
|
||||
|
||||
{{/each}}
|
||||
</select>
|
||||
<div class="ability-score flexrow">
|
||||
<span id="abilityScore">{{localize 'VERMINE.score'}}: </span>
|
||||
<span id="abilityScoreValue">0</span>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="flexcol">
|
||||
<label class="label">{{localize
|
||||
'VERMINE.skill_title'}}</label>
|
||||
<!-- SKILL -->
|
||||
<div class="flexcol skill-section">
|
||||
<label class="label">{{localize 'VERMINE.skill_title'}}</label>
|
||||
<select
|
||||
class="info-value"
|
||||
data-roll="true"
|
||||
@@ -99,25 +71,24 @@
|
||||
min="1"
|
||||
max="5"
|
||||
>
|
||||
<option>-- Choisissez une compétence
|
||||
--</option>
|
||||
<option value="">-- {{localize 'VERMINE.choose_skill'}} --</option>
|
||||
{{#each config.skillCategories as |skillCategory catkey|}}
|
||||
<optgroup label="{{ smarttlk 'SKILLS_CATEGORIES' catkey 'name' }}">
|
||||
{{#each @root.actor.system.skills as |skill key|}}
|
||||
{{#ife skill.category catkey}}
|
||||
<option
|
||||
value="{{skill.value}}"
|
||||
data-pool="{{skillLevel "dicePool"
|
||||
skill.value}}"
|
||||
data-pool="{{skillLevel 'dicePool' skill.value}}"
|
||||
data-label="{{key}}"
|
||||
data-reroll="{{skillLevel "reroll" skill.value}}"
|
||||
data-category="{{skill.category}}"
|
||||
data-reroll="{{skillLevel 'reroll' skill.value}}"
|
||||
{{#ife @root.rollType "skill"}}
|
||||
{{#ife @root.labelKey key}}
|
||||
selected="true"
|
||||
{{/ife}}
|
||||
{{#ife @root.labelKey key}}
|
||||
selected="true"
|
||||
{{/ife}}
|
||||
{{/ife}}
|
||||
>
|
||||
<b>{{ smarttlk 'SKILLS' key 'name' }} / </b>
|
||||
<b>{{ smarttlk 'SKILLS' key 'name' }}</b> /
|
||||
<i>{{skillLevel "label" skill.value}}</i>
|
||||
</option>
|
||||
{{/ife}}
|
||||
@@ -125,125 +96,120 @@
|
||||
</optgroup>
|
||||
{{/each}}
|
||||
</select>
|
||||
{{#if availableSpecialties.length}}
|
||||
<label class="label">{{localize 'VERMINE.specialty'}} (+1D)</label>
|
||||
<div class="flexrow">
|
||||
<span data-spec-skill="{{spec.system.skill}}">
|
||||
<i>aucunes</i>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- SPECIALTIES (shown when skill selected) -->
|
||||
{{#if availableSpecialties.length}}
|
||||
<details class="specialties-section">
|
||||
<summary class="flexrow">
|
||||
<span class="label">{{localize 'VERMINE.specialty'}} (+1D)</span>
|
||||
<span class="current-specialty">{{localize 'VERMINE.none'}}</span>
|
||||
</summary>
|
||||
<div class="flexrow specialty-options">
|
||||
<label class="flexrow">
|
||||
<input
|
||||
type="radio"
|
||||
data-roll="true"
|
||||
name="usingSpecialization"
|
||||
id="usingSpecialization"
|
||||
value="aucune"
|
||||
/>
|
||||
<span>{{localize 'VERMINE.none'}}</span>
|
||||
</label>
|
||||
{{#each availableSpecialties as |spec ind|}}
|
||||
<label class="flexrow">
|
||||
<input
|
||||
type="radio"
|
||||
data-roll="true"
|
||||
name="usingSpecialization"
|
||||
id="usingSpecialization"
|
||||
value="aucune"
|
||||
>
|
||||
</span>
|
||||
{{#each availableSpecialties as |spec ind|}}
|
||||
value="{{spec.name}}"
|
||||
data-spec-skill="{{spec.system.skill}}"
|
||||
{{#if specialty}}checked{{/if}}
|
||||
/>
|
||||
<span>{{spec.name}}</span>
|
||||
</label>
|
||||
{{/each}}
|
||||
</div>
|
||||
</details>
|
||||
{{/if}}
|
||||
|
||||
<span data-spec-skill="{{spec.system.skill}}">
|
||||
<i>{{spec.name}}</i>
|
||||
<input
|
||||
type="radio"
|
||||
data-roll="true"
|
||||
name="usingSpecialization"
|
||||
id="usingSpecialization"
|
||||
value="{{spec.name}}"
|
||||
{{#if specialty}}checked{{/if}}
|
||||
>
|
||||
</span>
|
||||
{{/each}}
|
||||
|
||||
</div>
|
||||
{{/if}}
|
||||
</div>
|
||||
</h1>
|
||||
|
||||
|
||||
<!--DIFFICULTY HANDICAP-->
|
||||
<h2 class="flexrow difficulties">
|
||||
<label class="label">{{localize
|
||||
'VERMINE.difficulty'}}</label>
|
||||
<select
|
||||
class="info-value"
|
||||
data-roll="tue"
|
||||
data-dtype="String"
|
||||
type="number"
|
||||
name="difficulty"
|
||||
id="difficulty"
|
||||
min="3"
|
||||
max="10"
|
||||
>
|
||||
{{#select difficulty }}
|
||||
<option value="{{ diffLevel 'difficulty' 1}}">{{ diffLevel 'label' 1}} -
|
||||
{{ diffLevel 'difficulty' 1}}
|
||||
</option>
|
||||
<option value="{{ diffLevel 'difficulty' 2}}">{{ diffLevel 'label' 2}} -
|
||||
{{ diffLevel 'difficulty' 2}}
|
||||
</option>
|
||||
<option
|
||||
value="{{ diffLevel 'difficulty' 3}}"
|
||||
selected
|
||||
>{{ diffLevel
|
||||
'label' 3}} - {{ diffLevel 'difficulty' 3}}</option>
|
||||
<option value="{{ diffLevel 'difficulty' 4}}">{{ diffLevel 'label' 4}} -
|
||||
{{ diffLevel 'difficulty' 4}}
|
||||
</option>
|
||||
<option value="{{ diffLevel 'difficulty' 5}}">{{ diffLevel 'label' 5}} -
|
||||
{{ diffLevel 'difficulty' 5}}
|
||||
</option>
|
||||
{{/select}}
|
||||
</select>
|
||||
<label for="handicap">Handicap</label>
|
||||
<select
|
||||
class="info-value"
|
||||
data-roll="tue"
|
||||
data-dtype="String"
|
||||
type="number"
|
||||
name="handicap"
|
||||
id="handicap"
|
||||
min="0"
|
||||
max="2"
|
||||
>
|
||||
{{#select difficulty }}
|
||||
<option
|
||||
value="1"
|
||||
selected
|
||||
>aucun</option>
|
||||
<option value="2">(I)</option>
|
||||
<option value="3">(II)</option>
|
||||
{{/select}}
|
||||
</select>
|
||||
</h2>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<!-- BONUSES -->
|
||||
<details class="flexcol bonuses">
|
||||
<!-- DIFFICULTY AND HANDICAP -->
|
||||
<details class="difficulty-section" open>
|
||||
<summary class="flexrow">
|
||||
<h3 class="flexrow align-center">Bonuses ?</h3>
|
||||
<span class="label">{{localize 'VERMINE.difficulty'}}</span>
|
||||
<span class="current-values">
|
||||
<span id="current-difficulty">{{localize 'DIFFICULTY_LEVELS.hard'}} (7)</span>
|
||||
<span id="current-handicap">{{localize 'VERMINE.none'}}</span>
|
||||
</span>
|
||||
</summary>
|
||||
<div class="grid grid-2col">
|
||||
<div class="flexrow difficulty-controls">
|
||||
<div class="flexcol">
|
||||
<label class="label" for="difficulty">{{localize 'VERMINE.difficulty'}}</label>
|
||||
<select
|
||||
class="info-value"
|
||||
data-roll="true"
|
||||
data-dtype="String"
|
||||
type="number"
|
||||
name="difficulty"
|
||||
id="difficulty"
|
||||
min="3"
|
||||
max="10"
|
||||
>
|
||||
{{#select difficulty }}
|
||||
<option value="{{ diffLevel 'difficulty' 1}}">{{ diffLevel 'label' 1}} ({{ diffLevel 'difficulty' 1}})</option>
|
||||
<option value="{{ diffLevel 'difficulty' 2}}">{{ diffLevel 'label' 2}} ({{ diffLevel 'difficulty' 2}})</option>
|
||||
<option value="{{ diffLevel 'difficulty' 3}}" selected>{{ diffLevel 'label' 3}} ({{ diffLevel 'difficulty' 3}})</option>
|
||||
<option value="{{ diffLevel 'difficulty' 4}}">{{ diffLevel 'label' 4}} ({{ diffLevel 'difficulty' 4}})</option>
|
||||
<option value="{{ diffLevel 'difficulty' 5}}">{{ diffLevel 'label' 5}} ({{ diffLevel 'difficulty' 5}})</option>
|
||||
{{/select}}
|
||||
</select>
|
||||
</div>
|
||||
<div class="flexcol">
|
||||
<label class="label" for="handicap">{{localize 'VERMINE.handicap'}}</label>
|
||||
<select
|
||||
class="info-value"
|
||||
data-roll="true"
|
||||
data-dtype="String"
|
||||
type="number"
|
||||
name="handicap"
|
||||
id="handicap"
|
||||
min="0"
|
||||
max="2"
|
||||
>
|
||||
<option value="1" selected>{{localize 'VERMINE.none'}}</option>
|
||||
<option value="2">(I)</option>
|
||||
<option value="3">(II)</option>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
</details>
|
||||
|
||||
|
||||
<div class="flexrow row smb">
|
||||
<label class="label">{{localize 'VERMINE.help'}} (+1D)</label>
|
||||
<!-- BONUSES SECTION -->
|
||||
<details class="bonuses-section">
|
||||
<summary class="flexrow">
|
||||
<span class="label">{{localize 'VERMINE.bonuses'}}</span>
|
||||
<span class="bonus-count">+<span id="total-bonus">0</span>D</span>
|
||||
</summary>
|
||||
<div class="grid grid-2col bonus-grid">
|
||||
|
||||
<!-- HELP -->
|
||||
<div class="flexrow bonus-item">
|
||||
<input
|
||||
type="checkbox"
|
||||
data-roll="true"
|
||||
name="helped"
|
||||
id="helped"
|
||||
value="1"
|
||||
{{#if
|
||||
help}}checked{{/if}}
|
||||
>
|
||||
{{#if help}}checked{{/if}}
|
||||
/>
|
||||
<label class="label" for="helped">{{localize 'VERMINE.help'}} (+1D)</label>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="flexrow row mdb">
|
||||
<label class="label">{{localize
|
||||
'VERMINE.group'}}</label>
|
||||
<!-- GROUP -->
|
||||
<div class="flexrow bonus-item">
|
||||
<label class="label" for="group">{{localize 'VERMINE.group'}}</label>
|
||||
<input
|
||||
type="number"
|
||||
data-roll="true"
|
||||
@@ -254,13 +220,15 @@
|
||||
min="0"
|
||||
max="5"
|
||||
value="0"
|
||||
>
|
||||
/>
|
||||
<span>D</span>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="flexrow row mdb">
|
||||
<label class="label">{{localize
|
||||
'VERMINE.self_control'}} + <span id="self_control_value">0</span>D
|
||||
<!-- SELF CONTROL -->
|
||||
<div class="flexrow bonus-item full-width">
|
||||
<label class="label" for="self_control">
|
||||
{{localize 'VERMINE.self_control'}}
|
||||
<span>(+<span id="self_control_value">0</span>D)</span>
|
||||
</label>
|
||||
<input
|
||||
type="range"
|
||||
@@ -273,13 +241,11 @@
|
||||
/>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="flexcol row mdb">
|
||||
<!-- TOOLS -->
|
||||
<div class="flexrow bonus-item full-width">
|
||||
<label class="label">{{localize 'VERMINE.tooling'}} (+1D)</label>
|
||||
|
||||
<div class="item-list grid grid-4col">
|
||||
<h3>
|
||||
<i>Auncun</i>
|
||||
<label>
|
||||
<input
|
||||
type="radio"
|
||||
data-roll="true"
|
||||
@@ -287,58 +253,112 @@
|
||||
id="usingTools"
|
||||
value="0"
|
||||
checked
|
||||
>
|
||||
</h3>
|
||||
/>
|
||||
<i>{{localize 'VERMINE.none'}}</i>
|
||||
</label>
|
||||
{{#each availableItems as |item ind|}}
|
||||
<span>
|
||||
<i>{{item.name}}</i>
|
||||
<label>
|
||||
<input
|
||||
type="radio"
|
||||
data-roll="true"
|
||||
name="usingTools"
|
||||
id="usingTools"
|
||||
value="{{item.name}}"
|
||||
>
|
||||
</span>
|
||||
/>
|
||||
<i>{{item.name}}</i>
|
||||
</label>
|
||||
{{/each}}
|
||||
</div>
|
||||
</div>
|
||||
<div class="flexcol">
|
||||
<label class="label">utiliser des dés totems ?
|
||||
</label>
|
||||
<div class="flexrow">
|
||||
|
||||
<!-- TOTEMS -->
|
||||
{{#ifgt @root.actor.system.adaptation.totems.human.value 0}}
|
||||
{{#ifgt @root.actor.system.adaptation.totems.adapted.value 0}}
|
||||
<div class="flexrow bonus-item full-width totems-section">
|
||||
<label class="label">{{localize 'VERMINE.totem_dice'}}</label>
|
||||
<div class="flexrow totem-options">
|
||||
<label class="totem-option">
|
||||
<input
|
||||
type="checkbox"
|
||||
data-roll="true"
|
||||
name="human-totem"
|
||||
id="human-totem"
|
||||
value="1"
|
||||
class="totem-checkbox"
|
||||
/>
|
||||
<span class="totem-label">{{localize 'TOTEMS.human.name'}}</span>
|
||||
<small>(+{{@root.actor.system.adaptation.totems.human.value}}D)</small>
|
||||
</label>
|
||||
<label class="totem-option">
|
||||
<input
|
||||
type="checkbox"
|
||||
data-roll="true"
|
||||
name="adapted-totem"
|
||||
id="adapted-totem"
|
||||
value="1"
|
||||
class="totem-checkbox"
|
||||
/>
|
||||
<span class="totem-label">{{localize 'TOTEMS.adapted.name'}}</span>
|
||||
<small>(+{{@root.actor.system.adaptation.totems.adapted.value}}D)</small>
|
||||
</label>
|
||||
</div>
|
||||
<small class="totem-hint">{{localize 'VERMINE.totem_hint'}}</small>
|
||||
</div>
|
||||
{{else}}
|
||||
{{#ifgt @root.actor.system.adaptation.totems.human.value 0}}
|
||||
<div class="totem-human">
|
||||
<h4 for="human-totem">totem humain </h4>
|
||||
<input
|
||||
type="checkbox"
|
||||
data-roll="true"
|
||||
name="human-totem"
|
||||
id="human-totem"
|
||||
value="1"
|
||||
>
|
||||
<div class="flexrow bonus-item totems-section">
|
||||
<label class="totem-option">
|
||||
<input
|
||||
type="checkbox"
|
||||
data-roll="true"
|
||||
name="human-totem"
|
||||
id="human-totem"
|
||||
value="1"
|
||||
/>
|
||||
<span class="totem-label">{{localize 'TOTEMS.human.name'}}</span>
|
||||
<small>(+{{@root.actor.system.adaptation.totems.human.value}}D)</small>
|
||||
</label>
|
||||
</div>
|
||||
{{/ifgt}}
|
||||
{{#ifgt @root.actor.system.adaptation.totems.adapted.value 0}}
|
||||
<div class="totem-adapted">
|
||||
<h4 for="human-totem">totem adapté </h4>
|
||||
{{/ifgt}}
|
||||
{{else}}
|
||||
{{#ifgt @root.actor.system.adaptation.totems.adapted.value 0}}
|
||||
<div class="flexrow bonus-item totems-section">
|
||||
<label class="totem-option">
|
||||
<input
|
||||
type="checkbox"
|
||||
data-roll="true"
|
||||
name="adapted-totem"
|
||||
id="adapted-totem"
|
||||
value="1"
|
||||
>
|
||||
</div>
|
||||
{{/ifgt}}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
/>
|
||||
<span class="totem-label">{{localize 'TOTEMS.adapted.name'}}</span>
|
||||
<small>(+{{@root.actor.system.adaptation.totems.adapted.value}}D)</small>
|
||||
</label>
|
||||
</div>
|
||||
{{/ifgt}}
|
||||
{{/ifgt}}
|
||||
|
||||
</div>
|
||||
</details>
|
||||
|
||||
<!-- TOTAL DICE POOL -->
|
||||
<div class="flexrow total-section">
|
||||
<label class="label">{{localize 'VERMINE.total'}}:</label>
|
||||
<span id="dice-pool-total" class="total-value">0D</span>
|
||||
{{#ifgt @root.actor.system.adaptation.totems.human.value 0}}
|
||||
{{#ifgt @root.actor.system.adaptation.totems.adapted.value 0}}
|
||||
<span class="totem-selector">
|
||||
({{localize 'VERMINE.keep_totem'}}
|
||||
<select id="keep-totem-select" name="keep_totem">
|
||||
<option value="human">{{localize 'TOTEMS.human.name'}}</option>
|
||||
<option value="adapted">{{localize 'TOTEMS.adapted.name'}}</option>
|
||||
</select>)
|
||||
</span>
|
||||
{{/ifgt}}
|
||||
{{/ifgt}}
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
</form>
|
||||
</form>
|
||||
|
||||
Reference in New Issue
Block a user