diff --git a/module/actor.js b/module/actor.js index dcf92e44..7624b3df 100644 --- a/module/actor.js +++ b/module/actor.js @@ -184,19 +184,19 @@ export class RdDActor extends RdDBaseActor { } /* -------------------------------------------- */ getChance() { - return Misc.toInt(this.system.carac.chance?.value ?? 10); + return Number(this.system.carac.chance?.value ?? 10); } getMoralTotal() { - return Misc.toInt(this.system.compteurs.moral?.value); + return Number(this.system.compteurs.moral?.value ?? 0); } /* -------------------------------------------- */ getBonusDegat() { // TODO: gérer séparation et +dom créature/entité indépendament de la compétence - return Misc.toInt(this.system.attributs.plusdom.value); + return Number(this.system.attributs.plusdom.value ?? 0); } /* -------------------------------------------- */ getProtectionNaturelle() { - return Misc.toInt(this.system.attributs.protection.value); + return Number(this.system.attributs.protection.value ?? 0); } /* -------------------------------------------- */ @@ -1799,8 +1799,8 @@ export class RdDActor extends RdDBaseActor { ethylismeData.jetVolonte = { selectedCarac: this.system.carac.volonte, caracValue: this.system.carac.volonte.value, - ethylisme: ethylisme.value, - finalLevel: ethylisme.value + this.system.compteurs.moral.value + ethylisme: Number(ethylisme.value), + finalLevel: Number(ethylisme.value) + Number(this.system.compteurs.moral.value) } await RdDResolutionTable.rollData(ethylismeData.jetVolonte); this._appliquerExperienceRollData(ethylismeData.jetVolonte);