Fix armors

This commit is contained in:
2022-08-26 18:54:40 +02:00
parent fa501abbd5
commit 35d500f24b
2 changed files with 5 additions and 5 deletions

View File

@ -752,10 +752,10 @@ export class CrucibleActor extends Actor {
let diceColor = armor.system.absorprionroll
let armorResult = await CrucibleUtility.getRollTableFromDiceColor( diceColor, false )
console.log("Armor log", armorResult)
let armorValue = (Number(armorResult.text) - reduce) * multiply
let armorValue = (Number(armorResult.text) + reduce) * multiply
if ( advantage || disadvantage) {
let armorResult2 = await CrucibleUtility.getRollTableFromDiceColor( diceColor, false )
let armorValue2 = (Number(armorResult2.text) - reduce) * multiply
let armorValue2 = (Number(armorResult2.text) + reduce) * multiply
if ( advantage) {
armorValue = (armorValue2 > armorValue) ? armorValue2 : armorValue
messages.push(`Armor advantage - Roll 1 = ${armorValue} - Roll 2 = ${armorValue2}`)