Fix bonus de case sorts
This commit is contained in:
parent
a380876ea6
commit
a99a08ab21
@ -114,7 +114,7 @@ export class RdDItemSort extends Item {
|
|||||||
let bonusCaseList = this.buildBonusCaseList(sort.data.bonuscase, false);
|
let bonusCaseList = this.buildBonusCaseList(sort.data.bonuscase, false);
|
||||||
for( let bc of bonusCaseList) {
|
for( let bc of bonusCaseList) {
|
||||||
if (bc.case == coordTMR) { // Case existante
|
if (bc.case == coordTMR) { // Case existante
|
||||||
return bc.bonus;
|
return Number(bc.bonus);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return 0;
|
return 0;
|
||||||
|
@ -134,7 +134,7 @@ export class RdDResolutionTable {
|
|||||||
/* -------------------------------------------- */
|
/* -------------------------------------------- */
|
||||||
static _updateChancesWithBonus(chances, bonus) {
|
static _updateChancesWithBonus(chances, bonus) {
|
||||||
if (bonus) {
|
if (bonus) {
|
||||||
let newScore = chances.score + bonus;
|
let newScore = Number(chances.score) + bonus;
|
||||||
mergeObject(chances, this._computeCell(null, newScore), { overwrite: true });
|
mergeObject(chances, this._computeCell(null, newScore), { overwrite: true });
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user