From 7cd378e434abbb22aad4238a9ba1b5a103288174 Mon Sep 17 00:00:00 2001 From: Matheus Clemente Date: Mon, 10 Jun 2024 17:04:28 -0300 Subject: [PATCH] Update Combat.js Fix #17. --- Combat.js | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/Combat.js b/Combat.js index cbad7a1..fab062b 100644 --- a/Combat.js +++ b/Combat.js @@ -29,7 +29,12 @@ class FurnaceCombatQoL { const combatTracker = html.find("#combat-tracker"); if (!combatTracker[0].children.length) return; getInitiatives(combatTracker); - let TokenInitiative = html.find(".token-initiative"); + const TokenInitiative = html.find(".token-initiative"); + TokenInitiative.find(".initiative").on("dblclick", FurnaceCombatQoL._onInitiativeDblClick); + TokenInitiative.find(".combatant-control.roll").on("contextmenu", (event) => { + const cid = event.target.closest(".combatant").dataset.combatantId; + game.combat.setInitiative(cid, 0); + }); if (orderButtons || revertButton) { TokenInitiative.before("
");