Script mods from TheDruidsKeeper
|
|
How about to refresh the page after doing a job? In the actual site layout, after doing job the page stays with the result and the Script Status stays at "Doing <job>... in 0s"</job> |
|
|
I`m really struggling since the latest changes to Mob Wars. The script only seems to work with a bit of prompting (changing pages) and the property buyer has been switched off as it keeps withdrawing money from the bank then putting it back in, then out, then in, its like the Mob Wars Hokey Cokey! Is anyone else experiencing the same problems? Another one is that Mean bank Loss, Upkeep and Total are all red and minus! I did try reinstalling the older Firefox but thats not cured anything! HELP !!!!!!!! |
|
|
OK, i modified the timer on the script so that it will refresh the page and keep going after property purchases / job actions. @Twangy I'm not sure what is causing the "Hokey Cokey", but I would recommend either turning of auto deposit, or turn off "using money from bank". Also, since I've been experiencing a huge lack of time, I haven't had the chance to update the auto city buy mod yet for the new property categories. Anyone can feel free to get it working with them and post the changes so I can put them into the script though. :) |
|
|
Cheers Druid, you`re a star! I`ll play around with the settings on the auto buy, it is probably just something I`m doing wrong! |
|
|
I disabled the extra row of links since I realized that the original links are back to normal. |
|
|
Is it just me or the Quickheal is not working anymore? |
|
|
@TheDruidsKeeper, what did you change to get the timer to work? |
|
|
Just a heads up to those who use the search script!!! Is not working anymore, they know when you do it. You will loose any searches left for the rest of the day. |
|
|
@J.M.
@SoulKeeper
I haven't gotten around to fixing the quick heal yet, but you're right it is broken. I'm sure it is just some xpaths that are messed up from the changes, it's just a difficult mod to fix since it is all done via ajax. As another note of good news, the original author of the script has sent me message as a request for me to simply send him the updates to the script and he will update the core. So I will start doing that once I stop being lazy and get around to fixing the city auto buy and the quick heal. |
|
|
Is anybody having a problem loading the Druid's script after activating the FB username feature? While I'm here, wicked script, thanks for all the hard work Druid.... |
![]() ![]() |
<quote>As another note of good news, the original author of the script has sent me message as a request for me to simply send him the updates to the script and he will update the core. So I will start doing that once I stop being lazy and get around to fixing the city auto buy and the quick heal.</quote> Haven't received anything from TheDruidsKeeper yet, but maybe I can find some time to update the script. |
![]() ![]() |
[quote]Is anybody having a problem loading the Druid's script after activating the FB username feature?[/quote] YES! That's exactly when it stopped loading. I haven't found a solution to it either. |
![]() ![]() |
Does anyone still using this script or made changes so it would work halfway? |
![]() ![]() |
Mine is *barely* working. It can do NYC jobs, and that's about it. I'm hoping to take some time to update to that January greasemonkey release, as Firefox 3.5 is out now, and I'd like to use it. |
![]() ![]() |
Mine does the hitlisting pretty well and only recently stopped doing the autopurchases because it can't see the cash anymore. It doesn't seem to see the energy either so it has stopped doing jobs. |
![]() ![]() |
There used to be a switch/case section that would let the script get the hero stats (money, health, energy, &c.); I commented out most of it and replaced it with the following:
/* Other data */
/* Cash */
var cash_span = document.getElementById('app8743457343_cur_cash');
var re = /\$([0-9]+)/;
var result = cash_span.innerHTML.replace(",","","gi").match(re);
this.cash = parseInt(result[1]);
/* Health */
var health_span = document.getElementById('app8743457343_cur_health');
this.health = parseInt(health_span.innerHTML);
var max_health_str = health_span.parentNode.innerHTML;
max_health_str = stringCleaner(max_health_str);
re = /\/([0-9]+)/;
result = max_health_str.match(re);
this.max_health = parseInt(result[1]);
/* Energy */
var energy_span = document.getElementById('app8743457343_cur_energy');
this.energy = parseInt(energy_span.innerHTML);
var max_energy_str = energy_span.parentNode.innerHTML;
max_energy_str = stringCleaner(max_energy_str);
result = max_energy_str.match(re);
this.max_energy = parseInt(result[1]);
/* Stamina */
var stamina_span = document.getElementById('app8743457343_cur_recovery');
this.stamina = parseInt(stamina_span.innerHTML);
var max_stamina_str = stamina_span.parentNode.innerHTML;
max_stamina_str = stringCleaner(max_stamina_str);
result = max_stamina_str.match(re);
this.max_stamina = parseInt(result[1]);
/* Experience */
var exp_div = document.getElementById('app8743457343_cur_experience');
var exp_str = exp_div.innerHTML;
exp_str = stringCleaner(exp_str);
re = /Exp: ([0-9]+)\/?([0-9]+)?/;
result = exp_str.match(re);
this.exp = parseInt(result[1]);
/* Level */
re = /Level: ([0-9]+)/;
result = exp_str.match(re);
if (this.level != parseInt(result[1])) this.new_level = 1;
this.level = parseInt(result[1]);
It's not at all optimized; it's a quick hack I threw together to make sure I could still do NYC jobs. It references a stringCleaner function that cleans up the HTML for regex parsing:
function stringCleaner(str) {
str = str.replace(/<[^>]*>/g, '');
str = str.replace(/[, \t]/g,'');
str = str.replace(/\r|\n|\r\n/g, '');
str = str.replace(" ", " ", "gi");
return str;
}
|


