Approved script Scavenging script - Early release

Anonymous...

Active Member
I've noticed that it says the same, but still sends the runs out in hours. Seems like its just a typo and doesn't really affect the functionality of the script in any way
 

Koallar

New Member
I've noticed that it says the same, but still sends the runs out in hours. Seems like its just a typo and doesn't really affect the functionality of the script in any way
Seems like it to me too now that I think of it. I just set the counter to 99999. It works for me. Thanks for the heads up though
 

Shinko to Kuma

Non-stop Poster
Seems like it to me too now that I think of it. I just set the counter to 99999. It works for me. Thanks for the heads up though
I've noticed that it says the same, but still sends the runs out in hours. Seems like its just a typo and doesn't really affect the functionality of the script in any way
I've noticed that it says the same, but still sends the runs out in hours. Seems like its just a typo and doesn't really affect the functionality of the script in any way
Sorry all, I put part of my test version as the live version, I did some testing to try and get the runtimes more accurate to allow for potential sniping through scavenging if people wanted to. I'll rollback and get the old version back till I have time to finish the update that will make the script work a LOT faster

EDIT: should work as intended now, there will be checkboxes to enable/disable categories but those won't work for now.
 
Last edited:

Koallar

New Member
Sorry all, I put part of my test version as the live version, I did some testing to try and get the runtimes more accurate to allow for potential sniping through scavenging if people wanted to. I'll rollback and get the old version back till I have time to finish the update that will make the script work a LOT faster

EDIT: should work as intended now, there will be checkboxes to enable/disable categories but those won't work for now.
Shinko, you and I need to become friends. LOL I have so much to learn.
 

Sashaahn

Non-stop Poster
I have two questions shinko if you can oblige me with an answer.

1 - Do you think this will ever be edited to be able to leave reserve troops at home? I know there a couple of slightly tedious ways to do this anyway, But would be handy to be able to leave 1000/1000 sp/sw at home for a snipe if you get in trouble while troops are out scavenging.

2 - Literally 99% of players (some very experienced and math driven players) have been talking about diminishing rate of return the longer one scavanges, pretty much since scavenging came out. Am I missing something here? Because I dont see it. In fact, all i see is the opposite. Every additional hour one scavenges for, the higher the rate of return, and at no point does the rate diminish.
 
Last edited:

Shinko to Kuma

Non-stop Poster
Yep same here. Glancing at the script it looks like there are some variables no longer defined .
Looks like scavenging script stopped working this morning... anyone else has the same problem??

V
I haven’t touched that script at all but I’ll take a look, on mobile rn so if you could show me a console log or something (F12 on chrome) that would be helpful

- Sophie

PS: I have another approved version of the scav script, more advanced but it has some calculation issues here and there still. You can try this one as well

Code:
javascript:
$.getScript('https://dl.dropboxusercontent.com/s/e30h3fie7ohu2wi/scavSpeed.js');
 

Flexander the Lit

New Member
Hey mate this was in my console after trying to run the script
en109.tribalwars.net-1563801268572.log:
Code:
scavengingfinal.js?_=1563801242991:28 Uncaught TypeError: Cannot read property 'duration_factor' of undefined
    at scavenge (scavengingfinal.js?_=1563801242991:28)
    at scavengingfinal.js?_=1563801242991:736
 

Flexander the Lit

New Member
and this one when trying your other version


Code:
scavSpeed.js?_=1563801596820:55 Getting  /game.php?&screen=unit_info&ajax=data
scavSpeed.js?_=1563801596820:97 Uncaught TypeError: Cannot read property 'duration_factor' of undefined
    at scavSpeed.js?_=1563801596820:97
scavSpeed.js?_=1563801596820:76 Object
scavSpeed.js?_=1563801596820:82 TypeError: Cannot read property 'checked' of undefined
    at calculateHaul (scavSpeed.js?_=1563801596820:205)
    at scavSpeed.js?_=1563801596820:79
    at loadNext (scavSpeed.js?_=1563801596820:43)
    at Object.<anonymous> (scavSpeed.js?_=1563801596820:62)
    at c (game.js:9)
    at Object.fireWith [as resolveWith] (game.js:9)
    at k (game.js:11)
    at XMLHttpRequest.r (game.js:11)
(anonymous) @ scavSpeed.js?_=1563801596820:82
 

Veronika7747

Active Member
there must have been something similar on the balancing script as well as you have to "hit" manually send now; if you hit the script 2nd time it will just close the tab without sending the resources indicated earlier..
hope this make a sense:confused:

V
 

Shinko to Kuma

Non-stop Poster
Update: both scripts should be fixed and working again, they did an update to major version 8.177, which changed the location of certain variables. Other servers (including .nl) are still running on 8.176 so I included an exception for those servers so they still keep working too.

there must have been something similar on the balancing script as well as you have to "hit" manually send now; if you hit the script 2nd time it will just close the tab without sending the resources indicated earlier..
hope this make a sense:confused:

V
Are you sure it doesn't send the resources before closing the tab? I have it set right now that it will close the tab once the URL no longer has "send" or "wood" in there, which only happens after the sending was succesfull and it returns to the market
 
Last edited:

Shinko to Kuma

Non-stop Poster
I have two questions shinko if you can oblige me with an answer.

1 - Do you think this will ever be edited to be able to leave reserve troops at home? I know there a couple of slightly tedious ways to do this anyway, But would be handy to be able to leave 1000/1000 sp/sw at home for a snipe if you get in trouble while troops are out scavenging.

2 - Literally 99% of players (some very experienced and math driven players) have been talking about diminishing rate of return the longer one scavanges, pretty much since scavenging came out. Am I missing something here? Because I dont see it. In fact, all i see is the opposite. Every additional hour one scavenges for, the higher the rate of return, and at no point does the rate diminish.

1) I can do this but with the overhaul they are doing to scavenging right now idk if I want to invest the time in that right now. I could just deduct a value of the numbers I grab from the page so it thinks there are less available then there actually are

2) after 2 hours of scavenging time the rates pretty much are the same for every scavenging type. They drop exponentionally from the start and once they are around 2 hours it becomes stagnant

 

Veronika7747

Active Member
for the balancing - when I run my shortkeys twice and it closes all the tabs I went and look how many mechants left in my only big village and they were still all there; so I run it again and hit the "send" manualy 2nd time around and resources were shipped out fine:)
 

Shinko to Kuma

Non-stop Poster
for the balancing - when I run my shortkeys twice and it closes all the tabs I went and look how many mechants left in my only big village and they were still all there; so I run it again and hit the "send" manualy 2nd time around and resources were shipped out fine:)
I can't reproduce it on my end, it works just fine here, but to be safe (might be latency related), I made it so it only closes the page after it sent and you reloaded the page, then you run the script again. So you can still keep pressing the script button and it will work. Let me know if this works better for you
 

Veronika7747

Active Member
Perfect; works for me just as before and I don't mind closing all tabs to the right once the 1st batch is done:)
Thanks you! You are great!!

V
 

FunnyPocketBook

New Member
On some servers they changed their scavenge object, to fix it just change the array index from 0 to 1 on line 28
From
PHP:
var scavengeInfo = JSON.parse($('html').find('script:contains("ScavengeScreen")').html().match(/\{.*\:\{.*\:.*\}\}/g)[0]);
to
PHP:
var scavengeInfo = JSON.parse($('html').find('script:contains("ScavengeScreen")').html().match(/\{.*\:\{.*\:.*\}\}/g)[1]);
 
Last edited: