From 75d562f9224757f14b32d9e5f8caa01a62580a75 Mon Sep 17 00:00:00 2001 From: LeRatierBretonnien Date: Sat, 25 Mar 2023 08:42:14 +0100 Subject: [PATCH] Nouvelle option d'ignorer les dommages --- lang/fr.json | 4 ++-- module/system/bol-utility.js | 4 ++-- system.json | 4 ++-- templates/chat/rolls/defense-request-card.hbs | 4 +++- 4 files changed, 9 insertions(+), 7 deletions(-) diff --git a/lang/fr.json b/lang/fr.json index 013dbf0..5d73864 100644 --- a/lang/fr.json +++ b/lang/fr.json @@ -577,6 +577,6 @@ "BOL.chat.welcome3": "Les cartes intégrées au système le sont grace à l'aimable autorisation de leur auteur Guillaume Tavernier et des éditions Ludospherik. Merci à eux !.", "BOL.chat.welcome4": "Tout le support et le suivi de ce système est disponible via le Discord Foundry FR.", "BOL.chat.welcome5": "Consulter l'aide en ligne pour plus d'informations : @UUID[Compendium.bol.aides-de-jeu.97rugQOtiwt8zPfQ]{Aide du Jeu}.", - "BOL.chat.welcome6": "Bon jeu en Lemurie !" - + "BOL.chat.welcome6": "Bon jeu en Lemurie !", + "BOL.chat.nodamage": "Ne pas appliquer les dommages" } \ No newline at end of file diff --git a/module/system/bol-utility.js b/module/system/bol-utility.js index c27ccb7..8d3882c 100644 --- a/module/system/bol-utility.js +++ b/module/system/bol-utility.js @@ -422,14 +422,14 @@ export class BoLUtility { console.log("Damage Handling", attackId, defenseMode, weaponId) // Only GM process this if (rollData && rollData.defenderId) { - if (rollData.defenseDone) { + if (rollData.defenseDone || defenseMode == 'damage-not-applied') { return } // ?? Why ??? rollData.defenseDone = true rollData.defenseMode = defenseMode let token = game.scenes.current.tokens.get(rollData.targetId) let defender = token.actor - + if (defenseMode == 'damage-with-armor') { let armorFormula = defender.getArmorFormula() rollData.rollArmor = new Roll(armorFormula) diff --git a/system.json b/system.json index c4ad482..a9fcd69 100644 --- a/system.json +++ b/system.json @@ -14,7 +14,7 @@ ], "url": "https://www.uberwald.me/gitea/public/bol", "license": "LICENSE.txt", - "version": "10.5.10", + "version": "10.5.11", "compatibility": { "minimum": "10", "verified": "10" @@ -202,7 +202,7 @@ ], "socket": true, "manifest": "https://www.uberwald.me/gitea/public/bol/raw/v10/system.json", - "download": "https://www.uberwald.me/gitea/public/bol/archive/bol-v10.5.10.zip", + "download": "https://www.uberwald.me/gitea/public/bol/archive/bol-v10.5.11.zip", "background": "systems/bol/ui/page_accueil.webp", "gridDistance": 1.5, "gridUnits": "m", diff --git a/templates/chat/rolls/defense-request-card.hbs b/templates/chat/rolls/defense-request-card.hbs index 3ac7c24..e41135d 100644 --- a/templates/chat/rolls/defense-request-card.hbs +++ b/templates/chat/rolls/defense-request-card.hbs @@ -6,7 +6,7 @@ {{/if}} - + {{#if defender.system.resources.hero.value}} @@ -15,4 +15,6 @@ {{/each}} + + {{/if}} \ No newline at end of file