|
|
|
HV Script Thread, Discuss your creations. Includes guidelines and infos for script creation (2020-02-28 upd) |
|
Jun 27 2017, 10:46
|
nekolor
Group: Members
Posts: 123
Joined: 16-June 14
|
QUOTE(cbn @ Jun 27 2017, 00:28) excuse me noBlinking: true, // Disable buff/debuff blinking showMonHP: true, // Show enemy HP value the above 2 didnt work for me the browser I used is CHROME ver. 59.0.3071.115 wat's wrong with me? (IMG:[ invalid] style_emoticons/default/laugh.gif) noBlinking is commented out — it doesn't work now and I don't know what exactly it did before to achieve its goal so I could fix it. showMonHP — What's wrong? I dunno. Perhaps, using Chrome? Works fine in Firefox for me. QUOTE(dmyers59 @ Jun 27 2017, 03:47) Has anyone been able to resurrect HV Track Drop in Battle in the 0.85 environment?
Unless there's some other TD you talk about I'm not aware of, the one I have posted recently works. You may have change '@match' in the beginning to "https://*.hentaiverse.org/*" or even "*://*.hentaiverse.org/*" if you're not using default HV over HTTPS. QUOTE(Hakrei @ Jun 27 2017, 07:52) This might just be me but whenever I switch to ultiltarian mode Sapo`s MouseMagelee stops working completely until I switch back to standard. Is that script not compatible with ultilarian mode? I'm on chrome via tampermoneky btw...
Because it doesn't support those bars? Anyway, it should use functions like those to get stats to make them work and not break from a slightest CSS change: CODE function getPlayerHP() {var el=document.querySelector('#vbh') || document.querySelector('#dvbh'); if (el) return el.firstChild.firstChild.width/el.offsetWidth}; function getPlayerMP() {var el=document.querySelector('#vbm') || document.querySelector('#dvbm'); if (el) return el.firstChild.firstChild.width/el.offsetWidth}; function getPlayerSP() {var el=document.querySelector('#vbs') || document.querySelector('#dvbs'); if (el) return el.firstChild.firstChild.width/el.offsetWidth};
QUOTE(Gambit126 @ Jun 27 2017, 09:52) Okay, no matter what script I try, either the new HV Clean UI or the new HV Battle Reloaded, allow me to see the gem Icon when one drops. ... Edit: Evidently for HV Clean UI "ikeyp.innerHTML.match(...) is null" For HV Battle Reloaded "gem.children[0].children[0].textContent.match(...) is null"
You probably have something (userscript) making names of gems non-standard or using HV default graphic font. Code now relies on literal text you can see in the item pane. This post has been edited by nekolor: Jun 27 2017, 10:49
|
|
|
|
|
|
Jun 27 2017, 11:00
|
friggo
Group: Gold Star Club
Posts: 2,134
Joined: 9-October 14
|
QUOTE(nekolor @ Jun 27 2017, 11:46) Unless there's some other TD you talk about I'm not aware of, the one I have posted recently works. You may have change '@match' in the beginning to "https://*.hentaiverse.org/*" or even "*://*.hentaiverse.org/*" if you're not using default HV over HTTPS. He's talking about the one that automatically shows loot immediately after battle (made by NerfThis, I believe). Like so:
|
|
|
|
|
|
Jun 27 2017, 11:14
|
Gambit126
Group: Members
Posts: 301
Joined: 27-September 15
|
QUOTE(nekolor @ Jun 27 2017, 04:46) noBlinking is commented out — it doesn't work now and I don't know what exactly it did before to achieve its goal so I could fix it. showMonHP — What's wrong? I dunno. Perhaps, using Chrome? Works fine in Firefox for me. Unless there's some other TD you talk about I'm not aware of, the one I have posted recently works. You may have change '@match' in the beginning to "https://*.hentaiverse.org/*" or even "*://*.hentaiverse.org/*" if you're not using default HV over HTTPS. Because it doesn't support those bars? Anyway, it should use functions like those to get stats to make them work and not break from a slightest CSS change: CODE function getPlayerHP() {var el=document.querySelector('#vbh') || document.querySelector('#dvbh'); if (el) return el.firstChild.firstChild.width/el.offsetWidth}; function getPlayerMP() {var el=document.querySelector('#vbm') || document.querySelector('#dvbm'); if (el) return el.firstChild.firstChild.width/el.offsetWidth}; function getPlayerSP() {var el=document.querySelector('#vbs') || document.querySelector('#dvbs'); if (el) return el.firstChild.firstChild.width/el.offsetWidth};
You probably have something (userscript) making names of gems non-standard or using HV default graphic font. Code now relies on literal text you can see in the item pane. The only other script I am using right now is HV Random Encounter Notification and I don't think it does anything with gems. I've always used the default font, even when I was using Chrome 49.
|
|
|
|
|
|
Jun 27 2017, 11:16
|
pooaa
Group: Gold Star Club
Posts: 645
Joined: 20-July 14
|
QUOTE(Scremaz @ Jun 27 2017, 16:36) patience, i'd say
i realize how i rely on it that i am too lazy to check whether the equip is junk or not (IMG:[ invalid] style_emoticons/default/cry.gif)
|
|
|
Jun 27 2017, 11:31
|
nekolor
Group: Members
Posts: 123
Joined: 16-June 14
|
QUOTE(Gambit126 @ Jun 27 2017, 11:14) I've always used the default font, even when I was using Chrome 49.
And that's the issue, of all the scripts reading something from page most don't support that pseudo-font and the rest shouldn't support such ridiculous abomination.
|
|
|
Jun 27 2017, 12:41
|
Usagi =
Group: Gold Star Club
Posts: 2,923
Joined: 29-October 13
|
Is anyone close to finishing work on the mega script?
Cause I just came back from vacation and I feel like making an attempt if its not too late.
I understand that Cupcake and Nekolor are already working on it.
|
|
|
Jun 27 2017, 12:44
|
Scremaz
Group: Gold Star Club
Posts: 24,304
Joined: 18-January 07
|
QUOTE(LOL50015 @ Jun 27 2017, 12:41) Is anyone close to finishing work on the mega script?
Cause I just came back from vacation and I feel like making an attempt if its not too late.
I understand that Cupcake and Nekolor are already working on it.
give it a try. contacting another coder and working on a module is fine as well. we have sort of a temporary workaround afaik, so i'd say it's better to go for a better solution than a quicker one. This post has been edited by Scremaz: Jun 27 2017, 12:45
|
|
|
|
|
|
Jun 27 2017, 13:15
|
lololo16
Group: Gold Star Club
Posts: 2,836
Joined: 5-March 12
|
QUOTE(nekolor @ Jun 27 2017, 06:31) And that's the issue, of all the scripts reading something from page most don't support that pseudo-font and the rest shouldn't support such ridiculous abomination.
So it was the font... Dx Now sickentide's script is working. Thank you :D
|
|
|
Jun 27 2017, 13:45
|
Gambit126
Group: Members
Posts: 301
Joined: 27-September 15
|
QUOTE(nekolor @ Jun 27 2017, 05:31) And that's the issue, of all the scripts reading something from page most don't support that pseudo-font and the rest shouldn't support such ridiculous abomination.
So are you saying that I need to set a custom font to get the script to work properly? If so, what settings do I need for the font and how do I get it on my computer to make the settings?
|
|
|
|
|
|
Jun 27 2017, 13:54
|
hentai_fusion
Group: Gold Star Club
Posts: 33,488
Joined: 14-August 09
|
QUOTE(nekolor @ Jun 27 2017, 02:24) Ok, rolling out. Major one: HV Battle Reloaded — essentially ex- Reloader with all obsolete AJAXing taken out and some of my fixes and additions I had for some time and didn't get to post before.
HV_Battle_Reloaded.user.js.txt ( 22.15k )
Number of downloads: 1656Settings excerpt with available features if you don't remember/know: CODE title: 'HVerse', // Page title replacement effectDurations: true, // Show buff/debuff durations gemIcon: true, // Show gem/powerup, click on icon to use roundCounter: true, // Show current round and rounds remaining showMonHP: false, // Show enemy HP value resizeHPBars: true, // Shorten HP Bar width to easily see which monster has the most HP sparkAlert: true, // Show alert when Spark of Life triggers skipTurnKey: 90, // Key code for Skip Turn (using Scan skill randomly); 90='z', 0 to disable defaultAction: 0, // Change the default action to a T1 spell // | 0 | 1 | 2 | 3 | 4 | 5 | 6 | // | No Change | Fiery Blast | Freeze | Shockblast | Gale | Smite | Corruption |
mouseMelee: false, // MouseMelee ( hover on enemies to attack ) minHP: 0.35, // Stop if hp is below this threshold minMP: 0.2 , // Stop if mp ... minSP: 0.3, // Stop if sp ... stopWhenChanneling: true, // Stop if you have channeling buff chromeFix: false, // Fix MM things on chrome by manually tracking cursor movement
battleLog: true, // Show battle log
skipToNextRound: true, // Auto-advance to next round popupTime: 800, // after `popupTime`ms
counterPlus: true, // HV-Counter-Plus; log and show turn/speed/time/exp/credits counterPlusSave: false // Store additional datas for Income Summary by Superlatanium And stuff from others, up-to-date and sometimes with minor changes I don't remember (IMG:[ invalid] style_emoticons/default/happy.gif) : Track Drops — tracks drops, shrine stuff, monster gifts; click on Stamina Smiley icon to show
HV_Track_Drops.user.js.txt ( 7.24k )
Number of downloads: 13430Inline difficulty dropdown
HV_Inline_Difficulty_Changer.user.js.txt ( 3.34k )
Number of downloads: 1830Random Encounter timer (Shift+Click forces relocation with timer still going)
HV_random_encounter_timer.user.js.txt ( 3.07k )
Number of downloads: 9062Answer Riddlemaster with clicks or number keys [attachmentid=104806] Feel free to thank me whichever way you deem appropriate. (IMG:[ invalid] style_emoticons/default/cool.gif) anyone using chrome tried if mouse melee works? too busy with real life right now to test everything out. (IMG:[ invalid] style_emoticons/default/cry.gif)
|
|
|
|
|
|
Jun 27 2017, 14:11
|
Null2Null
Group: Gold Star Club
Posts: 1,199
Joined: 8-May 11
|
QUOTE(hentai_fusion @ Jun 27 2017, 19:54) anyone using chrome tried if mouse melee works? too busy with real life right now to test everything out. (IMG:[ invalid] style_emoticons/default/cry.gif) my browser is chrome and it may pause randomly.... so I post my problem at the top of page 213 now the only way is waiting (IMG:[ invalid] style_emoticons/default/laugh.gif) and the chian attack may work sometimes(?)
|
|
|
Jun 27 2017, 14:51
|
trick_NM
Group: Gold Star Club
Posts: 510
Joined: 14-June 14
|
Does any equipment shop filter script work? (If not, I can post it. but I think it's too poor...)
This post has been edited by trick_NM: Jun 27 2017, 14:52
|
|
|
Jun 27 2017, 15:13
|
Scremaz
Group: Gold Star Club
Posts: 24,304
Joined: 18-January 07
|
QUOTE(trick_NM @ Jun 27 2017, 14:51) Does any equipment shop filter script work? (If not, I can post it. but I think it's too poor...)
list of features, please?
|
|
|
Jun 27 2017, 15:30
|
trick_NM
Group: Gold Star Club
Posts: 510
Joined: 14-June 14
|
QUOTE(Scremaz @ Jun 27 2017, 22:13) list of features, please?
just cutting off both low rarity equipments any kind of equipments (rarity or types) from right pane and locked equipments from left pane... Upper: Before Lower: After This post has been edited by trick_NM: Jun 27 2017, 16:54
|
|
|
Jun 27 2017, 15:46
|
Jack Tekila
Group: Members
Posts: 174
Joined: 17-November 09
|
QUOTE(trick_NM @ Jun 27 2017, 10:30) just cutting off both low rarity equipments from left pane and locked equipments from right pane... Upper: Before Lower: After There are some settings, to allow locked equipments but still cut off low rarity equips? If yes, I'd really like it.
|
|
|
|
|
|
Jun 27 2017, 15:59
|
trick_NM
Group: Gold Star Club
Posts: 510
Joined: 14-June 14
|
QUOTE(Jack Tekila @ Jun 27 2017, 22:46) There are some settings, to allow locked equipments but still cut off low rarity equips? If yes, I'd really like it.
thanks. following are the one (I only tested it in latest Vivaldi and Opera). QUOTE // ==UserScript== // @name Shop Cleaner // @namespace SC // @version 0.2 // @description clean up Item and Equipment Shop // @author none // @match https://hentaiverse.org/?s=Bazaar&ss=es*// @match https://hentaiverse.org/?s=Bazaar&ss=is*// @require https://code.jquery.com/jquery-3.2.1.min.js // @grant none // ==/UserScript== (function(){ $('div.eqshop_pane:nth-child(2) div.eqp > div').each(function(){ var txt = $(this).html(); $(this).html(txt.replace(/(Exquisite|Superior|Average|Fair|Crude|Club|Leather|Plate|Banshee|Vampire)/g,'<div class="tokens"></div>')); }); $('.itshop_pane:nth-child(2) td > div').each(function(){ var txt = $(this).html(); $(this).html(txt.replace(/(Health|Mana|Spirit|Scrap|Energy|Monster|Crystal|Infusion|Scroll)/g,'<div class="tokens"></div>')); }); $("table.nosel > tbody > tr:has(.tokens), div.nosel > div.eqp:has(.tokens)").css('display','none'); $("div.nosel > div.eqp:has(.il)").css('display','none'); })(); Please feel how to use. (If you delete "$("div.nosel > div.eqp:has(.il)").css('display','none');", locked equipments won't be eliminated from list.) This post has been edited by trick_NM: Jun 27 2017, 16:45
|
|
|
|
|
|
Jun 27 2017, 16:13
|
Jack Tekila
Group: Members
Posts: 174
Joined: 17-November 09
|
QUOTE(trick_NM @ Jun 27 2017, 10:59) thanks. following are the one (I only tested it in latest Vivaldi and Opera). Please feel how to use. (If you delete "$(".eqp:has(.il)").css('display','none');", locked equipments won't be eliminated from list.)
Thanks. Working on Firefox. It's really simple and useful. Nice job.
|
|
|
|
|
|
Jun 27 2017, 17:05
|
Maharid
Group: Catgirl Camarilla
Posts: 2,373
Joined: 27-April 10
|
CODE // ==UserScript== // @name MouseMagelee 0.85 // @namespace hentaiverse.org // @version 0.1 // @description Something something hoverplay // @include *hentaiverse.org/?s=Battle* // @run-at document-end // @grant none // ==/UserScript==
// ***THANKS*** // sickentide (HV No Popup) // sigo8 (Reloader Shim) // dmyers59 (@version and #description
// SETTINGS var hideLog = false; // hide battle log var defaultAction = [1]; //0 for melee, array of spell id for mage (check Crackling Cast for the list of spells id) var minHP = 0.35; // lower than fullHP X this value hover stops var minMP = 0.0; // lower than fullMP X this value hover stops var minSP = 0.3; // lower than fullSP X this value hover stops var rightClick = [1]; // spell to cast on right click var iconGem = true; // show gem above Focus button var showDuration = true; // show the duration of the applied effects var leftHp = true; //align HP bar left function canCast(id){ var el = document.getElementById(id); return !!el && el.hasAttribute('onclick'); } function setSpellAttack(id) { var caller = document.getElementById(id); window.battle.lock_action(caller, 1, 'magic', id); window.battle.set_hostile_skill(id); }
function castSupport(id) { var caller = document.getElementById(id); window.battle.lock_action(caller, 1, 'magic', id); window.battle.set_friendly_skill(id); window.battle.touch_and_go(); }
function runRightClickSpell() { for (var i = 0; i < rightClick.length; i++) { if (canCast(rightClick[i])) { castSupport(rightClick[i]); return; } } }
function applyDuration() { var targets = document.querySelectorAll('img[onmouseover^="battle.set_infopane_effect"]'), i = targets.length; while (i--) { var duration = targets[i].getAttribute('onmouseover').match(/, ([-\d]+)\)/); if (!duration || duration < 0) duration = '-'; else duration = duration[1]; var div = targets[i].parentNode.insertBefore(document.createElement('div'), targets[i].nextSibling); div.appendChild(document.createElement('div')).innerHTML = duration; div.className = 'duration'; }}
function showGem() { var gem = document.getElementById('ikey_p'); var gem_icon = document.getElementById('gem_icon'); if (gem && !gem_icon) { var icon; switch (document.querySelector('#ikey_p > div > div').innerHTML.match(/([^\s]+) Gem/)[1]) { case 'Mystic': icon = 'channeling.png'; break; case 'Health': icon = 'healthpot.png'; break; case 'Mana': icon = 'manapot.png'; break; case 'Spirit': icon = 'spiritpot.png'; break; }
gem_icon = document.getElementById('pane_effects').appendChild(document.createElement('img')); gem_icon.src = '/y/e/' + icon; gem_icon.style.cssText = 'float: right;margin-right: 565px;';
var useGem = function() { window.battle.lock_action(gem, 1, 'items', 'ikey_p'); window.battle.set_friendly_skill('999'); window.battle.touch_and_go(); gem.remove(); gem_icon.remove(); };
gem_icon.onclick = useGem; gem_icon.onmouseover = useGem; gem_icon.id = "gem_icon"; } else if (!gem && gem_icon) { gem_icon.remove(); } }
function reloadedEvent() { if(iconGem) showGem(); if(showDuration) applyDuration(); if(document.querySelector('#vbh img').width < 496*minHP) { document.getElementById('vbh').style.backgroundColor = 'red'; return; } if(document.querySelector('#vbm img').width < 207*minMP) { document.getElementById('vbm').style.backgroundColor = 'red'; return; } if(document.querySelector('#vbs img').width < 207*minSP) { document.getElementById('vbs').style.bbackgroundColor = 'red'; return; }
if(defaultAction){ for (var i = 0; i < defaultAction.length; i++) { if (canCast(defaultAction[i])) { setSpellAttack(defaultAction[i]); break; } } }
mpane = document.getElementById('pane_monster'); var m = mpane.getElementsByClassName("btm1");
for (var j = 0; j < m.length; j++) { if (m[j].hasAttribute('onclick')) { m[j].setAttribute('onmouseover', m[j].getAttribute('onclick')); } } } function roundEndEvent() { var btcp = document.getElementById('btcp'); if (btcp){ if(document.querySelector('img[src$="finishbattle.png"]')){ var endSheet = document.createElement('style'); endSheet.innerHTML = '#btcp {display: block !important}'; document.head.appendChild(endSheet); } else{ btcp.click(); } } }
var log = document.querySelector('#textlog > tbody'); var paneCompletion = document.getElementById('pane_completion');
function init() { if(!log) { return; } var obs = new MutationObserver(reloadedEvent); obs.observe(log, {childList: true});
var obs2 = new MutationObserver(roundEndEvent); obs2.observe(paneCompletion, {childList: true});
var sheet = document.createElement('style'); sheet.innerHTML = '#btcp {display: none}.duration{width:30px;display:inline-block;text-align:center;position:relative;margin-left:-30px;top:-4px}.duration>div{background:white;border:1px solid black;padding:0 2px;display:inline-block;min-width:8px;font-weight:bold;height:13px}'; if(hideLog){ sheet.innerHTML += '#pane_log {display: none}'; } if(leftHp){ sheet.innerHTML += '#vbh>div{text-align:left !important}'; } document.head.appendChild(sheet);
window.addEventListener('contextmenu', function (e) { e.preventDefault(); runRightClickSpell(); }, false);
reloadedEvent(); } init(); Another problem with this, it seem to not work with the "Utilitarian" Vital Bar Style. If i revert to " Standard" Vital Bar Style it work again. Some fix?
|
|
|
|
|
|
Jun 27 2017, 17:31
|
Scremaz
Group: Gold Star Club
Posts: 24,304
Joined: 18-January 07
|
QUOTE(Maharid @ Jun 27 2017, 17:05) Another problem with this, it seem to not work with the "Utilitarian" Vital Bar Style. If i revert to " Standard" Vital Bar Style it work again.
Some fix?
it's already been reported. sooner or later a fix will appear.
|
|
|
Jun 27 2017, 17:32
|
marutora
Group: Gold Star Club
Posts: 386
Joined: 16-May 10
|
QUOTE(nekolor @ Jun 27 2017, 03:24) Ok, rolling out.
Major one: HV Battle Reloaded — essentially ex-Reloader with all obsolete AJAXing taken out and some of my fixes and additions I had for some time and didn't get to post before.
(snipped)
Thank you for taking my fix ( https://forums.e-hentai.org/index.php?s=&am...t&p=4885653 ) into `resizeHPBars` feature.
|
|
|
1 User(s) are reading this topic (1 Guests and 0 Anonymous Users)
0 Members:
|
|
|
|
|