Fix after testing
This commit is contained in:
@@ -1,145 +1,190 @@
|
||||
<div class="chat-message-header">
|
||||
{{#if actorImg}}
|
||||
<img class="actor-icon" src="{{actorImg}}" alt="{{alias}}" />
|
||||
{{!-- Chat Card for Roll Results --}}
|
||||
<div class="heritiers-chat-card">
|
||||
|
||||
{{!-- Header --}}
|
||||
<div class="chat-card-header">
|
||||
{{#if actorImg}}
|
||||
<img class="chat-actor-avatar" src="{{actorImg}}" alt="{{alias}}" />
|
||||
{{/if}}
|
||||
<div class="chat-actor-info">
|
||||
<h4 class="chat-actor-name">{{alias}}</h4>
|
||||
{{#if competence}}
|
||||
<div class="chat-action-name">{{competence.name}}{{#if arme}} - {{arme.name}}{{/if}}</div>
|
||||
{{else if pouvoir}}
|
||||
<div class="chat-action-name">{{pouvoir.name}}</div>
|
||||
{{else if sort}}
|
||||
<div class="chat-action-name">{{sort.name}}</div>
|
||||
{{else if rang}}
|
||||
<div class="chat-action-name">{{rang.label}}</div>
|
||||
{{else}}
|
||||
<div class="chat-action-name">{{carac.label}}</div>
|
||||
{{/if}}
|
||||
</div>
|
||||
{{#if actionImg}}
|
||||
<img class="chat-action-icon" src="{{actionImg}}" alt="{{name}}" />
|
||||
{{/if}}
|
||||
</div>
|
||||
|
||||
{{!-- Attack Type Badge --}}
|
||||
{{#if attackType}}
|
||||
<div class="chat-attack-badge">{{attackType}}</div>
|
||||
{{/if}}
|
||||
<h4 class=chat-actor-name>{{alias}}</h4>
|
||||
</div>
|
||||
|
||||
<hr>
|
||||
|
||||
{{#if actionImg}}
|
||||
<div>
|
||||
<img class="chat-icon" src="{{actionImg}}" alt="{{name}}" />
|
||||
</div>
|
||||
{{/if}}
|
||||
|
||||
<div class="flexcol">
|
||||
</div>
|
||||
|
||||
<div>
|
||||
<ul>
|
||||
<li class="heritiers-roll"><strong>Caractéristique :</strong> {{carac.label}} ({{carac.value}})</li>
|
||||
|
||||
{{!-- Roll Calculation Grid --}}
|
||||
{{#unless noRoll}}
|
||||
<div class="chat-roll-grid">
|
||||
<div class="chat-roll-item">
|
||||
<span class="chat-roll-label">Carac</span>
|
||||
<span class="chat-roll-value">{{carac.label}} {{carac.value}}</span>
|
||||
</div>
|
||||
|
||||
{{#if rang}}
|
||||
<li><strong>{{rang.label}} :</strong> {{rang.value}}</li>
|
||||
<div class="chat-roll-item">
|
||||
<span class="chat-roll-label">Rang</span>
|
||||
<span class="chat-roll-value">{{rang.value}}</span>
|
||||
</div>
|
||||
{{/if}}
|
||||
|
||||
|
||||
{{#if competence}}
|
||||
<li><strong>Compétence :</strong> {{competence.name}} ({{competence.system.niveau}})</li>
|
||||
<div class="chat-roll-item">
|
||||
<span class="chat-roll-label">Compétence</span>
|
||||
<span class="chat-roll-value">{{competence.name}} {{competence.system.niveau}}</span>
|
||||
</div>
|
||||
{{/if}}
|
||||
|
||||
{{#if useSpecialite}}
|
||||
<li>Bonus de spécialité +1</li>
|
||||
<div class="chat-roll-item">
|
||||
<span class="chat-roll-label">Spécialité</span>
|
||||
<span class="chat-roll-value">+1</span>
|
||||
</div>
|
||||
{{/if}}
|
||||
{{/if}}
|
||||
|
||||
{{#if arme}}
|
||||
<li><strong>Attaque avec : </strong>{{arme.name}}</li>
|
||||
{{#if (eq mode "assommer")}}
|
||||
<li>Attaque pour assommer</li>
|
||||
{{/if}}
|
||||
{{/if}}
|
||||
|
||||
{{#if pouvoir}}
|
||||
<li><strong>Pouvoir</strong> : {{pouvoir.name}}</li>
|
||||
<li><strong>Effet</strong> : {{pouvoir.system.effet}}</li>
|
||||
{{#if (ne pouvoir.system.duree "")}}
|
||||
<li><strong>Durée :</strong> {{pouvoir.system.duree}}</li>
|
||||
{{/if}}
|
||||
{{#if (ne pouvoir.system.portee "")}}
|
||||
<li><strong>Portée :</strong> {{pouvoir.system.portee}}</li>
|
||||
{{/if}}
|
||||
{{#if (ne pouvoir.system.resistance "")}}
|
||||
<li><strong>Résistance :</strong> {{pouvoir.system.resistance}}</li>
|
||||
{{/if}}
|
||||
{{#if (ne pouvoir.system.resistanceautre "")}}
|
||||
<li><strong>Résistance autre :</strong> {{pouvoir.system.resistanceautre}}</li>
|
||||
{{/if}}
|
||||
{{#if (ne pouvoir.system.zoneeffet "")}}
|
||||
<li><strong>Zone d'effet :</strong> {{pouvoir.system.zoneeffet}}</li>
|
||||
{{/if}}
|
||||
{{#if (ne pouvoir.system.cibles "")}}
|
||||
<li><strong>Cibles :</strong> {{pouvoir.system.cibles}}</li>
|
||||
{{/if}}
|
||||
{{#if (ne pouvoir.system.virulence "")}}
|
||||
<li><strong>Virulence :</strong> {{pouvoir.system.virulence}}</li>
|
||||
{{/if}}
|
||||
<li><strong>Points d'usage consommés :</strong> {{pouvoirPointsUsage}}</li>
|
||||
{{/if}}
|
||||
|
||||
{{#if sort}}
|
||||
<li><strong>Sort :</strong> {{sort.name}}</li>
|
||||
{{#if (ne sort.system.resistance "")}}
|
||||
<li><strong>Résistance :</strong> {{sort.system.resistance}}</li>
|
||||
{{/if}}
|
||||
{{#if (ne sort.system.concentration "")}}
|
||||
<li><strong>Concentration :</strong> {{sort.system.concentration}}</li>
|
||||
{{/if}}
|
||||
{{#if (ne sort.system.duree "")}}
|
||||
<li><strong>Durée :</strong> {{sort.system.duree}}</li>
|
||||
{{/if}}
|
||||
{{#if (ne sort.system.portee "")}}
|
||||
<li><strong>Portée :</strong> {{sort.system.portee}}</li>
|
||||
{{/if}}
|
||||
{{#if (ne sort.system.ingredients "")}}
|
||||
<li><strong>Ingrédients :</strong> {{sort.system.ingredients}}</li>
|
||||
{{/if}}
|
||||
{{#if (ne sort.system.coutactivation "")}}
|
||||
<li><strong>Coût d'activation :</strong> {{sort.system.coutactivation}}</li>
|
||||
{{/if}}
|
||||
{{#if spendEsprit}}
|
||||
<li><strong>Points d'Esprit dépensé :</strong> 1</li>
|
||||
{{else}}
|
||||
<li><strong>Coût en points d'Âme</strong> : {{sortPointsAme}}</li>
|
||||
{{#if (eq sort.system.competence "Magie du Clan")}}
|
||||
<li><strong>Souffle :</strong> {{sort.system.souffle}}</li>
|
||||
<li><strong>Cout en PV :</strong> 2</li>
|
||||
{{/if}}
|
||||
{{/if}}
|
||||
{{/if}}
|
||||
|
||||
|
||||
<div class="chat-roll-item">
|
||||
<span class="chat-roll-label">Formule</span>
|
||||
<span class="chat-roll-value">{{diceFormula}}</span>
|
||||
</div>
|
||||
|
||||
<div class="chat-roll-item">
|
||||
<span class="chat-roll-label">Dé</span>
|
||||
<span class="chat-roll-value chat-dice-result">{{mainDice}} ({{diceValue}})</span>
|
||||
</div>
|
||||
|
||||
{{#if forcedValue}}
|
||||
<li>Vous dépensez 2 points de Tricherie et utilisez une face adjacente du dé !</li>
|
||||
<div class="chat-roll-item chat-tricherie-used">
|
||||
<span class="chat-roll-label">Tricherie</span>
|
||||
<span class="chat-roll-value">Face {{forcedValue}} utilisée (2 pts)</span>
|
||||
</div>
|
||||
{{/if}}
|
||||
</div>
|
||||
{{/unless}}
|
||||
|
||||
{{#if noRoll}}
|
||||
{{else}}
|
||||
<li><strong>Formule :</strong> {{diceFormula}}</li>
|
||||
<li><strong>Résultat du dé :</strong> {{diceResult}} </li>
|
||||
|
||||
{{#if adjacentFaces}}
|
||||
<li><strong>Faces adjacentes :</strong>
|
||||
{{#each adjacentFaces as |value key|}}
|
||||
<a class="roll-tricherie-2" data-dice-value="{{value}}">{{value}}</a>
|
||||
{{/each}}
|
||||
</li>
|
||||
{{/if}}
|
||||
|
||||
<li><strong>Total : {{finalResult}} {{#if (gt sdValue "-1")}}(Marge : {{marge}}){{/if}}</strong></li>
|
||||
|
||||
|
||||
{{!-- Result Display --}}
|
||||
{{#unless noRoll}}
|
||||
<div class="chat-result-box {{#if isSuccess}}success{{else}}{{#if isCriticalFailure}}critical-failure{{else}}failure{{/if}}{{/if}}">
|
||||
<div class="chat-result-total">
|
||||
<span class="chat-result-label">Total</span>
|
||||
<span class="chat-result-number">{{finalResult}}</span>
|
||||
</div>
|
||||
|
||||
{{#if (gt sdValue "-1")}}
|
||||
<li><strong>Seuil de difficulté :</strong> {{sdValue}}</li>
|
||||
{{#if isSuccess}}
|
||||
<li class="chat-success">Succès...
|
||||
</li>
|
||||
{{else}}
|
||||
<li class="chat-failure">Echec...</li>
|
||||
<div class="chat-result-details">
|
||||
<span>SD: {{sdValue}}</span>
|
||||
<span>Marge: {{marge}}</span>
|
||||
</div>
|
||||
<div class="chat-result-status">
|
||||
{{#if isCriticalSuccess}}
|
||||
<i class="fas fa-star"></i> RÉUSSITE CRITIQUE !
|
||||
{{else if isCriticalFailure}}
|
||||
<i class="fas fa-skull"></i> ÉCHEC CRITIQUE !
|
||||
{{else if isSuccess}}
|
||||
<i class="fas fa-check"></i> Succès
|
||||
{{else}}
|
||||
<i class="fas fa-times"></i> Échec
|
||||
{{/if}}
|
||||
</div>
|
||||
{{/if}}
|
||||
{{/if}}
|
||||
|
||||
|
||||
{{#if isBrelan}}
|
||||
<li class="chat-success">Brelan sur 3 dés !</li>
|
||||
<div class="chat-special-result"><i class="fas fa-dice"></i> Brelan !</div>
|
||||
{{/if}}
|
||||
{{#if isSuite}}
|
||||
<li class="chat-success">Suite sur 3 dés !</li>
|
||||
<div class="chat-special-result"><i class="fas fa-dice"></i> Suite !</div>
|
||||
{{/if}}
|
||||
|
||||
{{!-- Damage display for successful weapon attacks --}}
|
||||
{{#if (and arme isSuccess degatsArme)}}
|
||||
<div class="chat-damage-display">
|
||||
<i class="fas fa-heart-broken"></i> <strong>Dégâts : {{degatsArme}}</strong>
|
||||
</div>
|
||||
{{/if}}
|
||||
</div>
|
||||
{{/unless}}
|
||||
|
||||
{{#if isCriticalSuccess}}
|
||||
<li class="chat-success">Réussite Critique !!!</li>
|
||||
{{/if}}
|
||||
{{#if isCriticalFailure}}
|
||||
<li class="chat-failure">Echec Critique !!!</li>
|
||||
{{/if}}
|
||||
{{/if}}
|
||||
{{!-- Tricherie Adjacent Faces --}}
|
||||
{{#if (and adjacentFaces (not forcedValue))}}
|
||||
<div class="chat-tricherie-box">
|
||||
<span class="chat-tricherie-label">Faces adjacentes (2 pts Tricherie) :</span>
|
||||
<div class="chat-tricherie-faces">
|
||||
{{#each adjacentFaces as |value key|}}
|
||||
<a class="roll-tricherie-2 chat-tricherie-face" data-dice-value="{{value}}">{{value}}</a>
|
||||
{{/each}}
|
||||
</div>
|
||||
</div>
|
||||
{{/if}}
|
||||
|
||||
</ul>
|
||||
</div>
|
||||
{{!-- Details Section (Collapsible) --}}
|
||||
{{#if pouvoir}}
|
||||
<details class="chat-details-section">
|
||||
<summary class="chat-details-summary"><i class="fas fa-magic"></i> Détails du pouvoir</summary>
|
||||
<div class="chat-details-content">
|
||||
<div><strong>Effet :</strong> {{pouvoir.system.effet}}</div>
|
||||
{{#if (ne pouvoir.system.duree "")}}
|
||||
<div><strong>Durée :</strong> {{pouvoir.system.duree}}</div>
|
||||
{{/if}}
|
||||
{{#if (ne pouvoir.system.portee "")}}
|
||||
<div><strong>Portée :</strong> {{pouvoir.system.portee}}</div>
|
||||
{{/if}}
|
||||
{{#if (ne pouvoir.system.resistance "")}}
|
||||
<div><strong>Résistance :</strong> {{pouvoir.system.resistance}}</div>
|
||||
{{/if}}
|
||||
{{#if (ne pouvoir.system.zoneeffet "")}}
|
||||
<div><strong>Zone d'effet :</strong> {{pouvoir.system.zoneeffet}}</div>
|
||||
{{/if}}
|
||||
{{#if (ne pouvoir.system.cibles "")}}
|
||||
<div><strong>Cibles :</strong> {{pouvoir.system.cibles}}</div>
|
||||
{{/if}}
|
||||
<div><strong>Points d'usage :</strong> {{pouvoirPointsUsage}}</div>
|
||||
</div>
|
||||
</details>
|
||||
{{/if}}
|
||||
|
||||
{{#if sort}}
|
||||
<details class="chat-details-section">
|
||||
<summary class="chat-details-summary"><i class="fas fa-hat-wizard"></i> Détails du sort</summary>
|
||||
<div class="chat-details-content">
|
||||
{{#if (ne sort.system.duree "")}}
|
||||
<div><strong>Durée :</strong> {{sort.system.duree}}</div>
|
||||
{{/if}}
|
||||
{{#if (ne sort.system.portee "")}}
|
||||
<div><strong>Portée :</strong> {{sort.system.portee}}</div>
|
||||
{{/if}}
|
||||
{{#if (ne sort.system.ingredients "")}}
|
||||
<div><strong>Ingrédients :</strong> {{sort.system.ingredients}}</div>
|
||||
{{/if}}
|
||||
{{#if (ne sort.system.resistance "")}}
|
||||
<div><strong>Résistance :</strong> {{sort.system.resistance}}</div>
|
||||
{{/if}}
|
||||
{{#if spendEsprit}}
|
||||
<div><strong>Points d'Esprit :</strong> 1</div>
|
||||
{{else}}
|
||||
<div><strong>Points d'Âme :</strong> {{sortPointsAme}}</div>
|
||||
{{#if (eq sort.system.competence "Magie du Clan")}}
|
||||
<div><strong>Souffle :</strong> {{sort.system.souffle}}</div>
|
||||
<div><strong>Coût PV :</strong> 2</div>
|
||||
{{/if}}
|
||||
{{/if}}
|
||||
</div>
|
||||
</details>
|
||||
{{/if}}
|
||||
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user