Jump to content

We're sorry for technical difficulties latest site upgrade caused.

We have now resolved the issue. 

If you're still experiencing issues, please clear your cache by following instructions on this link.  
Shall the issue persist after this step, welcome report it. 

Sign in to follow this  
xZero

Donate all [BOOKMARKLET]

Recommended Posts

If you're like me, you would rather have nothing than to get robbed therefore:

  • Spend gold on anything useful (skills, potions, etc)
  • Donate everything else you can't use to clan

 

I was sick of visiting clan page and manually typing gold amount, furthermore annoyed by BF behavior "if donation amount is even a 1 gold bigger than your total gold nothing will happen".
So, I wrote a bookmarklet which is basically one click solution:

  1. Visit internal clan page (URL has to be http://sXX.XX.bitefight.gameforge.com/clan/index)
  2. Click "Donate all"  bookmarklet on your bookmarks bar

Clicking bookmarklet will: Get your current gold, fill the amount field, submit donation. Everything with just one click!


How I can get/use bookmarklet?

It's simple! Just drag and drop following link to your bookmarks bar: Donate all

Forgivable version (if first doesn't work) Just drag and drop following link to your bookmarks bar: Donate all

 

 

 

 

Usage of any scripts is against Bitefight rules, so discretion is advised. 

Bookmarklet is undetectable and there is no way that Gameforge can detect that you use it therefore you should be fine as long as you don't speak out loud about it on BF.

 

Enjoy!

Share this post


Link to post
Share on other sites

It is not working for me... When I go to the page with /Index at the end (which means that it is the first time I went on this page, if I click anywhere on the clan page, the url will shrink to clan/: http://s16.fr.bitefight.gameforge.com/clan).

So when I first entered the page and click on your bookmark, it puts the right amount of gold on the blank but it seems that the page refreshes without giving the gold to my clan :o

Btw I find this stuff really really underrated! What a time to be alive :D +1 for you Boss!!

Share this post


Link to post
Share on other sites
14 hours ago, Thebestsimon said:

It is not working for me... When I go to the page with /Index at the end (which means that it is the first time I went on this page, if I click anywhere on the clan page, the url will shrink to clan/: http://s16.fr.bitefight.gameforge.com/clan).

So when I first entered the page and click on your bookmark, it puts the right amount of gold on the blank but it seems that the page refreshes without giving the gold to my clan :o

Btw I find this stuff really really underrated! What a time to be alive :D +1 for you Boss!!

Odd, but well, perhaps I can set it to work even on url/clan ? I'll do. Search for updated version in first post.

When you click bookmarklet following happens:

if current page == any://*.*.bitefight.gameforge.com/clan/index {

    Get current gold value
    If currentgold > 0 {

fill in input field amount with current gold
// DO: Submit donation

}else{

// DO: Complain!

}

}else{

 // DO: Complain with alert("Blah blah blah")

}

 

Or there is JavaScript source code: 

var re = /s[0-9]+\.[A-Za-z]{2}\.bitefight\.gameforge\.com\/clan\/index$/;

function strip(html) {
    var tmp = document.createElement("DIV");
    tmp.innerHTML = html;
    return tmp.textContent || tmp.innerText || "";
}

// This if verifies URL with regex
if ((re.exec(window.location.href)) !== null) {
    var AvailGold = strip(document.getElementsByClassName('gold')[2].innerHTML); 

    AvailGold = AvailGold.replace(/\D/g, '');

    if (AvailGold > 0) {
        document.getElementsByName("donation")[0].value = AvailGold;
        document.forms[0].submit(); // Submit form
    } else {
        alert("You can't donate nothing!");
    }

} else {
    alert("This URL is not BiteFight internal clan URL");
}

To make bookmarklet yourself out of this (or modified) JS code, you can use either of following online tools:

... There are more tools you can use. Google for it.

Share this post


Link to post
Share on other sites

On what browser do you think we should use it? Im currently on Chrome and haven't tested on Firefox... But btw I don't really need this one :) It is sure a good help but since I've taken the rhythm to donate everyday after using the bot I will totally forgot to clic on my bookmark lol :) but thanks having shared the JS :) In my bot that I was working on I used those command lines as: 

document.getElementsByClassName('gold')[2].innerHTML

But I've no time to continue my bot :/

Share this post


Link to post
Share on other sites

Well, I play on s202, that explains why it does work for me.  
Can you open clan page, and send me HTML code to PM? I do not have accounts on any other servers, so if you send me a code, I can find a way to make it work there as well. I suppose something is a bit different on non-speed servers.

@Thebestsimon Well, I'm sure this bookmarklet have it's own puulic. JUst like BFSpyMon.

Share this post


Link to post
Share on other sites

@xZero For sure :) I know that all the people on this forum love what you did (I love it too but have no time to use it :'(). If I had not found this forum I sure had stopped Bitefight! You are saving my account life lol

Edit 07/26: Well now it is working :3 Quite good!

Share this post


Link to post
Share on other sites
3 hours ago, Add said:

It suddenly stopped working for me. I don't know why?

Any errors? Detailed description of "stopped working", please :)

,Is there clan war ahead?

Share this post


Link to post
Share on other sites
On 8/13/2016 at 6:04 PM, Add said:

Im not sure but I think it was. why?

It's a unfixed bug. 
Bookmarklet reads current gold amount, fills in a field in form 0 and then submits that form. While there is no war, donation form remains a form 0, as soon as there is clan war, join it is another form, and therefore clan war becomes form 0 and donation form 1.  Bookmarklet always uses form 0, so if there is a war ahead, using it will only join you to the war.

I'll fix that as soon as possible and promote notification in here.

Share this post


Link to post
Share on other sites
On 15.08.2016. at 1:09 AM, xZero said:

It's a unfixed bug. 
Bookmarklet reads current gold amount, fills in a field in form 0 and then submits that form. While there is no war, donation form remains a form 0, as soon as there is clan war, join it is another form, and therefore clan war becomes form 0 and donation form 1.  Bookmarklet always uses form 0, so if there is a war ahead, using it will only join you to the war.

I'll fix that as soon as possible and promote notification in here.

Awesome :)

Share this post


Link to post
Share on other sites

New update! Related to:

This update works with new URL structure. 
I also fixed bug with clan war - if clan war proposal - accept the war instead of donation.

Check up with first post for update! 
Simply delete old and drag and drop new!

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Sign in to follow this  

Elite7Hackers Netwok

Hack the imagination!

Support and inquiries

Open support ticket here or email us at [email protected]

Highlights

Highlighted/recommended lights

×
×
  • Create New...

Important Information

By using this site, you agree to our Privacy Policy and Terms of Use.