From 771622564a2cf4bcb2411c8ee483f25c775fe4fa Mon Sep 17 00:00:00 2001 From: LeFelis Date: Tue, 9 Feb 2021 23:23:40 +0100 Subject: [PATCH 1/3] Checkbox et regles d'appel au moral --- module/actor.js | 36 +++++++++++++++++-- module/rdd-carac.js | 6 ++-- module/rdd-roll.js | 46 ++++++++++++++++++++++--- module/rdd-utility.js | 1 + module/rolldata-ajustements.js | 4 +-- styles/simple.css | 18 +++++++++- templates/chat-info-appel-au-moral.html | 4 +++ templates/chat-resultat-competence.html | 1 + templates/dialog-competence.html | 2 ++ 9 files changed, 107 insertions(+), 11 deletions(-) create mode 100644 templates/chat-info-appel-au-moral.html diff --git a/module/actor.js b/module/actor.js index a22e56bf..f398355b 100644 --- a/module/actor.js +++ b/module/actor.js @@ -1593,7 +1593,15 @@ export class RdDActor extends Actor { action: r => this._appliquerAjoutExperience(r, game.settings.get("core", "rollMode") != 'blindroll') }; } - + + /* -------------------------------------------- */ + createCallbackAppelAuMoral() { + return { + condition: r => r.use.appelAuMoral && game.settings.get("core", "rollMode") != 'selfroll', + action: r => { console.log("createCallbackAppelAuMoral"); this.displayAppelAuMoral ; console.log(r.rolled.isEchec); this._appliquerAppelMoral(r, game.settings.get("core", "rollMode") != 'blindroll') } + }; + } + /* -------------------------------------------- */ async checkCaracXP(caracName) { let carac = this.data.data.carac[caracName]; @@ -1663,6 +1671,27 @@ export class RdDActor extends Actor { if (xpResult && xpResult.xpCarac > 0 && rollData.selectedCarac) { this.checkCaracXP(rollData.selectedCarac.name); } + } + + /* -------------------------------------------- */ + async _appliquerAppelMoral(rollData, display = true) { + console.log("_appliquerAppelMoral"); + console.log("_appliquerAppelMoral"); + console.log("_appliquerAppelMoral"); + console.log("_appliquerAppelMoral"); + console.log(rollData); + console.log(this.name); + console.log(this); + if (!this.isPersonnage()) return; + if (!rollData.rolled.isEchec) return; + const waitUpdate = this.moralIncDec(-1); /* L'appel au moral a échoué. Le personnage perd un point de moral */ + console.log("_appliquerAppelMoral : moral diminuer"); + rollData.moralDiminuer = true; + rollData.moralActualiser = 7; + await waitUpdate; + rollData.moralActualiser = this.getMoralTotal(); + console.log("rollData.moralDiminuer: "+rollData.moralDiminuer); + console.log("rollData.moralActualiser: "+rollData.moralActualiser); } /* -------------------------------------------- */ @@ -1967,6 +1996,7 @@ export class RdDActor extends Actor { label: 'Jet ' + Grammar.apostrophe('de', name), callbacks: [ this.createCallbackExperience(), + this.createCallbackAppelAuMoral(), { action: r => this._competenceResult(r) } ] }); @@ -2210,7 +2240,9 @@ export class RdDActor extends Actor { async _competenceResult(rollData) { RdDResolutionTable.displayRollData(rollData, this, 'chat-resultat-competence.html') } - + async _moralDecrease(rollData) { + RdDResolutionTable.displayRollData(rollData, this, 'chat-resultat-competence.html') + } /* -------------------------------------------- */ async rollAppelChance(onSuccess = () => { }, onEchec = () => { }) { let rollData = { selectedCarac: this.getCaracByName('chance-actuelle'), surprise: '' }; diff --git a/module/rdd-carac.js b/module/rdd-carac.js index ae9cdf26..337212b2 100644 --- a/module/rdd-carac.js +++ b/module/rdd-carac.js @@ -1,3 +1,5 @@ +import { Grammar } from "./grammar.js"; + export class RdDCarac { static isAgiliteOuDerivee(selectedCarac) { @@ -25,6 +27,6 @@ export class RdDCarac { * ainsi que de Perception active et volontaire. */ static isActionPhysique(selectedCarac) { - return selectedCarac?.label.match(/(Apparence|Force|Agilité|Dextérité|Vue|Ouïe|Odorat-Goût|Empathie|Mêlée|Tir|Lancer|Dérobée)/); + return Grammar.toLowerCaseNoAccent(selectedCarac?.label).match(/(apparence|force|agilite|dexterite|vue|ouie|odorat|empathie|melee|tir|lancer|derobee)/); } -} \ No newline at end of file +} diff --git a/module/rdd-roll.js b/module/rdd-roll.js index 4c81ad17..8d51628f 100644 --- a/module/rdd-roll.js +++ b/module/rdd-roll.js @@ -37,23 +37,26 @@ export class RdDRoll extends Dialog { ajustementsConditions: CONFIG.RDD.ajustementsConditions, difficultesLibres: CONFIG.RDD.difficultesLibres, etat: actor.getEtatGeneral(), - moral: actor.getMoralTotal(), + moral: actor.getMoralTotal(), /* La valeur du moral pour les jets de volonté */ carac: actor.data.data.carac, finalLevel: 0, diffConditions: 0, diffLibre: rollData.competence?.data.default_diffLibre ?? 0, malusArmureValue: actor.getMalusArmure(), - surencMalusFlag: actor.isPersonnage() ? (actor.data.data.compteurs.surenc.value < 0) : false, + surencMalusFlag: actor.isPersonnage() ? (actor.data.data.compteurs.surenc.value < 0) : false, surencMalusValue: actor.getSurenc(), useMalusSurenc: false, - use: { libre:true, conditions: true, surenc: false, encTotal: false, }, + appelAuMoralDemander :false, + use: { libre:true, conditions: true, surenc: false, encTotal: false, appelAuMoral : false }, isMalusEncombrementTotal: RdDItemCompetence.isMalusEncombrementTotal(rollData.competence), useMalusEncTotal: false, encTotal: actor.getEncTotal(), ajustementAstrologique: actor.ajustementAstrologique(), surprise: actor.getSurprise(false), } + console.log("defaultRollData.appelAuMoralFlag : "+defaultRollData.appelAuMoralFlag); mergeObject(rollData, defaultRollData, { recursive: true, overwrite: false }); + console.log("rollData.appelAuMoralFlag : "+rollData.appelAuMoralFlag); if ( rollData.forceCarac) { rollData.carac = rollData.forceCarac; } @@ -187,6 +190,23 @@ export class RdDRoll extends Dialog { this.rollData.useMalusEncTotal = event.currentTarget.checked; this.updateRollResult(); }); + html.find('#useAppelAuMoralCheckbox').change((event) => { /* l'appel au moral, qui donne un bonus de +1 */ + + console.log("#useAppelAuMoralCheckbox"); + //console.log("surencMalusFlag : "+surencMalusFlag); + console.log("this.appelAuMoralFlag : "+this.appelAuMoralFlag); + console.log("this.rollData.moral : "+this.rollData.moral); + console.log("this.rollData.ajustements : "+this.rollData.ajustements); + console.log("this.rollData.ajustements.moral : "+this.rollData.ajustements.moral); + console.log("this.rollData.ajustements.moral.isVisible : "+this.rollData.ajustements.moral.isVisible); + console.log("event.currentTarget.checked : "+event.currentTarget.checked); + console.log("this.rollData.use.appelAuMoral : "+this.rollData.use.appelAuMoral); + this.rollData.appelAuMoralDemander = event.currentTarget.checked + // this.rollData.use.appelAuMoral = event.currentTarget.checked + console.log("this.rollData.moral : "+this.rollData.moral); + console.log("this.rollData.use.appelAuMoral : "+this.rollData.use.appelAuMoral); + this.updateRollResult(); + }); // Section Méditation html.find('.conditionMeditation').change((event) => { let condition = event.currentTarget.attributes['id'].value; @@ -198,7 +218,7 @@ export class RdDRoll extends Dialog { /* -------------------------------------------- */ async updateRollResult() { let rollData = this.rollData; - + rollData.dmg = rollData.attackerRoll?.dmg ?? RdDBonus.dmg(rollData, this.actor.getBonusDegat()); rollData.caracValue = parseInt(rollData.selectedCarac.value); rollData.coupsNonMortels = (rollData.attackerRoll?.dmg.mortalite ?? rollData.dmg.mortalite) == 'non-mortel'; @@ -211,10 +231,28 @@ export class RdDRoll extends Dialog { rollData.bonus = RdDItemSort.getCaseBonus(rollData.selectedSort, rollData.coord); } + /* ! actor.isPersonnage() || */ + if ( ! RdDCarac.isActionPhysique(rollData.selectedCarac) ) { + rollData.use.appelAuMoral = false; + } else { + rollData.use.appelAuMoral = rollData.appelAuMoralDemander; + } + + RollDataAjustements.calcul(rollData, this.actor); rollData.finalLevel = this._computeFinalLevel(rollData); + console.log("updateRollResult"); + console.log("rollData.ajustements.moralTotal.used: "+rollData.ajustements.moralTotal.used); + console.log("rollData.ajustements.moral.used: "+rollData.ajustements.moral.used); + console.log("rollData.use.appelAuMoral: "+rollData.use.appelAuMoral); + console.log("rollData.selectedCarac: "); + console.log(rollData.selectedCarac); + console.log("RdDCarac.isActionPhysique(rollData.selectedCarac): "+RdDCarac.isActionPhysique(rollData.selectedCarac)); + HtmlUtility._showControlWhen($(".diffMoral"), rollData.ajustements.moralTotal.used); + HtmlUtility._showControlWhen($(".diffAppelAuMoral"), RdDCarac.isActionPhysique(rollData.selectedCarac) ); + HtmlUtility._showControlWhen($(".diffAppelAuMoral-checker"), RdDCarac.isActionPhysique(rollData.selectedCarac) ); HtmlUtility._showControlWhen($("#etat-general"), !RdDCarac.isIgnoreEtatGeneral(rollData.selectedCarac, rollData.competence)); HtmlUtility._showControlWhen($("#ajust-astrologique"), RdDResolutionTable.isAjustementAstrologique(rollData)); diff --git a/module/rdd-utility.js b/module/rdd-utility.js index 7a05c7a3..0a319a64 100644 --- a/module/rdd-utility.js +++ b/module/rdd-utility.js @@ -246,6 +246,7 @@ export class RdDUtility { 'systems/foundryvtt-reve-de-dragon/templates/hud-actor-attaque.html', // messages tchat 'systems/foundryvtt-reve-de-dragon/templates/chat-infojet.html', + 'systems/foundryvtt-reve-de-dragon/templates/chat-info-appel-au-moral.html', 'systems/foundryvtt-reve-de-dragon/templates/chat-demande-defense.html', 'systems/foundryvtt-reve-de-dragon/templates/chat-demande-attaque-particuliere.html', 'systems/foundryvtt-reve-de-dragon/templates/chat-demande-attaque-etotal.html', diff --git a/module/rolldata-ajustements.js b/module/rolldata-ajustements.js index d1c6692a..0fd3b7fe 100644 --- a/module/rolldata-ajustements.js +++ b/module/rolldata-ajustements.js @@ -74,8 +74,8 @@ export const referenceAjustements = { }, moral: { isVisible: (rollData, actor) => RdDCarac.isActionPhysique(rollData.selectedCarac), - isUsed: (rollData, actor) => rollData.use?.moral, - getLabel: (rollData, actor) => 'Moral', + isUsed: (rollData, actor) => rollData.use?.appelAuMoral, + getLabel: (rollData, actor) => 'Appel au moral', getValue: (rollData, actor) => 1 }, moralTotal: { diff --git a/styles/simple.css b/styles/simple.css index dbfe89da..d0f30f69 100644 --- a/styles/simple.css +++ b/styles/simple.css @@ -812,6 +812,22 @@ ul, li { text-align: center; } + +.diffAppelAuMoral { + display: none !important; +} +.diffAppelAuMoral-checker{ + display: inline-block; + background-image: url('../icons/moral-neutre.svg'); + width: 20px; + height: 20px; + background-size: cover; +} +.diffAppelAuMoral:checked + .diffAppelAuMoral-checker { + background-image: url('../icons/moral-heureux.svg'); +} + + /* ======================================== */ /* Fatigue CSS */ .table-fatigue { @@ -1391,4 +1407,4 @@ display: inline-flex; content : url(img/logo.png); width: 80px; height: 68px; -} \ No newline at end of file +} diff --git a/templates/chat-info-appel-au-moral.html b/templates/chat-info-appel-au-moral.html new file mode 100644 index 00000000..7b340d0f --- /dev/null +++ b/templates/chat-info-appel-au-moral.html @@ -0,0 +1,4 @@ +{{#if use.appelAuMoral}}
+ {{alias}} fait appel {{#if (gt moral 0)}}au moral{{else}}à l'énergie du déspoir{{/if}} {{#if moralDiminuer}}et échoue, diminuant son moral.{{else}} et réussit.{{/if}} + {{^moralDiminuer}} Son moral reste inchangé à {{moral}}.{{/moralDiminuer}} +
{{/if}} diff --git a/templates/chat-resultat-competence.html b/templates/chat-resultat-competence.html index 64e94f4d..8a46b0a8 100644 --- a/templates/chat-resultat-competence.html +++ b/templates/chat-resultat-competence.html @@ -12,6 +12,7 @@
{{#if rolled.ptTache}}{{rolled.ptTache}} points de tâche{{/if}}{{#if rolled.ptQualite}}{{#if rolled.ptTache}},{{/if}} ajustement Qualité {{numberFormat rolled.ptQualite decimals=0 sign=true}}{{/if}}
+{{> "systems/foundryvtt-reve-de-dragon/templates/chat-info-appel-au-moral.html"}} {{~#if show.explications}}
{{show.explications}} diff --git a/templates/dialog-competence.html b/templates/dialog-competence.html index 72817bb0..b0033a12 100644 --- a/templates/dialog-competence.html +++ b/templates/dialog-competence.html @@ -11,6 +11,8 @@
+ +
{{#if attackerRoll}} From 5ff38599741a7488fbf41977fe48c99dc6a841c1 Mon Sep 17 00:00:00 2001 From: LeFelis Date: Thu, 11 Feb 2021 20:31:04 +0100 Subject: [PATCH 2/3] Ajout de commentaire et suppression des logs --- module/actor.js | 17 +------ module/rdd-roll.js | 59 ++++++++++++------------- styles/simple.css | 18 +++++--- templates/chat-info-appel-au-moral.html | 2 +- templates/dialog-competence.html | 8 +++- 5 files changed, 48 insertions(+), 56 deletions(-) diff --git a/module/actor.js b/module/actor.js index f398355b..56df451a 100644 --- a/module/actor.js +++ b/module/actor.js @@ -1595,7 +1595,7 @@ export class RdDActor extends Actor { } /* -------------------------------------------- */ - createCallbackAppelAuMoral() { + createCallbackAppelAuMoral() { /* Si l'appel au moral est utilisé, on l'affiche dans le chat et on diminue éventuellement le moral */ return { condition: r => r.use.appelAuMoral && game.settings.get("core", "rollMode") != 'selfroll', action: r => { console.log("createCallbackAppelAuMoral"); this.displayAppelAuMoral ; console.log(r.rolled.isEchec); this._appliquerAppelMoral(r, game.settings.get("core", "rollMode") != 'blindroll') } @@ -1675,23 +1675,10 @@ export class RdDActor extends Actor { /* -------------------------------------------- */ async _appliquerAppelMoral(rollData, display = true) { - console.log("_appliquerAppelMoral"); - console.log("_appliquerAppelMoral"); - console.log("_appliquerAppelMoral"); - console.log("_appliquerAppelMoral"); - console.log(rollData); - console.log(this.name); - console.log(this); if (!this.isPersonnage()) return; if (!rollData.rolled.isEchec) return; const waitUpdate = this.moralIncDec(-1); /* L'appel au moral a échoué. Le personnage perd un point de moral */ - console.log("_appliquerAppelMoral : moral diminuer"); - rollData.moralDiminuer = true; - rollData.moralActualiser = 7; - await waitUpdate; - rollData.moralActualiser = this.getMoralTotal(); - console.log("rollData.moralDiminuer: "+rollData.moralDiminuer); - console.log("rollData.moralActualiser: "+rollData.moralActualiser); + rollData.jetEchouerMoralDiminuer = true; } /* -------------------------------------------- */ diff --git a/module/rdd-roll.js b/module/rdd-roll.js index 8d51628f..0b51a02a 100644 --- a/module/rdd-roll.js +++ b/module/rdd-roll.js @@ -46,17 +46,17 @@ export class RdDRoll extends Dialog { surencMalusFlag: actor.isPersonnage() ? (actor.data.data.compteurs.surenc.value < 0) : false, surencMalusValue: actor.getSurenc(), useMalusSurenc: false, - appelAuMoralDemander :false, - use: { libre:true, conditions: true, surenc: false, encTotal: false, appelAuMoral : false }, + appelAuMoralPossible : false, /* Est-ce que l'appel au moral est possible ? Variable utisé pour l'affichage ou non de la ligne concernant le moral */ + appelAuMoralDemander :false, /* Est-ce que le joueur demande d'utiliser le moral ? Utile si le joueur change plusieurs fois de carac associée. */ + jetEchouerMoralDiminuer : false, /* Pour l'affichage dans le chat */ + use: { libre:true, conditions: true, surenc: false, encTotal: false, appelAuMoral : false /* Le jet se fait ou non en utilisant l'appel au moral */}, isMalusEncombrementTotal: RdDItemCompetence.isMalusEncombrementTotal(rollData.competence), useMalusEncTotal: false, encTotal: actor.getEncTotal(), ajustementAstrologique: actor.ajustementAstrologique(), surprise: actor.getSurprise(false), } - console.log("defaultRollData.appelAuMoralFlag : "+defaultRollData.appelAuMoralFlag); mergeObject(rollData, defaultRollData, { recursive: true, overwrite: false }); - console.log("rollData.appelAuMoralFlag : "+rollData.appelAuMoralFlag); if ( rollData.forceCarac) { rollData.carac = rollData.forceCarac; } @@ -190,21 +190,25 @@ export class RdDRoll extends Dialog { this.rollData.useMalusEncTotal = event.currentTarget.checked; this.updateRollResult(); }); + html.find('#iconeSmile').change((event) => { + console.log("iconeSmile"); + console.log(html.find('.iconeSmile')); + this.updateRollResult(); + }); html.find('#useAppelAuMoralCheckbox').change((event) => { /* l'appel au moral, qui donne un bonus de +1 */ - - console.log("#useAppelAuMoralCheckbox"); - //console.log("surencMalusFlag : "+surencMalusFlag); - console.log("this.appelAuMoralFlag : "+this.appelAuMoralFlag); - console.log("this.rollData.moral : "+this.rollData.moral); - console.log("this.rollData.ajustements : "+this.rollData.ajustements); - console.log("this.rollData.ajustements.moral : "+this.rollData.ajustements.moral); - console.log("this.rollData.ajustements.moral.isVisible : "+this.rollData.ajustements.moral.isVisible); - console.log("event.currentTarget.checked : "+event.currentTarget.checked); - console.log("this.rollData.use.appelAuMoral : "+this.rollData.use.appelAuMoral); this.rollData.appelAuMoralDemander = event.currentTarget.checked - // this.rollData.use.appelAuMoral = event.currentTarget.checked - console.log("this.rollData.moral : "+this.rollData.moral); - console.log("this.rollData.use.appelAuMoral : "+this.rollData.use.appelAuMoral); + if ( this.rollData.appelAuMoralDemander ) { + if ( this.rollData.moral > 0 ) { + html.find('#iconeSmile')[0].src = "/systems/foundryvtt-reve-de-dragon/icons/moral-heureux.svg"; + html.find('#textSmile')[0].innerHTML = "Appel au moral"; + } else { + html.find('#iconeSmile')[0].src = "/systems/foundryvtt-reve-de-dragon/icons/moral-malheureux.svg"; + html.find('#textSmile')[0].innerHTML = "Appel à l'énergie du désespoir"; + } + } else { + html.find('#iconeSmile')[0].src = "/systems/foundryvtt-reve-de-dragon/icons/moral-neutre.svg"; + html.find('#textSmile')[0].innerHTML = "Sans appel au moral"; + } this.updateRollResult(); }); // Section Méditation @@ -231,28 +235,21 @@ export class RdDRoll extends Dialog { rollData.bonus = RdDItemSort.getCaseBonus(rollData.selectedSort, rollData.coord); } - /* ! actor.isPersonnage() || */ - if ( ! RdDCarac.isActionPhysique(rollData.selectedCarac) ) { - rollData.use.appelAuMoral = false; + if ( ! RdDCarac.isActionPhysique(rollData.selectedCarac || ! actor.isPersonnage() ) ) { + rollData.appelAuMoralPossible = false; + rollData.use.appelAuMoral = false; } else { - rollData.use.appelAuMoral = rollData.appelAuMoralDemander; + rollData.appelAuMoralPossible = true; + rollData.use.appelAuMoral = rollData.appelAuMoralDemander; + } RollDataAjustements.calcul(rollData, this.actor); rollData.finalLevel = this._computeFinalLevel(rollData); - console.log("updateRollResult"); - console.log("rollData.ajustements.moralTotal.used: "+rollData.ajustements.moralTotal.used); - console.log("rollData.ajustements.moral.used: "+rollData.ajustements.moral.used); - console.log("rollData.use.appelAuMoral: "+rollData.use.appelAuMoral); - console.log("rollData.selectedCarac: "); - console.log(rollData.selectedCarac); - console.log("RdDCarac.isActionPhysique(rollData.selectedCarac): "+RdDCarac.isActionPhysique(rollData.selectedCarac)); - HtmlUtility._showControlWhen($(".diffMoral"), rollData.ajustements.moralTotal.used); - HtmlUtility._showControlWhen($(".diffAppelAuMoral"), RdDCarac.isActionPhysique(rollData.selectedCarac) ); - HtmlUtility._showControlWhen($(".diffAppelAuMoral-checker"), RdDCarac.isActionPhysique(rollData.selectedCarac) ); + HtmlUtility._showControlWhen($("#divAppelAuMoral"), rollData.appelAuMoralPossible ); HtmlUtility._showControlWhen($("#etat-general"), !RdDCarac.isIgnoreEtatGeneral(rollData.selectedCarac, rollData.competence)); HtmlUtility._showControlWhen($("#ajust-astrologique"), RdDResolutionTable.isAjustementAstrologique(rollData)); diff --git a/styles/simple.css b/styles/simple.css index d0f30f69..94ebf9e2 100644 --- a/styles/simple.css +++ b/styles/simple.css @@ -811,22 +811,26 @@ ul, li { left: 0px; text-align: center; } - - .diffAppelAuMoral { display: none !important; } -.diffAppelAuMoral-checker{ - display: inline-block; - background-image: url('../icons/moral-neutre.svg'); - width: 20px; +.diffAppelAuMoral-checker { height: 20px; + background-image: url('../icons/moral-neutre.svg'); background-size: cover; } .diffAppelAuMoral:checked + .diffAppelAuMoral-checker { background-image: url('../icons/moral-heureux.svg'); } - +.iconeSmile { + height: 20px; + width: 20px; + border:none; + outline: none; + background-size: cover; +} +.textSmile { +} /* ======================================== */ /* Fatigue CSS */ diff --git a/templates/chat-info-appel-au-moral.html b/templates/chat-info-appel-au-moral.html index 7b340d0f..6ceef396 100644 --- a/templates/chat-info-appel-au-moral.html +++ b/templates/chat-info-appel-au-moral.html @@ -1,4 +1,4 @@ {{#if use.appelAuMoral}}
{{alias}} fait appel {{#if (gt moral 0)}}au moral{{else}}à l'énergie du déspoir{{/if}} {{#if moralDiminuer}}et échoue, diminuant son moral.{{else}} et réussit.{{/if}} - {{^moralDiminuer}} Son moral reste inchangé à {{moral}}.{{/moralDiminuer}} + {{^jetEchouerMoralDiminuer}} Son moral reste inchangé à {{moral}}.{{/jetEchouerMoralDiminuer}}
{{/if}} diff --git a/templates/dialog-competence.html b/templates/dialog-competence.html index b0033a12..4b0ab6e7 100644 --- a/templates/dialog-competence.html +++ b/templates/dialog-competence.html @@ -11,8 +11,6 @@
- -
{{#if attackerRoll}} @@ -61,6 +59,12 @@ {{/if}}
{{/if}} +
+ + + + +
{{>"systems/foundryvtt-reve-de-dragon/templates/dialog-roll-surenc.html"}} {{>"systems/foundryvtt-reve-de-dragon/templates/dialog-roll-enctotal.html"}} From aab7dc10203344d079ccf3bbae094706249b5bc1 Mon Sep 17 00:00:00 2001 From: LeFelis Date: Thu, 11 Feb 2021 20:44:50 +0100 Subject: [PATCH 3/3] Fix merge v1.3 dans appel au moral --- module/rdd-roll.js | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/module/rdd-roll.js b/module/rdd-roll.js index 04ed49d5..cf8d2a70 100644 --- a/module/rdd-roll.js +++ b/module/rdd-roll.js @@ -46,14 +46,10 @@ export class RdDRoll extends Dialog { surencMalusFlag: actor.isPersonnage() ? (actor.data.data.compteurs.surenc.value < 0) : false, surencMalusValue: actor.getSurenc(), useMalusSurenc: false, -<<<<<<< HEAD appelAuMoralPossible : false, /* Est-ce que l'appel au moral est possible ? Variable utisé pour l'affichage ou non de la ligne concernant le moral */ appelAuMoralDemander :false, /* Est-ce que le joueur demande d'utiliser le moral ? Utile si le joueur change plusieurs fois de carac associée. */ jetEchouerMoralDiminuer : false, /* Pour l'affichage dans le chat */ - use: { libre:true, conditions: true, surenc: false, encTotal: false, appelAuMoral : false /* Le jet se fait ou non en utilisant l'appel au moral */}, -======= - use: { libre: true, conditions: true, surenc: false, encTotal: false, }, ->>>>>>> v1.3 + use: { libre: true, conditions: true, surenc: false, encTotal: false, appelAuMoral : false /* Le jet se fait ou non en utilisant l'appel au moral */}, isMalusEncombrementTotal: RdDItemCompetence.isMalusEncombrementTotal(rollData.competence), useMalusEncTotal: false, encTotal: actor.getEncTotal(),