From 49c7ce9cab4026988f72ce819ad1dfaebd13a5cc Mon Sep 17 00:00:00 2001 From: GaboGG Date: Sun, 26 Jul 2026 14:12:48 -0400 Subject: [PATCH] v0.13.18 - Add channeling score debug logging - Logs the top candidate from findBestChannelingTarget() on every Q press - Shows: spell, score, dur, maxDur, mpCost, emptiness% - Next time channeling doesn't fire on a buff, the console will show the actual computed scores so we can see what's happening --- scripts/hv-unified.user.js | 5 +++-- scripts/latest.user.js | 5 +++-- src/config.js | 2 +- src/header.user.js | 2 +- src/strategy-engine.js | 1 + 5 files changed, 9 insertions(+), 6 deletions(-) diff --git a/scripts/hv-unified.user.js b/scripts/hv-unified.user.js index ec45c86..8fcb6c7 100644 --- a/scripts/hv-unified.user.js +++ b/scripts/hv-unified.user.js @@ -1,7 +1,7 @@ // ==UserScript== // @name HV Unified // @namespace hvunified -// @version 0.13.17 +// @version 0.13.18 // @description HV Unified — battle automation, guidance, and UI enhancements for HentaiVerse // @author GaboGG + Hermes // @match *://*.hentaiverse.org/* @@ -17,7 +17,7 @@ // CONFIG — default settings // ═══════════════════════════════════════════════════════════════════════ -const VERSION = '0.13.17'; +const VERSION = '0.13.18'; const CFG = { // — Battle automation @@ -914,6 +914,7 @@ function findBestChannelingTarget() { if (candidates.length > 0) { candidates.sort((a, b) => b.score - a.score); + console.log(`%c[HV] ch score: ${candidates[0].spell}=${candidates[0].score.toFixed(1)} (dur=${candidates[0].dur}, max=${candidates[0].maxDur}, mp=${candidates[0].mpCost}, empty=${(candidates[0].emptiness*100).toFixed(0)}%)`, 'color:#bb0'); // Only use a buff if it actually needs refreshing (score >= 30 means // e.g. 30% emptiness on a 100-MP spell, or 60% on a 50-MP spell) if (candidates[0].score >= 30) { diff --git a/scripts/latest.user.js b/scripts/latest.user.js index ec45c86..8fcb6c7 100644 --- a/scripts/latest.user.js +++ b/scripts/latest.user.js @@ -1,7 +1,7 @@ // ==UserScript== // @name HV Unified // @namespace hvunified -// @version 0.13.17 +// @version 0.13.18 // @description HV Unified — battle automation, guidance, and UI enhancements for HentaiVerse // @author GaboGG + Hermes // @match *://*.hentaiverse.org/* @@ -17,7 +17,7 @@ // CONFIG — default settings // ═══════════════════════════════════════════════════════════════════════ -const VERSION = '0.13.17'; +const VERSION = '0.13.18'; const CFG = { // — Battle automation @@ -914,6 +914,7 @@ function findBestChannelingTarget() { if (candidates.length > 0) { candidates.sort((a, b) => b.score - a.score); + console.log(`%c[HV] ch score: ${candidates[0].spell}=${candidates[0].score.toFixed(1)} (dur=${candidates[0].dur}, max=${candidates[0].maxDur}, mp=${candidates[0].mpCost}, empty=${(candidates[0].emptiness*100).toFixed(0)}%)`, 'color:#bb0'); // Only use a buff if it actually needs refreshing (score >= 30 means // e.g. 30% emptiness on a 100-MP spell, or 60% on a 50-MP spell) if (candidates[0].score >= 30) { diff --git a/src/config.js b/src/config.js index c3e785d..08dc1df 100644 --- a/src/config.js +++ b/src/config.js @@ -2,7 +2,7 @@ // CONFIG — default settings // ═══════════════════════════════════════════════════════════════════════ -const VERSION = '0.13.17'; +const VERSION = '0.13.18'; const CFG = { // — Battle automation diff --git a/src/header.user.js b/src/header.user.js index 9e955d6..04ed7e9 100644 --- a/src/header.user.js +++ b/src/header.user.js @@ -1,7 +1,7 @@ // ==UserScript== // @name HV Unified // @namespace hvunified -// @version 0.13.17 +// @version 0.13.18 // @description HV Unified — battle automation, guidance, and UI enhancements for HentaiVerse // @author GaboGG + Hermes // @match *://*.hentaiverse.org/* diff --git a/src/strategy-engine.js b/src/strategy-engine.js index cc20624..292a171 100644 --- a/src/strategy-engine.js +++ b/src/strategy-engine.js @@ -251,6 +251,7 @@ function findBestChannelingTarget() { if (candidates.length > 0) { candidates.sort((a, b) => b.score - a.score); + console.log(`%c[HV] ch score: ${candidates[0].spell}=${candidates[0].score.toFixed(1)} (dur=${candidates[0].dur}, max=${candidates[0].maxDur}, mp=${candidates[0].mpCost}, empty=${(candidates[0].emptiness*100).toFixed(0)}%)`, 'color:#bb0'); // Only use a buff if it actually needs refreshing (score >= 30 means // e.g. 30% emptiness on a 100-MP spell, or 60% on a 50-MP spell) if (candidates[0].score >= 30) {