Gestion des signes draconiques #455

Closed
vincent.vandeme wants to merge 233 commits from v1.4-signes-draconiques into master
16 changed files with 201 additions and 146 deletions
Showing only changes of commit d42de6c316 - Show all commits

View File

@ -324,12 +324,13 @@ export class RdDActor extends Actor {
/* -------------------------------------------- */
getDraconicList() {
return this.items.filter(it => Misc.data(it).type == 'competence' && Misc.templateData(it).categorie == 'draconic')
.sort(Misc.descending(it => Misc.templateData(it).niveau));
}
/* -------------------------------------------- */
getBestDraconic() {
const list = this.getDraconicList().sort(Misc.descending(it => Misc.templateData(it).niveau));
const list = this.getDraconicList();
if (list.length == 0) {
return { name: "Aucun", data: { name: "Aucun", data: { niveau: -11 } } };
return { name: "Aucun", data: { name: "Aucun", data: { niveau: 0 } } };
}
return duplicate(list[0]);
}
@ -541,9 +542,8 @@ export class RdDActor extends Actor {
ChatMessage.create(message);
}
/* -------------------------------------------- */
async dormir(heures = 1) {
async dormir(heures) {
let message = {
whisper: ChatUtility.getWhisperRecipientsAndGMs(this.name),
content: `${this.name}: Vous dormez ${heures == 1 ? 'une' : heures} heure${heures == 1 ? '' : 's'}.`
@ -552,9 +552,9 @@ export class RdDActor extends Actor {
for (let i = 0; i < heures; i++) {
await this._recupererEthylisme(message);
await this.recupererFatigue(message);
await this.recuperationReve(message);
await this.recuperationReve(message, 1);
if (EffetsDraconiques.isDonDoubleReve(this)) {
await this.recuperationReve(message);
await this.recuperationReve(message, 2);
}
}
ChatMessage.create(message);
@ -620,11 +620,13 @@ export class RdDActor extends Actor {
}
/* -------------------------------------------- */
async recuperationReve(message) {
async recuperationReve(message, demiHeure) {
const seuil = Misc.templateData(this).reve.seuil.value;
const reveActuel = this.getReveActuel();
if (reveActuel >= seuil) {
message.content += `Vous avez suffisament rêvé, au delà de votre seuil. `;
if (demiHeure == 1) {
message.content += `Vous avez suffisament rêvé, au delà de votre seuil. `;
}
}
else {
let deRecuperation = (await DeDraconique.ddr("selfroll")).total;
@ -1967,28 +1969,29 @@ export class RdDActor extends Actor {
}
/* -------------------------------------------- */
filterDraconicList(sortList) {
let draconicDone = {};
let newDraconicList = [];
let draconicList = this.getDraconicList();
let bestDraconic = this.getBestDraconic();
computeDraconicAndSortIndex(sortList) {
let draconicList = this.getDraconicList().map(d => duplicate(Misc.data(d)));
for (let sort of sortList) {
let voie = sort.data.draconic;
let draconic = RdDItemCompetence.getVoieDraconic(draconicList, voie);
//console.log(draconicList, bestDraconic, draconic, voie);
if (sort.name.toLowerCase().includes('aura')) {
draconic = bestDraconic;
let draconicsSort = this.getDraconicsSort(draconicList, sort).map(it => it.name);
for (let index = 0; index < draconicList.length && sort.data.listIndex==undefined; index++){
if (draconicsSort.includes(draconicList[index].name)){
sort.data.listIndex = index;
}
}
// TODO: duplicate sur Misc.data?
draconic = duplicate(Misc.data(draconic));
if (draconicDone[draconic.name] == undefined) {
draconic.data.defaut_carac = 'reve';
newDraconicList.push(draconic);
draconicDone[draconic.name] = newDraconicList.length - 1; // Patch local pour relier facilement voie/compétence
}
sort.data.listIndex = draconicDone[draconic.name] || 0;
}
return newDraconicList;
return draconicList;
}
getDraconicsSort(draconicList, sort) {
//console.log(draconicList, bestDraconic, draconic, voie);
switch (Grammar.toLowerCaseNoAccent(sort.name)) {
case "lecture d'aura":
case "detection d'aura":
return draconicList;
case "annulation de magie":
return draconicList.filter(it => !Grammar.toLowerCaseNoAccent(Misc.data(it).name).includes('thanatos'));
}
return [RdDItemCompetence.getVoieDraconic(draconicList, sort.data.draconic)];
}
/* -------------------------------------------- */
@ -2009,7 +2012,7 @@ export class RdDActor extends Actor {
}
if (this.currentTMR) this.currentTMR.minimize(); // Hide
let draconicList = this.filterDraconicList(sortList);
let draconicList = this.computeDraconicAndSortIndex(sortList);
const actorData = Misc.data(this);
let rollData = {
forceCarac: { 'reve': duplicate(actorData.data.carac.reve) },
@ -2028,6 +2031,7 @@ export class RdDActor extends Actor {
const dialog = await RdDRoll.create(this, rollData,
{
html: 'systems/foundryvtt-reve-de-dragon/templates/dialog-roll-sort.html',
options: { height: 600 },
close: html => { this.currentTMR.maximize() } // Re-display TMR
},
{
@ -2035,17 +2039,9 @@ export class RdDActor extends Actor {
label: 'Lancer un sort',
callbacks: [
this.createCallbackExperience(),
{ action: r => this._rollUnSortResult(r, false) }
{ action: r => this._rollUnSortResult(r) }
]
},
{
name: 'mettre-en-reserve',
label: 'Mettre un sort en réserve',
callbacks: [
this.createCallbackExperience(),
{ action: r => this._rollUnSortResult(r, true) }
]
},
}
);
dialog.render(true);
}
@ -2095,17 +2091,11 @@ export class RdDActor extends Actor {
}
/* -------------------------------------------- */
async _rollUnSortResult(rollData, isSortReserve = false) {
async _rollUnSortResult(rollData) {
let rolled = rollData.rolled;
let selectedSort = rollData.selectedSort;
let closeTMR = !isSortReserve;
if (selectedSort.data.isrituel && isSortReserve) {
ui.notifications.error("Impossible de mettre le rituel '" + selectedSort.name + "' en réserve");
this.currentTMR.close(); // Close TMR !
return;
}
rollData.isSortReserve = isSortReserve;
rollData.isSortReserve = rollData.mettreEnReserve && !selectedSort.data.isrituel;
rollData.show = {}
rollData.depenseReve = Number(selectedSort.data.ptreve_reel);
@ -2126,7 +2116,6 @@ export class RdDActor extends Actor {
if (rollData.isSortReserve) {
await this.sortMisEnReserve(rollData, selectedSort);
closeTMR = false;
}
}
else {
@ -2146,10 +2135,10 @@ export class RdDActor extends Actor {
reveActuel = Math.max(reveActuel - rollData.depenseReve, 0);
await this.update({ "data.reve.reve.value": reveActuel });
if (closeTMR) {
this.currentTMR.close(); // Close TMR !
} else {
if (rollData.isSortReserve) {
this.currentTMR.maximize(); // Re-display TMR
} else {
this.currentTMR.close(); // Close TMR !
}
// Final chat message
RdDResolutionTable.displayRollData(rollData, this, 'chat-resultat-sort.html');
@ -2320,7 +2309,7 @@ export class RdDActor extends Actor {
{
oeuvre: oeuvre,
art: oeuvre.type,
competence: duplicate(Misc.data(this.getCompetence(oeuvre.data.competence ?? artData.art))),
competence: duplicate(Misc.data(this.getCompetence(artData.compName ?? oeuvre.data.competence ?? artData.art))),
diffLibre: - (oeuvre.data.niveau ?? 0),
diffConditions: 0,
use: { libre: false, conditions: true },
@ -2402,8 +2391,8 @@ export class RdDActor extends Actor {
async rollRecetteCuisine(id) {
const oeuvre = Misc.data(this.getRecetteCuisine(id));
const artData = {
art: 'cuisine',
verbe: 'Cuisiner',
compName: 'cuisine',
proportions: 1,
ajouterEquipement: false
};

View File

@ -15,8 +15,7 @@ export class DeDraconique extends Roll{
evaluate() {
super.evaluate();
const rerolls = Math.ceil(this.total / 8);
this.terms[this.terms.length - 1] = rerolls;
this.results[this.results.length - 1] = rerolls;
this.terms[this.terms.length - 1].number = rerolls;
this._total -= rerolls;
return this;
}

View File

@ -1,7 +1,6 @@
import { RollDataAjustements } from "./rolldata-ajustements.js";
import { HtmlUtility } from "./html-utility.js";
import { RdDItemCompetence } from "./item-competence.js";
import { RdDItemMeditation } from "./item-meditation.js";
import { RdDItemSort } from "./item-sort.js";
import { Misc } from "./misc.js";
import { RdDBonus } from "./rdd-bonus.js";
@ -169,7 +168,8 @@ export class RdDRoll extends Dialog {
$("#carac").val(defaut_carac);
}
if (rollData.selectedSort) {
$("#draconic").val(rollData.selectedSort.data.listIndex); // Uniquement a la selection du sort, pour permettre de changer
dialog.setSelectedSort(rollData.selectedSort);
$(".draconic").val(rollData.selectedSort.data.listIndex); // Uniquement a la selection du sort, pour permettre de changer
}
RdDItemSort.setCoutReveReel(rollData.selectedSort);
$("#diffLibre").val(Misc.toInt(rollData.diffLibre));
@ -194,20 +194,16 @@ export class RdDRoll extends Dialog {
this.rollData.selectedCarac = this.rollData.carac[caracKey]; // Update the selectedCarac
this.updateRollResult();
});
html.find('#draconic').change((event) => {
html.find('.roll-draconic').change((event) => {
let draconicKey = Misc.toInt(event.currentTarget.value);
this.rollData.competence = this.rollData.draconicList[draconicKey]; // Update the selectedCarac
this.updateRollResult();
});
html.find('#sort').change((event) => {
html.find('.roll-sort').change((event) => {
let sortKey = Misc.toInt(event.currentTarget.value);
this.rollData.selectedSort = this.rollData.sortList[sortKey]; // Update the selectedCarac
this.rollData.bonus = RdDItemSort.getCaseBonus(this.rollData.selectedSort, this.rollData.tmr.coord);
this.rollData.diffLibre = RdDItemSort.getDifficulte(this.rollData.selectedSort, -7)
RdDItemSort.setCoutReveReel(this.rollData.selectedSort);
$("#draconic").val(this.rollData.selectedSort.data.listIndex); // Uniquement a la selection du sort, pour permettre de changer
$("#diffLibre").val(this.rollData.diffLibre);
this.setSelectedSort(this.rollData.sortList[sortKey]);
this.updateRollResult();
$("#diffLibre").val(this.rollData.diffLibre);
});
html.find('#ptreve-variable').change((event) => {
let ptreve = Misc.toInt(event.currentTarget.value);
@ -257,6 +253,29 @@ export class RdDRoll extends Dialog {
});
}
async setSelectedSort(sort) {
this.rollData.selectedSort = sort; // Update the selectedCarac
this.rollData.competence = RdDItemCompetence.getVoieDraconic(this.rollData.draconicList, sort.data.draconic);
this.rollData.bonus = RdDItemSort.getCaseBonus(sort, this.rollData.tmr.coord);
this.rollData.diffLibre = RdDItemSort.getDifficulte(sort, -7);
RdDItemSort.setCoutReveReel(sort);
const htmlSortDescription = await renderTemplate("systems/foundryvtt-reve-de-dragon/templates/partial-description-sort.html", { sort: sort });
$(".sort-ou-rituel").text(sort.data.isrituel ? "rituel" : "sort");
$(".bonus-case").text(`${this.rollData.bonus}%`);
$(".details-sort").remove();
$(".description-sort").append(htmlSortDescription);
$(".roll-draconic").val(sort.data.listIndex);
$(".div-sort-difficulte-fixe").text(Misc.toSignedString(sort.data.difficulte));
$(".div-sort-ptreve-fixe").text(sort.data.ptreve);
const diffVariable = RdDItemSort.isDifficulteVariable(sort);
const coutVariable = RdDItemSort.isCoutVariable(sort);
HtmlUtility._showControlWhen($(".div-sort-non-rituel"), !sort.data.isrituel);
HtmlUtility._showControlWhen($(".div-sort-difficulte-var"), diffVariable);
HtmlUtility._showControlWhen($(".div-sort-difficulte-fixe"), !diffVariable);
HtmlUtility._showControlWhen($(".div-sort-ptreve-var"), coutVariable);
HtmlUtility._showControlWhen($(".div-sort-ptreve-fixe"), !coutVariable);
}
/* -------------------------------------------- */
async updateRollResult() {
let rollData = this.rollData;
@ -270,11 +289,6 @@ export class RdDRoll extends Dialog {
if (rollData.coupsNonMortels) {
dmgText = `(${dmgText}) non-mortel`
}
if (rollData.selectedSort) {
rollData.bonus = RdDItemSort.getCaseBonus(rollData.selectedSort, rollData.tmr.coord);
HtmlUtility._showControlWhen($("#div-sort-difficulte"), RdDItemSort.isDifficulteVariable(rollData.selectedSort))
HtmlUtility._showControlWhen($("#div-sort-ptreve"), RdDItemSort.isCoutVariable(rollData.selectedSort))
}
RollDataAjustements.calcul(rollData, this.actor);
rollData.finalLevel = this._computeFinalLevel(rollData);

View File

@ -157,6 +157,8 @@ export class RdDUtility {
'systems/foundryvtt-reve-de-dragon/templates/dialog-roll-alchimie.html',
'systems/foundryvtt-reve-de-dragon/templates/dialog-astrologie-joueur.html',
// Partials
'systems/foundryvtt-reve-de-dragon/templates/partial-description-overflow.html',
'systems/foundryvtt-reve-de-dragon/templates/partial-description-sort.html',
'systems/foundryvtt-reve-de-dragon/templates/partial-roll-ajustements.html',
'systems/foundryvtt-reve-de-dragon/templates/partial-roll-diffLibre.html',
'systems/foundryvtt-reve-de-dragon/templates/partial-roll-diffCondition.html',

View File

@ -447,6 +447,16 @@ table {border: 1px solid #7a7971;}
font-size: 0.70rem;
text-align: right;
}
.poesie-overflow {
color: rgba(82, 17, 131, 0.9);
max-height: 2.5rem;
overflow: hidden;
}
.poesie-overflow:hover {
max-height: unset;
overflow: visible;
}
/* ======================================== */
/* Sheet */
.window-app.sheet .window-content .sheet-header{

View File

@ -15,10 +15,8 @@
</div>
</div>
<div id="tableResolution">
</div>
<div id="tableProbaReussite">
</div>
<div id="tableResolution"></div>
<div id="tableProbaReussite"></div>
</form>
<script>

View File

@ -8,7 +8,7 @@
<label>Caractéristique: </label><label class="flex-grow">{{selectedCarac.label}}</label>
<label>{{competence.name}}:</label><label class="flex-grow">{{numberFormat competence.data.niveau decimals=0 sign=true}}</label></label>
</div>
{{> "systems/foundryvtt-reve-de-dragon/templates/chat-poesie.html" oeuvre.data}}
{{> "systems/foundryvtt-reve-de-dragon/templates/partial-description-overflow.html" oeuvre.data}}
</div>
<div class="flex-group-left">
<div class="flexrow">

View File

@ -8,7 +8,7 @@
<label for="carac">Caractéristique:</label>{{>"systems/foundryvtt-reve-de-dragon/templates/partial-select-carac.html"}}
<label>{{competence.name}}:</label><label class="flex-grow">{{numberFormat competence.data.niveau decimals=0 sign=true}}</label></label>
</div>
{{> "systems/foundryvtt-reve-de-dragon/templates/chat-poesie.html" oeuvre.data}}
{{> "systems/foundryvtt-reve-de-dragon/templates/partial-description-overflow.html" oeuvre.data}}
</div>
<div class="flex-group-left">
<div class="flexrow">

View File

@ -18,7 +18,7 @@
<div id="tableAjustements" class="flexrow"></div>
</div>
</div>
{{> "systems/foundryvtt-reve-de-dragon/templates/chat-poesie.html" oeuvre.data}}
{{> "systems/foundryvtt-reve-de-dragon/templates/partial-description-overflow.html" oeuvre.data}}
<div id="tableResolution"></div>
<div id="tableProbaReussite"></div>

View File

@ -8,7 +8,7 @@
<label>Caractéristique: </label><label class="flex-grow">{{selectedCarac.label}}</label>
<label>{{competence.name}}:</label><label class="flex-grow">{{numberFormat competence.data.niveau decimals=0 sign=true}}</label></label>
</div>
{{> "systems/foundryvtt-reve-de-dragon/templates/chat-poesie.html" oeuvre.data}}
{{> "systems/foundryvtt-reve-de-dragon/templates/partial-description-overflow.html" oeuvre.data}}
</div>
<div class="flex-group-left">
<div class="flexrow">

View File

@ -9,7 +9,7 @@
</label>
<label>{{competence.name}}:</label><label class="flex-grow">{{numberFormat competence.data.niveau decimals=0 sign=true}}</label></label>
</div>
{{> "systems/foundryvtt-reve-de-dragon/templates/chat-poesie.html" oeuvre.data}}
{{> "systems/foundryvtt-reve-de-dragon/templates/partial-description-overflow.html" oeuvre.data}}
</div>
<div class="flex-group-left">
<div class="flexrow">

View File

@ -1,9 +1,5 @@
<form class="rdddialog">
<h2 class="tooltip" style="width: 100%;">Cuisiner: {{oeuvre.name}}
<div class="tooltiptext ttt-titre">
{{> "systems/foundryvtt-reve-de-dragon/templates/chat-poesie.html" oeuvre.data}}
</div>
</h2>
<h2>Cuisiner: {{oeuvre.name}}</h2>
<div class="grid grid-2col">
<div class="flex-group-left">
@ -38,7 +34,7 @@
<div id="tableAjustements" class="flexrow"></div>
</div>
</div>
{{> "systems/foundryvtt-reve-de-dragon/templates/partial-description-overflow.html" oeuvre.data}}
<div id="tableResolution"></div>
<div id="tableProbaReussite"></div>
</form>

View File

@ -1,12 +1,27 @@
<form class="skill-roll-dialog">
<h2>Rêve de Dragon de force {{rencontre.force}}!</h2>
<div class="form-group">
<div class="grid grid-2col">
<div class="flex-group-left">
<img class="chat-icon" src="{{competence.img}}" alt="{{competence.name}}"/>
<div class="grid grid-2col">
<label for="carac">Rêve actuel:</label><label class="flex-grow" name="carac">{{selectedCarac.value}}</label>
<label for="competence">{{competence.name}}:</label><label class="flex-grow" name="competence">{{numberFormat competence.data.niveau decimals=0 sign=true}}</label>
</div>
</div>
<div class="flex-group-left">
<div class="flexrow">
<label>Difficulté</label>
<label>{{numberFormat diffLibre decimals=0 sign=true}}</label>
</div>
{{>"systems/foundryvtt-reve-de-dragon/templates/partial-roll-diffCondition.html"}}
<div id="tableAjustements" class="flexrow"></div>
</div>
</div>
<div id="tableAjustements"></div>
<div id="tableResolution"></div>
<div id="tableProbaReussite"></div>
</form>
</form>
<script>
</script>
<script>
</script>

View File

@ -1,63 +1,77 @@
{{log 'lancer de sort' this}}
<form class="dialog-roll-sort">
<div class="form-group">
<label>Rêve : <label>{{numberFormat selectedCarac.value decimals=0 sign=false}}</label></label>
<label>TMR : {{tmr.label}} ({{tmr.coord}})</label>
</div>
<div class="form-group">
<label>Draconic </label>
<select name="draconic" id="draconic" data-dtype="String">
{{#select draconic}}
{{#each draconicList as |draconic key|}}
<option value={{key}}>{{draconic.name}} : {{draconic.data.niveau}}</option>
{{/each}}
{{/select}}
</select>
<label> &nbsp;Conditions</label>
<select name="diffConditions" id="diffConditions" data-dtype="number">
{{#select diffConditions}}
{{#each ajustementsConditions as |key|}}
<option value={{key}}>{{numberFormat key decimals=0 sign=true}}</option>
{{/each}}
{{/select}}
</select>
</div>
<div class="form-group">
<label>Sort </label>
<select name="sort" id="sort" data-dtype="String">
{{#select sort}}
{{#each sortList as |sort key|}}
<option value={{key}}>{{this.name}} - {{#if this.data.caseTMRspeciale}} {{this.data.caseTMRspeciale}} {{else}}{{this.data.caseTMR}}{{/if}} / R{{this.data.difficulte}} r {{sort.data.ptreve}} ({{sort.data.draconic}})</option>
{{/each}}
{{/select}}
</select>
</div>
<div class="form-group" id="div-sort-difficulte">
<label>Difficulté </label>
<select name="diffLibre" id="diffLibre" data-dtype="number">
{{#select diffLibre}}
{{#each difficultesLibres as |key|}}
<option value={{key}}>{{numberFormat key decimals=0 sign=true}}</option>
{{/each}}
{{/select}}
</select>
</div>
<div class="form-group" id="div-sort-ptreve">
<label>Couts en Points de Rêve </label>
<select name="ptreve-variable" id="ptreve-variable" data-dtype="number">
{{#select ptreve-variable}}
{{#each coutreve as |cout key|}}
<option value={{cout}}>{{cout}}</option>
<h2>Lancer le <span class="sort-ou-rituel">{{#if sort.data.isrituel}}rituel{{else}}sort{{/if}}</span>:
<select name="sort" class="roll-sort flex-grow" data-dtype="String">
{{#select sort}}
{{#each sortList as |sort key|}}
<option value={{key}}>{{this.name}} - {{#if this.data.caseTMRspeciale}} {{this.data.caseTMRspeciale}}
{{else}}{{this.data.caseTMR}}{{/if}} / R{{this.data.difficulte}} r {{sort.data.ptreve}} ({{sort.data.draconic}})
</option>
{{/each}}
{{/select}}
</select>
</h2>
<img class="chat-icon" src="{{competence.img}}" alt="{{competence.name}}" />
<div class="grid grid-2col">
<div class="flex-group-left">
<div class="flexrow">
<label for="tmr">TMR - {{tmr.coord}}:</label><label name="tmr">{{tmr.label}}</label>
</div>
<div class="flexrow">
<label for="carac">Rêve:</label><label name="carac">{{selectedCarac.value}}</label>
</div>
<div class="flexrow">
<label for="ptreve-variable">Points de Rêve: </label>
<select name="ptreve-variable" class="div-sort-ptreve-var" id="ptreve-variable" data-dtype="number">
{{#select ptreve-variable}}
{{#each coutreve as |cout key|}}
<option value={{cout}}>{{cout}}</option>
{{/each}}
{{/select}}
</select>
<label class="div-sort-ptreve-fixe">{{selectedSort.data.ptreve}}</select>
</div>
<div class="flexrow div-sort-non-rituel">
<label>Mettre en réserve</label>
<input class="checkbox-by-name" type="checkbox" name="mettreEnReserve" {{#if mettreEnReserve}}checked{{/if}} />
</div>
</div>
<div class="flex-group-left">
<div class="flexrow">
<label for="competence">Draconic:</label>
<select name="competence" class="roll-draconic" data-dtype="String">
{{#select draconic}}
{{#each draconicList as |draconic key|}}
<option value={{key}}>{{draconic.name}} : {{numberFormat draconic.data.niveau decimals=0 sign=true}}
</option>
{{/each}}
{{/select}}
</select>
</div>
<div class="flexrow">
<label for="diffLibre">Difficulté </label>
<select name="diffLibre" class="div-sort-difficulte-var" id="diffLibre" data-dtype="number">
{{#select diffLibre}}
{{#each difficultesLibres as |key|}}
<option value={{key}}>{{numberFormat key decimals=0 sign=true}}</option>
{{/each}}
{{/select}}
</select>
<label class="div-sort-difficulte-fixe">{{numberFormat selectedSort.data.difficulte decimals=0 sign=true}}</label>
</div>
{{>"systems/foundryvtt-reve-de-dragon/templates/partial-roll-diffCondition.html"}}
<div class="flexrow">
<label for="bonus-case">Bonus de case </label>
<label name="bonus-case" class="bonus-case">0%</label>
</div>
<div id="tableAjustements" class="flexrow"></div>
</div>
</div>
<div class="description-sort">
<hr>
{{> "systems/foundryvtt-reve-de-dragon/templates/partial-description-sort.html" sort=selectedSort}}
</div>
<div id="tableAjustements">
</div>
<div id="tableResolution"></div>
<div id="tableProbaReussite"></div>
</form>

View File

@ -0,0 +1,8 @@
{{#if (or description reference)}}
<div class="poesie-extrait poesie-overflow">
{{{description}}}
{{#if reference}}
<p class="poesie-reference">{{reference}}</p>
{{/if}}
</div>
{{/if}}

View File

@ -0,0 +1,10 @@
<div class="flex-group-left details-sort">
{{#if sort.data.cible}}<label><strong>Cible</strong>: {{sort.data.cible}}&nbsp;&nbsp;</label>{{/if}}
{{#if sort.data.JR}}<label><strong>JR</strong>: {{sort.data.JR}}&nbsp;&nbsp;</label>{{/if}}
{{#if sort.data.portee}}<label><strong>Portée</strong>: {{sort.data.portée}}&nbsp;&nbsp;</label>{{/if}}
{{#if sort.data.duree}}<label><strong>Durée</strong>: {{sort.data.duree}}&nbsp;&nbsp;</label>{{/if}}
{{#if sort.data.coutseuil}}<label><strong>Coût de seuil</strong>: {{sort.data.coutseuil}}</label>{{/if}}
</div>
<div class="details-sort">
{{> "systems/foundryvtt-reve-de-dragon/templates/partial-description-overflow.html" sort.data}}
</div>