Hentai Heroes++ (OCD) Season version

Adding things here and there in the Hentai Heroes game.

< Opiniones de Hentai Heroes++ (OCD) Season version

Puntuación: Bueno; el script funciona tal y como promete

§
Publicado: 27/06/2021
Editado: 27/06/2021

the two wiki aren't needed because u can klick on the name for the wiki page...
and i always need to remove this from the script on line 2996
"if ($('#hh_comix').length == 0) {
if (!girl.own) {
if (HH_UNIVERSE == 'gay') {
$(this).find('p').after('

');
}
else if (lang == 'fr') {
$(this).find('p').after('

');
}
else {
$(this).find('p').after('

');
}
}
if (girl.own) {
if (HH_UNIVERSE == 'gay') {
$(this).find('h3').after('

');
}
else if (lang == 'fr') {
$(this).find('h3').after('

');
}
else {
$(this).find('h3').after('

');
}
}
}"


and it looks much cleaner without this 2 links

§
Publicado: 08/07/2021

I have been noticing this too. Its not a huge deal but a removal of the second link would be a nice visual change and won't slide some stuff on the page a little too low

Tom208Autor
§
Publicado: 14/07/2021

It's strange because I don't have this issue on my side. I only have 1 wiki link on the page of the girls I already own.

§
Publicado: 16/07/2021
Editado: 16/07/2021
§
Publicado: 20/07/2021

Yes, it is caused by two scripts running together and connected events. Currently both scripts has selecting girl bound to click event, which updates display.
This script also runs update function each time harem page is loaded. Mine, when harem page is loaded, simply triggers click event on active girl.
This way, update function from this script is run twice, and since there's no checking for elements existence, wiki link is added twice.

To fix this, I would suggest:

  • changing running updateInfo from moduleHarem to triggering bound event. There can be unlimited event handlers for element (like mine), and each should be treated separately. Running bound function 'just so' can be a problem.
  • adding checks for needed elements before they are created. As seen here, it can clash with other script.
  • updating your code with some fixes I'll provide, so both scripts will work fine

Line numbers as for version 0.28.8
Line 3022:
setTimeout(function () {
$("#harem_left div.girls_list div[girl].opened").click();
}, 0);

Lines 3033 to 3056:
if ($('#hh_comix').length == 0) {
if ($(this).find('.middle_part .WikiLink h3').length == 0) {
--keep old code here--
} else {
var newHref = '';
if (HH_UNIVERSE == 'gay') {
newHref = 'https://harem-battle.club/wiki/Gay-Harem/GH:' + girlName;
}
else if (lang == 'fr') {
newHref = 'http://hentaiheroes.wikidot.com/' + girlName;
}
else {
newHref = 'https://harem-battle.club/wiki/Harem-Heroes/HH:' + girlName;
}
$(this).find('.middle_part .WikiLink a').attr('href', newHref);
}
}

This way, your link is added if there is no mine script running, and if there are my changes (link as girl name), your link changes (lang etc) are injected it mine and your actual link is hidden.
Let me no if you're gonna use any of. ;)

§
Publicado: 11/08/2021

will this be added?

§
Publicado: 29/08/2021

Ty @Tom208
i really appreciate it ♥

Publicar respuesta

Inicia sesión para responder.