Welcome Guest ( Log In | Register )

45 Pages V « < 32 33 34 35 > »   
Reply to this topicStart new topic
> [Script] Monsterbation 1.4.1.2, A comprehensive hovering script for HentaiVerse and ISK. Including CrunkJuice 1.3.0, an out-of-battle script

 
post Jan 23 2021, 22:29
Post #647
Nezu



Rat
********
Group: Catgirl Camarilla
Posts: 3,946
Joined: 29-January 12
Level 500 (Ponyslayer)


QUOTE(sickentide @ Jan 23 2021, 20:27) *

the thing is, i have never seen a monster resist a spike shield... what was added in this version, however, was counting the times a monster resists Imperil. is this really a problem, though? you can still get an accurate count of you weapon misses by looking at the total in the physical column


I also think it's the imperil evades/resists. (It would be nice to have hits counted for those too?)

This post has been edited by Nezu: Jan 23 2021, 22:30
User is offlineProfile CardPM
Go to the top of the page
+Quote Post

 
post Jan 23 2021, 23:01
Post #648
Basara Nekki



A poor man with a star.
**********
Group: Gold Star Club
Posts: 7,745
Joined: 13-September 12
Level 500 (Ponyslayer)


QUOTE(sickentide @ Jan 23 2021, 17:27) *

the thing is, i have never seen a monster resist a spike shield... what was added in this version, however, was counting the times a monster resists Imperil. is this really a problem, though? you can still get an accurate count of your weapon misses by looking at the total in the physical column

and there is a distinction: a spell "fails to connect" or the monster "evades your spell", an attack "misses its mark" or the monster "evades your attack"


I hadn't thought about Imperil. (IMG:[invalid] style_emoticons/default/heh.gif) Now it makes sense.

As the numbers of misses were way above what I was used to seeing, I was a little surprised. There is no problem with the results themselves.

The only annoyance that remains is the size of the table, with up to 10 lines at the bottom. So I asked if it was possible to remove some lines. That way I wouldn't need to capture a second image like I did above. But no need to worry. I will continue using the old version only for testing.

User is offlineProfile CardPM
Go to the top of the page
+Quote Post

 
post Jan 23 2021, 23:07
Post #649
sickentide



sexromancer
*******
Group: Catgirl Camarilla
Posts: 1,355
Joined: 31-August 10
Level 500 (Ponyslayer)


QUOTE(Basara Nekki @ Jan 23 2021, 23:01) *

So I asked if it was possible to remove some lines.

did you try the fixed fix i posted? changing lines 260-264 will do it:
CODE
        (any.hit ? '</tr><tr style="border-top:1px solid">' + Count('hit') + '</tr><tr>' + Count('crit') +
        (any.r50 ? '</tr><tr>' + Count('r50') : '') + (any.r75 ? '</tr><tr>' + Count('r75') : '') + (any.r90 ? '</tr><tr>' + Count('r90') : '') : '') +
        (any.none ? '</tr><tr style="border-top:1px solid">' + (any.miss ? '</tr><tr>' + Count('miss') : '') + (any.evade ? '</tr><tr>' + Count('evade') : '') +
        (any.parry ? '</tr><tr>' + Count('parry') : '') + (any.resist ? '</tr><tr>' + Count('resist') : '') + (any.block ? '</tr><tr>' + Count('block') : ''): '') +
        (any.none ? '</tr><tr><td>total</td>' +

into
CODE
        (any.hit ? '</tr><tr style="border-top:1px solid">' + Count('hit') + '</tr><tr>' + Count('crit') : '') +
        (any.none ? '</tr><tr><td>miss</td>' +
User is offlineProfile CardPM
Go to the top of the page
+Quote Post

 
post Jan 24 2021, 00:06
Post #650
Basara Nekki



A poor man with a star.
**********
Group: Gold Star Club
Posts: 7,745
Joined: 13-September 12
Level 500 (Ponyslayer)


QUOTE(sickentide @ Jan 23 2021, 18:07) *

did you try the fixed fix i posted? changing lines 260-264 will do it:
CODE
        (any.hit ? '</tr><tr style="border-top:1px solid">' + Count('hit') + '</tr><tr>' + Count('crit') +
        (any.r50 ? '</tr><tr>' + Count('r50') : '') + (any.r75 ? '</tr><tr>' + Count('r75') : '') + (any.r90 ? '</tr><tr>' + Count('r90') : '') : '') +
        (any.none ? '</tr><tr style="border-top:1px solid">' + (any.miss ? '</tr><tr>' + Count('miss') : '') + (any.evade ? '</tr><tr>' + Count('evade') : '') +
        (any.parry ? '</tr><tr>' + Count('parry') : '') + (any.resist ? '</tr><tr>' + Count('resist') : '') + (any.block ? '</tr><tr>' + Count('block') : ''): '') +
        (any.none ? '</tr><tr><td>total</td>' +

into
CODE
        (any.hit ? '</tr><tr style="border-top:1px solid">' + Count('hit') + '</tr><tr>' + Count('crit') : '') +
        (any.none ? '</tr><tr><td>miss</td>' +



Now it worked! (IMG:[invalid] style_emoticons/default/biggrin.gif) Thank you very much sickentide. (IMG:[invalid] style_emoticons/default/wink.gif)

As I don't understand anything about coding, I had made the changes you suggested in previous posts, but the script stopped working.

I have already saved it in a file to be able to modify future versions, if necessary.
User is offlineProfile CardPM
Go to the top of the page
+Quote Post

 
post Jan 25 2021, 22:30
Post #651
Firew



Casual Poster
****
Group: Gold Star Club
Posts: 258
Joined: 22-February 11
Level 500 (Ponyslayer)


Hello, while I am able to get it working on certain non-sandbox versions of tampermonkey, it's a pain to ensure this behavior always works.

I was wondering if you could simply add the timelog, combatlog, and droplog to the window? It'll basically act as a pointer that can be accessed from any other script.

My idea is basically to put it after initializing the global variables/constants, something like this:

CODE
// global variables and constants
var cfg = {}, profile = JSON.parse(localStorage.HVmbp || '{}'), isekai = document.URL.indexOf('isekai') > -1 ? 'i' : '',
    bindings = [], gem = [], target = false, cursor = localStorage['HVcursor' + isekai] ? parseInt(localStorage['HVcursor' + isekai]) : -1,
    interruptHover, interruptAlert = false, hovering = false, override = false, impulse = false, done = false,
    release = false, shiftHeld = false, ctrlHeld = false, altHeld = false, bg, dummy = document.createElement('div'),
    mp = 1, sp = 1, monsters = [], monsterData = {}, log, timelog = JSON.parse(localStorage['HVtimelog' + isekai] || '{ "turn":0,"action":0,"round":1,"lastuse":{} }'),
    combatlog = JSON.parse(localStorage['HVcombatlog' + isekai] || '{ "pdealt":{"hit":0,"crit":0,"miss":0,"evade":0,"parry":0,"resist":0,"r50":0,"r75":0,"r90":0},' +
                                                         '"mdealt":{"hit":0,"crit":0,"miss":0,"evade":0,"parry":0,"resist":0,"r50":0,"r75":0,"r90":0},' +
                                                         '"ptaken":{"hit":0,"shit":0,"crit":0,"scrit":0,"miss":0,"evade":0,"parry":0,"block":0,"r50":0,"r75":0,"r90":0},' +
                                                         '"mtaken":{"hit":0,"shit":0,"crit":0,"scrit":0,"miss":0,"evade":0,"parry":0,"block":0,"r50":0,"r75":0,"r90":0},' +
                                                         '"used":{} }'),
    vitals = JSON.parse(localStorage['HVvitals' + isekai] || '{ "hp":0,"mp":0,"sp":0 }'),
    droplog = JSON.parse(localStorage['HVtrackdrops' + isekai] ||
              '{ "Crystals":{}, "Equips":{}, "Mats":{}, "Artifacts":{}, "Figurines":{}, "Trophies":{}, "Consumables":{}, "Foods":{}, "proficiency":{} }'),
    csp = false;

window.timelog = timelog;
window.combatlog = combatlog;
window.droplog = droplog;

const damage = document.getElementById('2501') ? 'Arcane Focus' : 'Heartseeker',
...


edit:

you may also choose to dispatch the event with data, it seems.
CODE
window.dispatchEvent(new CustomEvent("battleEnd", {"detail":{timelog,combatlog,droplog}}));


Which I can then consume as well. That might be better.

This post has been edited by Firew: Jan 26 2021, 17:08
User is offlineProfile CardPM
Go to the top of the page
+Quote Post

 
post Jan 26 2021, 05:30
Post #652
what_is_name



Active Poster
*******
Group: Gold Star Club
Posts: 1,056
Joined: 5-May 19
Level 500 (Ponyslayer)


edit: NVM, I may messed up different test (IMG:[invalid] style_emoticons/default/cry.gif) , ignore my post, it up to you and Firew's choose

This post has been edited by what_is_name: Jan 26 2021, 07:44
User is offlineProfile CardPM
Go to the top of the page
+Quote Post

 
post Jan 27 2021, 04:15
Post #653
sickentide



sexromancer
*******
Group: Catgirl Camarilla
Posts: 1,355
Joined: 31-August 10
Level 500 (Ponyslayer)


QUOTE(Firew @ Jan 25 2021, 21:30) *

you may also choose to dispatch the event with data, it seems.
CODE
window.dispatchEvent(new CustomEvent("battleEnd", {"detail":{timelog,combatlog,droplog}}));


Which I can then consume as well. That might be better.

that seems more practical than relying on localstorage interactions that can and have changed in the past. here goes: Attached File  HentaiverseMonsterbation.1.4.0.3.user.js.txt ( 159.46k ) Number of downloads: 12280
User is offlineProfile CardPM
Go to the top of the page
+Quote Post

 
post Jan 28 2021, 17:01
Post #654
forneus_zero



Data Hoarder
***
Group: Members
Posts: 235
Joined: 4-June 12
Level 372 (Dovahkiin)


Is there a guide/documentation for the syntax i.e impulse, any, strongest etc? What do they mean?

Thank you in advance
User is offlineProfile CardPM
Go to the top of the page
+Quote Post

 
post Jan 28 2021, 23:49
Post #655
Nezu



Rat
********
Group: Catgirl Camarilla
Posts: 3,946
Joined: 29-January 12
Level 500 (Ponyslayer)


QUOTE(forneus_zero @ Jan 28 2021, 15:01) *

Is there a guide/documentation for the syntax i.e impulse, any, strongest etc? What do they mean?

Thank you in advance


Impulse queues an action to occur on your next hover. Without impulse, hovering will generally overwrite the command unless you move your mouse off the monsters, because you're generally somewhere in the cycle of 'already clicked, waiting for server response'.

Strongest takes an array of actions and, starting from the right and working back to the left, clicks each of them in turn. This has some slightly different outcomes depending on what you put in; targeted skills and spells like OFC, Smite etc are 'loaded' for use, so they'll occur on your next click on a monster. Because you can 'overwrite' your loaded action with ones further up in your Strongest priority, it'll always end with the leftmost available action.

But untargeted actions such as consumables or heals work the opposite way, where they can fire immediately on click, so you have to list those in opposite priority order (ie if you want to Cure first, and then Full-Cure second, it'd be Full-Cure then Cure in the array).

Atomic actions are things like Cast(), Use() and TargetMonster(). Strongest and Impulse are essentially decorators. If you want to impulse-queue an action selected by strongest, you'd use Impulse(Strongest([...])).
User is offlineProfile CardPM
Go to the top of the page
+Quote Post

 
post Jan 29 2021, 00:57
Post #656
sickentide



sexromancer
*******
Group: Catgirl Camarilla
Posts: 1,355
Joined: 31-August 10
Level 500 (Ponyslayer)


i should also note that the script file contains some explanations and examples for all the bindable functions, in the section starting with the comment "key bindings"
User is offlineProfile CardPM
Go to the top of the page
+Quote Post

 
post Jan 29 2021, 21:18
Post #657
forneus_zero



Data Hoarder
***
Group: Members
Posts: 235
Joined: 4-June 12
Level 372 (Dovahkiin)


QUOTE(Nezu @ Jan 29 2021, 04:49) *

Impulse queues an action to occur on your next hover. Without impulse, hovering will generally overwrite the command unless you move your mouse off the monsters, because you're generally somewhere in the cycle of 'already clicked, waiting for server response'.

Strongest takes an array of actions and, starting from the right and working back to the left, clicks each of them in turn. This has some slightly different outcomes depending on what you put in; targeted skills and spells like OFC, Smite etc are 'loaded' for use, so they'll occur on your next click on a monster. Because you can 'overwrite' your loaded action with ones further up in your Strongest priority, it'll always end with the leftmost available action.

But untargeted actions such as consumables or heals work the opposite way, where they can fire immediately on click, so you have to list those in opposite priority order (ie if you want to Cure first, and then Full-Cure second, it'd be Full-Cure then Cure in the array).

Atomic actions are things like Cast(), Use() and TargetMonster(). Strongest and Impulse are essentially decorators. If you want to impulse-queue an action selected by strongest, you'd use Impulse(Strongest([...])).


Thanks this helps a lot!

QUOTE(sickentide @ Jan 29 2021, 05:57) *

i should also note that the script file contains some explanations and examples for all the bindable functions, in the section starting with the comment "key bindings"


I've read the keybindings section but I'm too dumb hehe (IMG:[invalid] style_emoticons/default/cry.gif)
User is offlineProfile CardPM
Go to the top of the page
+Quote Post

 
post Feb 3 2021, 23:13
Post #658
Chaisy



Succubus Developer
****
Group: Gold Star Club
Posts: 407
Joined: 3-August 12
Level 472 (Godslayer)


In Monsterbation Settings, for the extend quickbar line, i.e.:

[1,"ikey_1","ikey_2","ikey_3","ikey_4","ikey_7","ikey_8","ikey_9","ikey_10","ikey_s1","ikey_s2","ikey_s4","ikey_n1","ikey_n5","ikey_n6","ikey_6","ikey_5"]

When I try to change it to just [1] to only show the gem, it resets itself to the above again whenever I click "save".

How can I get this setting to stick?


Edit:

I can change the entries between each comma, but if I ever have less than 17 items in that list, it goes back to the default for that item.

So my workaround is:

[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]

but if I try to enter:

[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]

when I click Save it changes it to:

[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,"ikey_5"]


This post has been edited by Chaisy: Feb 3 2021, 23:58
User is offlineProfile CardPM
Go to the top of the page
+Quote Post

 
post Feb 6 2021, 12:00
Post #659
uareader



Critter
*********
Group: Catgirl Camarilla
Posts: 5,594
Joined: 1-September 14
Level 500 (Ponyslayer)


Feature request: would it be possible to have an option to, when using ajaxRound (or another thing that accelerate the round transition if it's not exactly what I think of), to have the last log entry from the previous round copied, then pasted in the log of the next round?
User is offlineProfile CardPM
Go to the top of the page
+Quote Post

 
post Feb 7 2021, 16:46
Post #660
what_is_name



Active Poster
*******
Group: Gold Star Club
Posts: 1,056
Joined: 5-May 19
Level 500 (Ponyslayer)


QUOTE(Chaisy @ Feb 4 2021, 05:13) *

In Monsterbation Settings, for the extend quickbar line, i.e.:
When I try to change it to just [1] to only show the gem, it resets itself to the above again whenever I click "save".


It not reset but override by default setting when load, from the LoadCfg function

CODE

        if ( typeof(settings[setting]) == 'object' ) {
             for ( var item in settings[setting] ) {
                 if ( !cfg[setting][item] && !(cfg[setting][item] === false) ) {
                     cfg[setting][item] = settings[setting][item]; }}}}


seems it consider the items in array as missing setting item. add a Array filter may fix it. I noticed that long ago but forgot it because I use 17 extend items now

CODE

        if ( typeof(settings[setting]) == 'object' && !(settings[setting] instanceof Array) ) {
             for ( var item in settings[setting] ) {
                 if ( !cfg[setting][item] && !(cfg[setting][item] === false) ) {
                     cfg[setting][item] = settings[setting][item]; }}}}


User is offlineProfile CardPM
Go to the top of the page
+Quote Post

 
post Feb 9 2021, 07:34
Post #661
kserox



Poster Irregular
*****
Group: Catgirl Camarilla
Posts: 727
Joined: 26-December 10
Level 500 (Godslayer)


Key bindings confuse me a little, do I need to enable them somewhere else in the script for them to work? For example, I added the line
Bind(KEY_M, Cast('Cure'));
but nothing happens when I press M. As far as I can tell other bindings also do nothing. Am I missing something?
User is offlineProfile CardPM
Go to the top of the page
+Quote Post

 
post Feb 10 2021, 13:19
Post #662
uareader



Critter
*********
Group: Catgirl Camarilla
Posts: 5,594
Joined: 1-September 14
Level 500 (Ponyslayer)


QUOTE(kserox @ Feb 9 2021, 06:34) *

Key bindings confuse me a little, do I need to enable them somewhere else in the script for them to work? For example, I added the line
Bind(KEY_M, Cast('Cure'));
but nothing happens when I press M. As far as I can tell other bindings also do nothing. Am I missing something?

Maybe it's commented, or not on the currently loaded profile?
Maybe try "Bind(KEY_M, Any, Cast('Cure'));" (maybe Cast require the key modifier entry?)
User is offlineProfile CardPM
Go to the top of the page
+Quote Post

 
post Feb 10 2021, 15:53
Post #663
kserox



Poster Irregular
*****
Group: Catgirl Camarilla
Posts: 727
Joined: 26-December 10
Level 500 (Godslayer)


QUOTE(uareader @ Feb 10 2021, 16:19) *

Maybe it's commented, or not on the currently loaded profile?
Maybe try "Bind(KEY_M, Any, Cast('Cure'));" (maybe Cast require the key modifier entry?)

[i.imgur.com] That's what I see when I check my MB Settings. Looks proper to me except that [persistent] part. However, there is no [isekai] option in a dropdown, and hotkeys don't work in persistent mode also.
It's weird.

This post has been edited by kserox: Feb 10 2021, 16:01
User is offlineProfile CardPM
Go to the top of the page
+Quote Post

 
post Feb 14 2021, 11:46
Post #664
Nezu



Rat
********
Group: Catgirl Camarilla
Posts: 3,946
Joined: 29-January 12
Level 500 (Ponyslayer)


Have you thought about encasing the settings parsing in a try/catch block, so settings can be fixed in battle without having to go through the script in LocalStorage (since syntax errors etc will break the whole thing currently)?

Users can currently work around this by opening up isekai and using the settings there, but it would certainly be convenient if you ever want to experiment with new binds in battle. I frequently am asked to provide support for people who break their binds mid-battle, so it's a real use case.
User is offlineProfile CardPM
Go to the top of the page
+Quote Post

 
post Feb 14 2021, 23:06
Post #665
uareader



Critter
*********
Group: Catgirl Camarilla
Posts: 5,594
Joined: 1-September 14
Level 500 (Ponyslayer)


QUOTE(kserox @ Feb 10 2021, 14:53) *
there is no [isekai] option in a dropdown
That's weird, but I thought of something: maybe it's because of "inherit", as I do see an isekai list of options, and have the box unchecked, and you don't see the option, and have the box checked.
User is offlineProfile CardPM
Go to the top of the page
+Quote Post

 
post Feb 15 2021, 09:22
Post #666
OnceForAll



Fluffy Tail Fox
*******
Group: Catgirl Camarilla
Posts: 1,638
Joined: 3-January 21
Level 500 (Ponyslayer)


Have you ever tried using GM_setValue / GM_removeValue / GM_getValue instead of using localStorage?Almost every userscript manager supports those GreaseMonkey API.

It seems that those APIs are safer than localStorage (since localStorage can be accessed by anyone, although there is nothing to be leaked).
User is offlineProfile CardPM
Go to the top of the page
+Quote Post


45 Pages V « < 32 33 34 35 > » 
Reply to this topicStart new topic
1 User(s) are reading this topic (1 Guests and 0 Anonymous Users)
0 Members:

 


Lo-Fi Version Time is now: 31st August 2025 - 20:33