v10/v11 compatibility

This commit is contained in:
2023-05-25 07:23:25 +02:00
parent b1966412a0
commit 189411eef8
6 changed files with 49 additions and 14 deletions

View File

@@ -599,11 +599,17 @@ export class HawkmoonActor extends Actor {
}
console.log("DEGATS", arme)
let roll
let bonus = 0
if (rollDataInput?.isHeroique) {
roll = new Roll("2d10rr10+" + arme.system.totalDegats).roll({ async: false })
if (rollDataInput?.attaqueCharge) {
bonus = 5
}
roll = new Roll("2d10rr10+" + arme.system.totalDegats + "+" + bonus).roll({ async: false })
} else {
roll = new Roll("1d10+" + arme.system.totalDegats).roll({ async: false })
if (rollDataInput?.attaqueCharge) {
bonus = 3
}
roll = new Roll("1d10+" + arme.system.totalDegats + "+" + bonus).roll({ async: false })
}
await HawkmoonUtility.showDiceSoNice(roll, game.settings.get("core", "rollMode"));
let nbEtatPerdus = 0