Travian: current/max Bounty ML v1

By Meals Last update Jul 8, 2008 — Installed 78,678 times.

Archived Comments (locked)

in
Subscribe to Archived Comments 14 posts, 9 voices



Jesse Andrews Admin

The following is an archive of comments made before threaded discussions was implemented (November 16th, 2008)

 
Joca Scriptwright

Thanks but (http://userscripts.org/scripts/show/10835) resolved the problem.

 
Joca Scriptwright

It doesnt work with battle analyse :( (http://userscripts.org/scripts/show/10835)
When i install this script disappears

Lucro 100% -------------HERE------------------- Profit in %
Eficiência 100% -------------HERE------------------- Eficiency in %

 
blodyx User

Thank you! This is what i needed :) Now i can finally thrash Travian beyond!

 
kispaljr User

if you use some other scripts (like Battle Analyse) that put images int the row of units, then you should replace the getBags() function with this code:

function getBags() {
	ret = new Array(11);
	unitline_images = find("//table/tbody/tr[4]/td/table[1]/tbody/tr[2]/td/img/@src", XPOList);
	
	var len = unitline_images.snapshotLength-1;
	for (j=0, i=0; i<=len; i++){
		img_url = unitline_images.snapshotItem(i).nodeValue;
		if (img_url.substr(0, 9) == "img/un/u/") {
			ret[j++] =t[img_url.substring(img_url.lastIndexOf("/")+1, img_url.length-4)]; 
		}
	}
	return ret;
}

 
Risi Scriptwright

To make this work with the Battle Analyse script, please update line #56 to:
ret[i-1]=t[(current.nodeValue).substring((current.nodeValue).lastIndexOf("/")+1,(current.nodeValue).length-4)];

 
Meals Script's Author

Whatever you decide I'll support you.
If you choose to increment, I'll upload your source and if you choose to post I'll add a link to your script, provided you let me know that you uploaded it.
Thank you for taking the time to do this.

 
Jelle Fresen Scriptwright

Hi, nice script, but it's a pity that it only works in english. I editted the script so it's multilanguage, and I re-engineered most of the code so its far cleaner. Later I found out about ondy1985's attempt to make it multilanguage, which is basically the same as I did, but he forgot one thing: the code is still searching for the 'Prisoners' string, which still makes it english-only.

Meals, what do you think is the best way to distribute my version?
Add a new script to the bulk of userscripts, or add it as the next version of the userscript "Travian: current/max Bounty"?

 
ondy1985 Scriptwright

You're welcome. The script is really useful, thank you for that.

 
Meals Script's Author

Wonderful. Thank you! I've been swamped lately and didn't have time to look into it :/

 
ondy1985 Scriptwright

I modified Meals' code to work with unit icons rather than unit names, which should make the script usable in all languages.

see: http://userscripts.org/scripts/show/9819

 
Joramb User

Dutch, I play on the Speed server from Holland.
http://speed.travian.nl

But I saw other battle reports witch a second number. But I don't understand what the second number means, (it is not the total bounty your army can hold, and it is not the total bounty you missed. ) can you explain me what the function of the second number is.

Greats,

Boal

 
Meals Script's Author

What language is your Travian account ?

 
Joramb User

I See a Zero after the total sum. The zero needs to be the total amount you can hold with your army so something is wrong.

1500/0
I see this when I attack with 25 man (they can hold total 1500)

1086/0
and I see this when I attack a opponent that don't have enough resources.

//Boal

Cross
Presentational HTML allowed.
Use <code> for inline code and <pre> for code blocks. Use &lt; and &gt; for literal < and >.
We help break paragraphs and link your links.
or cancel