simplification ajust. écaille

This commit is contained in:
Vincent Vandemeulebrouck 2021-02-06 01:36:02 +01:00
parent fe73e5b984
commit cfef9a559d

View File

@ -94,10 +94,10 @@ export const referenceAjustements = {
getDescr: (rollData, actor) => rollData.diviseurSignificative > 1 ? `Facteur significative <span class="rdd-diviseur">&times;${Misc.getFractionHtml(rollData.diviseurSignificative)}</span>` : '' getDescr: (rollData, actor) => rollData.diviseurSignificative > 1 ? `Facteur significative <span class="rdd-diviseur">&times;${Misc.getFractionHtml(rollData.diviseurSignificative)}</span>` : ''
}, },
isEcaille: { isEcaille: {
isVisible: (rollData, actor) => rollData.arme && rollData.arme.data.magique && Number(rollData.arme.data.ecaille_efficacite) > 0, isVisible: (rollData, actor) => rollData.arme?.data.magique && Number(rollData.arme?.data.ecaille_efficacite) > 0,
isUsed: (rollData, actor) => rollData.arme && rollData.arme.data.magique && Number(rollData.arme.data.ecaille_efficacite) > 0, isUsed: (rollData, actor) => rollData.arme?.data.magique && Number(rollData.arme?.data.ecaille_efficacite) > 0,
getLabel: (rollData, actor) => "Ecaille d'Efficacité: ", getLabel: (rollData, actor) => "Ecaille d'Efficacité: ",
getValue: (rollData, actor) => (rollData.arme && rollData.arme.data.magique && Number(rollData.arme.data.ecaille_efficacite) > 0) ? rollData.arme.data.ecaille_efficacite : 0, getValue: (rollData, actor) => (rollData.arme?.data.magique && Number(rollData.arme.data.ecaille_efficacite) > 0) ? rollData.arme.data.ecaille_efficacite : 0,
}, },
finesse: { finesse: {
isUsed: (rollData, actor) => RdDBonus.isDefenseAttaqueFinesse(rollData), isUsed: (rollData, actor) => RdDBonus.isDefenseAttaqueFinesse(rollData),