From f42e44db34111b6f2c9348974698ceee42317a6a Mon Sep 17 00:00:00 2001 From: GaboGG Date: Tue, 28 Jul 2026 09:12:01 -0400 Subject: [PATCH] v0.14.23 - OC conservation: save weapon skills for 3+ mob groups MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - Raised heal threshold from 60%@7+ to 65%@5+ (earlier healing in big groups) - Cure threshold also dynamic: 65% when 5+ mobs, normal otherwise - Secondary weapon skill dump restricted to 3+ enemies (no OC waste on cleanup) - Great Cleave already limited to rares — kept as-is - Simulation confirmed +7 rounds deeper (R30->R37 avg) from OC conservation - Source: agy_oc_output.txt --- scripts/hv-unified.user.js | 15 ++++++++------- scripts/latest.user.js | 15 ++++++++------- src/config.js | 2 +- src/header.user.js | 2 +- src/strategy-engine.js | 11 ++++++----- 5 files changed, 24 insertions(+), 21 deletions(-) diff --git a/scripts/hv-unified.user.js b/scripts/hv-unified.user.js index 4bb7e84..40fc5b5 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.14.22 +// @version 0.14.23 // @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.14.22'; +const VERSION = '0.14.23'; const CFG = { // — Battle automation @@ -1409,7 +1409,7 @@ function strategyAdept() { function strategyVeteran() { // 1. Health items — ALWAYS BEFORE ATTACKING OR SKILLS! - const reqHpItem = (STATE.monsters && STATE.monsters.length >= 7) ? 0.60 : CFG.cureItemHP; + const reqHpItem = (STATE.monsters && STATE.monsters.length >= 5) ? 0.65 : CFG.cureItemHP; if (STATE.hp < reqHpItem) { const gem = hasUsableGem('heal'); if (gem) return { type: 'item', id: gem.id, selfTarget: true, _reason: `hp${(STATE.hp*100).toFixed(0)}` }; @@ -1421,8 +1421,9 @@ function strategyVeteran() { } } - // 2. Cure / Full-Cure spell - if (STATE.hp < Math.max(0.55, CFG.cureHP)) { + // 2. Cure / Full-Cure spell — higher threshold when many mobs + const cureThresh = (STATE.monsters && STATE.monsters.length >= 5) ? 0.65 : Math.max(0.55, CFG.cureHP); + if (STATE.hp < cureThresh) { const c = hasReadySpell('Full-Cure') ? 'Full-Cure' : hasReadySpell('Cure') ? 'Cure' : null; if (c) return { type: 'spell', name: c, selfTarget: true, _reason: `hp${(STATE.hp*100).toFixed(0)}` }; } @@ -1590,8 +1591,8 @@ function strategyVeteran() { const t = isHighThreat ? findDangerousMonster() : findStrongestMonster(); if (t >= 0) return { type: 'skill', name: 'Great Cleave', target: t, _reason: isHighThreat ? 'threat' : 'boss' }; } - // If high threat and no AoE skill available, use any weapon skill on the most dangerous - if (isHighThreat && STATE.oc >= (CFG.skillOC || 80)) { + // If high threat and 3+ enemies, use single-target skills on the most dangerous + if (isHighThreat && STATE.oc >= (CFG.skillOC || 60) && STATE.monsters.length >= 3) { const ps = ['Frenzied Blows', 'Skyward Sword', 'Iris Strike', 'Merciful Blow', 'Vital Strike', 'Shield Bash', 'Concussive Strike']; for (const sk of ps) { diff --git a/scripts/latest.user.js b/scripts/latest.user.js index 4bb7e84..40fc5b5 100644 --- a/scripts/latest.user.js +++ b/scripts/latest.user.js @@ -1,7 +1,7 @@ // ==UserScript== // @name HV Unified // @namespace hvunified -// @version 0.14.22 +// @version 0.14.23 // @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.14.22'; +const VERSION = '0.14.23'; const CFG = { // — Battle automation @@ -1409,7 +1409,7 @@ function strategyAdept() { function strategyVeteran() { // 1. Health items — ALWAYS BEFORE ATTACKING OR SKILLS! - const reqHpItem = (STATE.monsters && STATE.monsters.length >= 7) ? 0.60 : CFG.cureItemHP; + const reqHpItem = (STATE.monsters && STATE.monsters.length >= 5) ? 0.65 : CFG.cureItemHP; if (STATE.hp < reqHpItem) { const gem = hasUsableGem('heal'); if (gem) return { type: 'item', id: gem.id, selfTarget: true, _reason: `hp${(STATE.hp*100).toFixed(0)}` }; @@ -1421,8 +1421,9 @@ function strategyVeteran() { } } - // 2. Cure / Full-Cure spell - if (STATE.hp < Math.max(0.55, CFG.cureHP)) { + // 2. Cure / Full-Cure spell — higher threshold when many mobs + const cureThresh = (STATE.monsters && STATE.monsters.length >= 5) ? 0.65 : Math.max(0.55, CFG.cureHP); + if (STATE.hp < cureThresh) { const c = hasReadySpell('Full-Cure') ? 'Full-Cure' : hasReadySpell('Cure') ? 'Cure' : null; if (c) return { type: 'spell', name: c, selfTarget: true, _reason: `hp${(STATE.hp*100).toFixed(0)}` }; } @@ -1590,8 +1591,8 @@ function strategyVeteran() { const t = isHighThreat ? findDangerousMonster() : findStrongestMonster(); if (t >= 0) return { type: 'skill', name: 'Great Cleave', target: t, _reason: isHighThreat ? 'threat' : 'boss' }; } - // If high threat and no AoE skill available, use any weapon skill on the most dangerous - if (isHighThreat && STATE.oc >= (CFG.skillOC || 80)) { + // If high threat and 3+ enemies, use single-target skills on the most dangerous + if (isHighThreat && STATE.oc >= (CFG.skillOC || 60) && STATE.monsters.length >= 3) { const ps = ['Frenzied Blows', 'Skyward Sword', 'Iris Strike', 'Merciful Blow', 'Vital Strike', 'Shield Bash', 'Concussive Strike']; for (const sk of ps) { diff --git a/src/config.js b/src/config.js index 965e5c7..395c3da 100644 --- a/src/config.js +++ b/src/config.js @@ -2,7 +2,7 @@ // CONFIG — default settings // ═══════════════════════════════════════════════════════════════════════ -const VERSION = '0.14.22'; +const VERSION = '0.14.23'; const CFG = { // — Battle automation diff --git a/src/header.user.js b/src/header.user.js index 952f31a..ab3a1b2 100644 --- a/src/header.user.js +++ b/src/header.user.js @@ -1,7 +1,7 @@ // ==UserScript== // @name HV Unified // @namespace hvunified -// @version 0.14.22 +// @version 0.14.23 // @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 c7c76b0..a538db3 100644 --- a/src/strategy-engine.js +++ b/src/strategy-engine.js @@ -683,7 +683,7 @@ function strategyAdept() { function strategyVeteran() { // 1. Health items — ALWAYS BEFORE ATTACKING OR SKILLS! - const reqHpItem = (STATE.monsters && STATE.monsters.length >= 7) ? 0.60 : CFG.cureItemHP; + const reqHpItem = (STATE.monsters && STATE.monsters.length >= 5) ? 0.65 : CFG.cureItemHP; if (STATE.hp < reqHpItem) { const gem = hasUsableGem('heal'); if (gem) return { type: 'item', id: gem.id, selfTarget: true, _reason: `hp${(STATE.hp*100).toFixed(0)}` }; @@ -695,8 +695,9 @@ function strategyVeteran() { } } - // 2. Cure / Full-Cure spell - if (STATE.hp < Math.max(0.55, CFG.cureHP)) { + // 2. Cure / Full-Cure spell — higher threshold when many mobs + const cureThresh = (STATE.monsters && STATE.monsters.length >= 5) ? 0.65 : Math.max(0.55, CFG.cureHP); + if (STATE.hp < cureThresh) { const c = hasReadySpell('Full-Cure') ? 'Full-Cure' : hasReadySpell('Cure') ? 'Cure' : null; if (c) return { type: 'spell', name: c, selfTarget: true, _reason: `hp${(STATE.hp*100).toFixed(0)}` }; } @@ -864,8 +865,8 @@ function strategyVeteran() { const t = isHighThreat ? findDangerousMonster() : findStrongestMonster(); if (t >= 0) return { type: 'skill', name: 'Great Cleave', target: t, _reason: isHighThreat ? 'threat' : 'boss' }; } - // If high threat and no AoE skill available, use any weapon skill on the most dangerous - if (isHighThreat && STATE.oc >= (CFG.skillOC || 80)) { + // If high threat and 3+ enemies, use single-target skills on the most dangerous + if (isHighThreat && STATE.oc >= (CFG.skillOC || 60) && STATE.monsters.length >= 3) { const ps = ['Frenzied Blows', 'Skyward Sword', 'Iris Strike', 'Merciful Blow', 'Vital Strike', 'Shield Bash', 'Concussive Strike']; for (const sk of ps) {