Fix recul

This commit is contained in:
Vincent Vandemeulebrouck 2020-12-08 21:42:38 +01:00
parent 468c699f70
commit e46bcce2da

View File

@ -207,7 +207,7 @@ export class RdDActor extends Actor {
}
/* -------------------------------------------- */
computeRecul( rollData ) { // Calcul du recul (p. 132)
computeRecul( rollData, encaisser = undefined ) { // Calcul du recul (p. 132)
if ( rollData.arme || encaisser ) {
if ( (rollData.attackerRoll.particuliereAttaque && rollData.attackerRoll.particuliereAttaque == 'force') || rollData.attackerRoll.isCharge) {
let reculNiveau = this.data.data.taille.value - (rollData.attackerRoll.forceValue+rollData.attackerRoll.arme.dommages);
@ -272,7 +272,6 @@ export class RdDActor extends Actor {
if (rollData.needSignificative)
explications += " Significative nécessaire!";
}
this.computeRecul( rollData );
encaisser = rollData.needSignificative ? !rolled.isSign : !rolled.isSuccess;
this.computeRecul( rollData, encaisser );
} else { // This is the attack roll!