Extra caution is recommended when installing recently uploaded/updated scripts (read more)
Be sure you trust any scripts you install

Facebook Monsters Enhancer

Creates a menu to use those applications in Facebook and has auto-play functions

This script has superseded the original script, as this now has all the equivalent functionality & more. Except for Checkboxes (i.e. manually selecting to feed or to fight users).

PURPOSE

  • Organize players in clans that can feed mutually and attack each other
  • Auto feed monsters from the clan to gain money & attacks.
  • Auto attack friends to gain experience points.
  • Auto buy items to improve your attack power.
  • Do this all easily and conveniently, without manual effort (i.e. a bot)

HOW AUTO-FEED WORKS:

  1. There is an 'Feed off!' button on the statistics panel. If you press the function will activate. (The button will now show 'Feed on!')
  2. On your profile or a feeding related page (event-history, feed-result, ...) the script will begin to work, showing what it's doing on the status line(on top of the sidebar).
  3. On your Feeding History or Feeding Main Page you can see who is in your clan. You cannot edit it for now :-(

Current Logic for feeding: Read your feeding history and you friends list (if there are not enough people in the feeding history) to populate your clan. Than attack the 8 people that fed you last. Switch to the next monster when it's done.

From version 1.1: when people in your feeding clan does not feed you in 3 days (configurable with the TOLERANCE_TIME variable) they become replaceable and random people from your friends/clan feeding history will take their place. The script will in this way try to attain 8 people feeding you every day.

HOW AUTO-ATTACK WORKS:

  1. There is an 'Attack off!' button on the statistics panel. If you press it the function will activate. (The button will now show 'Attack on!')
  2. On your profile or an attacking related page (fighting-main, fighting-confirm, ...) the script will begin to work, showing what it's doing on the status line (on the statistics panel).

Current Logic for attacking: Go from top to bottom, choose an opponent who is less than twice as strong as you. Use all 3 attacks per round and than choose another defender monster type randomly. Once done switch to another monster type.

HOW AUTO-BUY WORKS:

  1. There is an 'Buy off!' button on the statistics panel. If you press it the function will activate. (The button will now show 'Buy on!')
  2. On your profile or your store the script will begin to work, showing what it's doing on the status line (on the statistics panel).

Current Logic for buying: If you have enough money to buy a shield or a boom stick and you don't have them already, the script will purchase them.

CREDITS

Facebook Slayers/Werewolves/Vampires/Zombies Enhancer by ViXaY Xavier (http://userscripts.org/users/42874) for the initial code and inspiration.

VERSIONS

<dl>
1.0-alpha
First released
1.0-alpha2
Corrected a minor glitch in the code that made the script unusable. Please upgrade
1.0-beta
Many feature improvements, among them:
  • You can now feed from your friends list as well: the script will use it as a fallback if your feeding history doesn't contain enough monsters.
  • Your clan is now displayed on the bottom of your feeding history and feeding mainpage.
  • The menu was removed and all items moved into the page. Just hover over the game's menu and see what happens :-)
1.0
There is an auto-buy function (thanks to ViXaY)
1.1
Big rewrite of the script. The different cycles can now kick in on any monsters related page and the delay for new attacks is taken into account. The number of attacks left is also calculated in a much precise way.
</dl>

For more informations look at the Facebook Monsters Enhancer blog.






1 point
login to vote
berto user
Posted 4 hours ago

I understand Viva y Xavier. I believe this routine told before to select monsters less than twice in points (I am learning java with this script sorry)

/* Get the list of all enemies */
var powers = getElementsByClassName("small_avatar_experience", "div", divs[2]);
var names = getElementsByClassName('small_avatar_user_name', 'div', divs[2]);
var urls = getElementsByClassName('small_avatar_attack_link', 'div', divs[2]);

Will look more into it to see if it helps to put it back and will report on it.

1 point
login to vote
ViXaY Xavier scriptwright
Posted 16 hours ago

berto, i'm swamped right now, so haven't had much time to look at it, but as i see it, it has to do with the changes in Facebook. If you are interested i think it's the parsing of the tables on the fight page that's causing these problems. See if you can work something out in that :)

1 point
login to vote
berto user
Posted 1 day ago

Example of script results as is now:

18 Attacks: 2 wins 16 losses.

Must say until now was a great script, but since it does not select anymore monsters less than twice your monster´s points, but any monster in the list, it destroys the attack purpose of the script, by attacking too powerfull monsters. Any clues?

October 04 Your Zombie attacked Marie's Vampire 3 times.
But Marie defended with a shield and earned some points!
» You won 0 of the attacks and earned 0 points.
» Marie won 3 of the attacks and earned 3 points.
attack Lennie! October 04 Your Zombie attacked Lennie's Slayer 3 times.
Lennie would have won defending points, but she didn't have any armour!
» You won 1 of the attacks and earned 8 points.
» Lennie won 2 of the attacks and earned 0 points.
attack Lennie! October 04 Your Zombie attacked Lennie's Werewolf 3 times.
Lennie would have won defending points, but she didn't have any armour!
» You won 0 of the attacks and earned 0 points.
» Lennie won 3 of the attacks and earned 0 points.
attack Lennie! October 04 Your Zombie attacked Lennie's Slayer 3 times.
Lennie would have won defending points, but she didn't have any armour!
» You won 0 of the attacks and earned 0 points.
» Lennie won 3 of the attacks and earned 0 points.
attack Lennie! October 04 Your Zombie attacked Lennie's Slayer 3 times.
Lennie would have won defending points, but she didn't have any armour!
» You won 1 of the attacks and earned 8 points.
» Lennie won 2 of the attacks and earned 0 points.
attack Lennie! October 04 Your Zombie attacked Lennie's Werewolf 3 times.
Lennie would have won defending points, but she didn't have any armour!
» You won 0 of the attacks and earned 0 points.
» Lennie won 3 of the attacks and earned 0 points.

1 point
login to vote
berto user
Posted Oct 4, 2008 11:24pm

Great job Kaz, it works really well. I am looking at the script code to try to figure out how to select to attack monsters with just 1.5 more points than our monster. Can you help on this? thanks, Berto.

2 points
login to vote
kaz user
Posted Oct 4, 2008 6:45pm

fix to latest bug....

replace line:
var APPS_URL = "http://apps.new.facebook.com/";

with line:
var APPS_URL = "http://apps.facebook.com/";

1 point
login to vote
berto user
Posted Sep 30, 2008 8:38am

I have been monitoring the results of the attacks of the script and the results of the attacks have gone done drastically. Many more attacks are lost than won because the script does not select anymore monsters who are just 1.5 or 2 times stronger than our attacking monster. Now it attacks any monster on the list, even with 60.000 or more points, and the fights are constantly lost. The rule programmed on the script about attacking monsters just 1.5 or 2 times stronger was a success and a real winner for this script. Now it just contributes to make the defending strong monsters we attack, even stronger. The script can be one of the best with just a few details like the selection of the monsters to be attacked. If it can be arranged it will be greatly appreciate. Thank you also for keeping the script alive with all the effort it involves.

1 point
login to vote
Posted Sep 24, 2008

I've been using script for sometime now and it was fine till today. Today I cant seem to switch off the Auto feed and Auto Attack button..... and i dont know what to do.... can anyone help me in that ???

1 point
login to vote
Daigoro user
Posted Sep 21, 2008

ViXaY Xavier, you were right; Your fix really fixed the problem. For some reason I just didn't see it before I posted my comment.

Thanks for your help.

But I noticed that the Auto Buy function apparently isn't working so well, either, even after your fix: At least I've run out of shield despite having plenty of money to buy for.
Or perhaps it's just me?

1 point
login to vote
berto user
Posted Sep 18, 2008

Perfect Vixay Xavier. I will be monitoring the reloadevery script. I always have the computer on and the facebook vampire´s application page oppend so will monitore it.

What I noticed with the new lines of code for the monster enhancer is that it does not select anymore enemies 1.5 or 2 times more powerfull than yours (this maximized the chances in the attacks), but rather selects any monster to attact. In the end, the scrip selecs to attack very high rank monsters in the list, and high rank monsters are much harder to defeat. Will investigate to see how far I an go. Thank you again, Berto.

1 point
login to vote
ViXaY Xavier scriptwright
Posted Sep 18, 2008

You are welcome. I am aware of that bug and have contacted Piotr about it.

Berto, I assume you are talking about the Reload Every Extension.
I'll explain the way I've set it up.
1) Install Addon ReloadEvery
2) Right Click on the facebook page goto reload every and click custom
3) Now enter whatever time you like (i have it set to 60 minutes)
4) Now leave your browser open forever :P (I have a separate FF3 profile for it)

The only problem I had was that once it asked me if i wanted to send the postback data again, i said yes. After that I haven't had any prompts, so i don't know if that's because I haven't run into more errors, or it's because that it's working. I also haven't tried after restarting the browser, I think maybe it reset when you restart it? I don't know. Experiment for yourself and enjoy the Thrill of discovery! Then share with us :)

A sidenote: The reason I use the extension is because the script doesn't load when the page is incomplete and thus I think there's no way to handle it within the script itself. Unless you hit the try again page, then you can get it to work, i had it working in my old script, you can check it out there and hack away!

1 point
login to vote
berto user
Posted Sep 17, 2008

Yes, thanks ViXay Xavier, it works great. What it does not work properly is the "Reload Every" routine. Once it is activated, it starts by asking every how long we want to reload, and keeps doing every so often. While keeping in doing it, it bloks the Facebook monster enhancer script until reset again. Any insight?

1 point
login to vote
kaz user
Posted Sep 16, 2008

changes work, thanks.

changes have one teeeeenie bug though "Attacking You's werewolf... (S)" kinda funny, but still works and attacks proper person, not yourself. :)

1 point
login to vote
berto user
Posted Sep 16, 2008

very well explained VixayXAvier. It is done and I install also the reload script. Will be looking for the changes in the following hours to give the feedback that might be usefull for all. thanks.

1 point
login to vote
ViXaY Xavier scriptwright
Posted Sep 16, 2008

I'm assuming this is happening with the new facebook layout only.

No need to upload. To modify:
1) Right-click GM (GreaseMonkey) Icon in Firefox
2) Click Manage User Scripts
3) Select Facebook Monster Enhancer script
4) Click Edit
5) Make the changes, Save
6) Reload page you are working on, it should work

IF it doesn't work
1) Tools>Error Console
2) cilck on errors tab
3) see what is the error produced by GM Script
4) Copy and paste it here (it should be clanm is undefined)

We'll see what we can do from there.

1 point
login to vote
berto user
Posted Sep 15, 2008

Yes, changed the script code and I am afraid it keeps on doing it. It stops when selecting the oponent to attack. I select it and then goes on. Do we have to upload the script once modified? How to upload it from own computer to greasymonkey? Thank you.

1 point
login to vote
berto user
Posted Sep 15, 2008

I will try it rideway. How can we edit the script?

1 point
login to vote
ViXaY Xavier scriptwright
Posted Sep 15, 2008

Daigoro, Berto, Did you try the solution I've posted below? It'll take care of the problem for now, until Piotr comes back from wherever he's gone. Just find the following lines and change them accordingly.
Before Fix
/* Get the list of all enemies */
var powers = getElementsByClassName("small_avatar_experience", "div", divs[2]);
var names = getElementsByClassName('small_avatar_user_name', 'div', divs[2]);
var urls = getElementsByClassName('small_avatar_attack_link', 'div', divs[2]);

After Fix
/* Get the list of all enemies */
var powers = getElementsByClassName("small_avatar_experience", "div", divs[divs.length]);
var names = getElementsByClassName('small_avatar_user_name', 'div', divs[divs.length]);
var urls = getElementsByClassName('small_avatar_attack_link', 'div', divs[divs.length]);

1 point
login to vote
berto user
Posted Sep 15, 2008

Great script. It happened the same to me than to harlequin-1998. I believe with the new facebook it needs some rewrite.
Will that be possible?

1 point
login to vote
Daigoro user
Posted Sep 14, 2008

First of all, this is a great script, which I'm very happy to use.

But it seems to me the fight function has been broken a week or so - but I haven't had time to report it earlier.
Whenever I allow the script to fight, I'm stuck at the http://apps.new.facebook.com/werewolves/fightin... page, where the script isn't running, and thus I manually have to select the person I want to fight - the script then kicks in again, and returns me to the page mentioned.
The same problem exists for Zombies, Vampire and Slayer.

I'm looking forward to see it fixed.

Best regards

1 point
login to vote
ViXaY Xavier scriptwright
Posted Sep 12, 2008

For the timeout/error page problem that I have frequently i've found a different solution, Download & Install the add-on "Reload Every" And use that and set it up to reload every hour or so, such that any error page is resolved within an hour :)... hope this helps

1 point
login to vote
ViXaY Xavier scriptwright
Posted Sep 8, 2008

I've fixed it temporarily (there's still a bug though)... Like i'd suspected it had to do with the SelectDefender routine.

by changing some lines in the selectDefender routine as follows

function selectDefender () {
var divs = document.getElementsByTagName("td");
//GM_log(divs.length);//DEBUG
if (divs.length < 3) return;
/* Get the list of all enemies */
var powers = getElementsByClassName("small_avatar_experience", "div", divs[divs.length]);
var names = getElementsByClassName('small_avatar_user_name', 'div', divs[divs.length]);
var urls = getElementsByClassName('small_avatar_attack_link', 'div', divs[divs.length]);

basically before we were sending divs[2] now i am sending the last div (i.e. td) by divs[divs.length]

this seems to work well, except the name is always You instead of the actual name..

Until Piotr get's it fixed, this is a good enough option.

1 point
login to vote
Posted Sep 4, 2008

I'm encountering a problem (and my Javascript-Fu is not up to par to figure it out). When the script goes to attack someone, the attack page loads up, but the script menu goes away and no attack is actually performed. I didn't change anything (I swear!) and the "included pages" setting appears to be valid. Any ideas?

1 point
login to vote
Posted Sep 4, 2008

I'm still using it! And I have a wish-list item as well - I'd like to be able to enable the script to auto-invite. Is that possible?

1 point
login to vote
Piotr P. Kar... script's author
Posted Sep 3, 2008

noelgreen: I'll look into it. Nice to see that someone is still using this script.

1 point
login to vote
noelgreen user
Posted Aug 27, 2008

Need to make it so that when the page hits a facebook error where you have to hit the "Try Again" button it will automatically hit it and let you continue. It seems to only run through about 10 successful things before it hits an error.

You could comment on this script if you were logged in.