Ameliorations lancer de sort

This commit is contained in:
2021-02-02 07:56:45 +01:00
parent be796a7169
commit d24b9c07fa
4 changed files with 56 additions and 7 deletions

View File

@ -120,6 +120,9 @@ export class RdDRoll extends Dialog {
rollData.selectedCarac = rollData.carac[rollData.competence.data.defaut_carac];
$("#carac").val(rollData.competence.data.defaut_carac);
}
if (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));
$("#diffConditions").val(Misc.toInt(rollData.diffConditions));
@ -153,6 +156,7 @@ export class RdDRoll extends Dialog {
this.rollData.selectedSort = this.rollData.sortList[sortKey]; // Update the selectedCarac
this.rollData.bonus = RdDItemSort.getCaseBonus(this.rollData.selectedSort, this.rollData.coord);
RdDItemSort.setCoutReveReel(this.rollData.selectedSort);
$("#draconic").val( this.rollData.selectedSort.data.listIndex ); // Uniquement a la selection du sort, pour permettre de changer
this.updateRollResult();
});
html.find('#ptreve-variable').change((event) => {