From e13b4c5206597939fad434f68188c7a5b537a320 Mon Sep 17 00:00:00 2001 From: GaboGG Date: Sun, 26 Jul 2026 13:38:31 -0400 Subject: [PATCH] v0.13.10 - Only consume channeling on buffs that need refresh (<10 turns) - findBestChannelingTarget: skip buffs with >10 remaining turns - When all buffs are fresh, falls through to cheap damage spell instead of wasting channeling on a nearly-full duration buff - This prevents recasting Spark of Life at 15 turns just because its score happens to be highest among all fresh buffs --- scripts/hv-unified.user.js | 2 ++ scripts/latest.user.js | 2 ++ src/strategy-engine.js | 2 ++ 3 files changed, 6 insertions(+) diff --git a/scripts/hv-unified.user.js b/scripts/hv-unified.user.js index 082dd49..5b3d9bb 100644 --- a/scripts/hv-unified.user.js +++ b/scripts/hv-unified.user.js @@ -881,6 +881,8 @@ function findBestChannelingTarget() { if (b.icon === 'regen' && STATE.hp >= CFG.cureRegenHP) continue; // Skip completely fresh Heartseeker (> 50 turns means just cast) if (b.icon === 'heartseeker' && dur > 50) continue; + // Only consider buffs that would benefit from a refresh + if (dur > 10) continue; // Still fresh, don't waste channeling const sp = findSpell(b.spell); const mpCost = sp ? sp.mp : 0; // Score: higher MP cost + lower remaining turns = better channeling target diff --git a/scripts/latest.user.js b/scripts/latest.user.js index 082dd49..5b3d9bb 100644 --- a/scripts/latest.user.js +++ b/scripts/latest.user.js @@ -881,6 +881,8 @@ function findBestChannelingTarget() { if (b.icon === 'regen' && STATE.hp >= CFG.cureRegenHP) continue; // Skip completely fresh Heartseeker (> 50 turns means just cast) if (b.icon === 'heartseeker' && dur > 50) continue; + // Only consider buffs that would benefit from a refresh + if (dur > 10) continue; // Still fresh, don't waste channeling const sp = findSpell(b.spell); const mpCost = sp ? sp.mp : 0; // Score: higher MP cost + lower remaining turns = better channeling target diff --git a/src/strategy-engine.js b/src/strategy-engine.js index 0dc15ff..f7edba8 100644 --- a/src/strategy-engine.js +++ b/src/strategy-engine.js @@ -233,6 +233,8 @@ function findBestChannelingTarget() { if (b.icon === 'regen' && STATE.hp >= CFG.cureRegenHP) continue; // Skip completely fresh Heartseeker (> 50 turns means just cast) if (b.icon === 'heartseeker' && dur > 50) continue; + // Only consider buffs that would benefit from a refresh + if (dur > 10) continue; // Still fresh, don't waste channeling const sp = findSpell(b.spell); const mpCost = sp ? sp.mp : 0; // Score: higher MP cost + lower remaining turns = better channeling target