diff --git a/modules/hawkmoon-actor.js b/modules/hawkmoon-actor.js index 1153e5b..6a8bf16 100644 --- a/modules/hawkmoon-actor.js +++ b/modules/hawkmoon-actor.js @@ -76,6 +76,7 @@ export class HawkmoonActor extends Actor { arme.system.totalDegats = arme.system.degats + "+" + combat.bonusDegatsTotal arme.system.totalOffensif = this.system.attributs.pui.value + arme.system.competence.system.niveau + arme.system.bonusmaniementoff arme.system.totalDefensif = combat.defenseTotal + arme.system.competence.system.niveau + arme.system.seuildefense + bonusDefense + console.log("Arme", arme.system.totalDefensif, combat, arme.system.competence.system.niveau, arme.system.seuildefense, bonusDefense) arme.system.isdefense = true arme.system.isMelee = true arme.system.isDistance = false @@ -175,7 +176,7 @@ export class HawkmoonActor extends Actor { /* -------------------------------------------- */ getDefenseBase() { - return Math.max(this.system.attributs.tre.value, this.system.attributs.pui.value) + return Math.max(this.system.attributs.tre.value, this.system.attributs.adr.value) } /* -------------------------------------------- */ @@ -185,7 +186,7 @@ export class HawkmoonActor extends Actor { /* -------------------------------------------- */ getProtection() { let equipProtection = 0 - for (let armor in this.items) { + for (let armor of this.items) { if (armor.type == "protection" && armor.system.equipped) { equipProtection += Number(armor.system.protection) } diff --git a/modules/hawkmoon-utility.js b/modules/hawkmoon-utility.js index e6f345d..3e49a93 100644 --- a/modules/hawkmoon-utility.js +++ b/modules/hawkmoon-utility.js @@ -716,11 +716,11 @@ export class HawkmoonUtility { /* -------------------------------------------- */ static async confirmDelete(actorSheet, li) { let itemId = li.data("item-id"); - let msgTxt = "
Are you sure to remove this Item ?"; + let msgTxt = "
Etes vous certain de vouloir supprimer cet item ?"; let buttons = { delete: { icon: '', - label: "Yes, remove it", + label: "Oui !", callback: () => { actorSheet.actor.deleteEmbeddedDocuments("Item", [itemId]); li.slideUp(200, () => actorSheet.render(false)); @@ -728,12 +728,12 @@ export class HawkmoonUtility { }, cancel: { icon: '', - label: "Cancel" + label: "Non" } } msgTxt += "
"; let d = new Dialog({ - title: "Confirm removal", + title: "Confirmer la suppression", content: msgTxt, buttons: buttons, default: "cancel" @@ -752,7 +752,6 @@ export class HawkmoonUtility { console.log(entryData) htmlTab += `