Travian QP Targets 3.9.0

By QP Last update Sep 28, 2008 — Installed 314,375 times.

Archived Comments (locked)

in
Subscribe to Archived Comments 407 posts, 98 voices



" + tr.innerHTML;
}
var xresult = document.evaluate("//table[@class='tbg']/tbody/tr[last()]/td[position()=1]", document, null, XPathResult.ORDERED_NODE_SNAPSHOT_TYPE, null );
var td = xresult.snapshotItem(0);
td.innerHTML = '<input />';
}

//===========================================================================================================
//===========================================================================================================
//============================== Travian Report List pages extra functions ================================
//===========================================================================================================
//===========================================================================================================
.
.
.
/** transformPageReportList_addSelectAllCheckbox */
function transformPageReportList_addSelectAllCheckbox() {
// Plus users already have this checkbox so do nothing
if (document.getElementsByName("s10").length > 0) { return; }

var func = "var inputs = document.getElementsByTagName('input');"
+ "for (var i = 0; i < inputs.length; i++) {"
+ "if (inputs[i].type == 'checkbox') {"
+ "if (inputs[i].name.search(/n[1-9][0-9]?/i) >= 0) {"
+ "inputs[i].checked = !inputs[i].checked;"
+ "}}}";

var xresult = document.evaluate("//table[@class='tbg']/tbody/tr[last()]", document, null, XPathResult.ORDERED_NODE_SNAPSHOT_TYPE, null );
var tr = xresult.snapshotItem(0);

if (location.href.search(/berichte/i) >= 0) {
var xresult = document.evaluate("//table[@class='tbg']/tbody/tr[last()]/td[position()=1]", document, null, XPathResult.ORDERED_NODE_SNAPSHOT_TYPE, null );
var td = xresult.snapshotItem(0);
td.setAttribute("colspan", 1);
tr.innerHTML = "

" + tr.innerHTML;
}
var xresult = document.evaluate("//table[@class='tbg']/tbody/tr[last()]/td[position()=1]", document, null, XPathResult.ORDERED_NODE_SNAPSHOT_TYPE, null );
var td = xresult.snapshotItem(0);
td.innerHTML = '<input />';
}
.
.
.

I like it more that way, it selects all the boxes you didnt in other words it selects the oposite what you did (i think that Travian Plus function have it this way)

dbKiller Scriptwright

QP your script rocks!
I like the "Map Village Colors" feature, it's very useful.
But the normal map is too little so I use this other script, TravianMap, which create a large map in another window.
Request: could you add colors to that map as well? is it feasible?
tia

 
Diego2002 User

Ok! Another script was the problem. There's something collision between your scipt, and that one, because if I disable either yours either the another, it steps by 1 or 7. If both of the two script are enabled, I can step by 7 or 14...

But your script is more important ;)

 
r4mp4g3 User

Auto-construction doesn't work in the travian CL, Chile of normal speed.

 
ThePirate User

I meant only for the village you are in... It is nice to know at the beginning of the game, but it's not a big deal, just an idea.

 
QP Script's Author

@Diego2002: I am going to change 1 thing I did as a mistake, which is Plus users, shouldn't have the map tampered with (sice they already have the color coded information, so this will only be done on non-Plus users (next release... maybe this weekend).
Other than that I don't really understand your question:
1 - without the script there are 2 groups of arrows, 1 around the map which move 1 square, and 1 in the right bottom of the map which move 7 squares;
2 - with the script you have the same arrows which move the exact same squares!
The only thing that I changed (other than adding the colors) was to remove the nice-looking ajax behavior (at least for now).

 
brunoa Scriptwright

"So you wanted troops at home + troops returning home? But that doesn't give you anything relevant, unless you wanted troops at home + all incoming reinfs, which you simply do not know because the game does not tell you... I'm not sure I'm going to add that "home + returning"... at least for now - not even sure if it is easy or doable."
It's main propose is to make an update to troop tool easyer.
I think if you write someting like:

" Find the code "troops leaving the vilage" then find "attack "or" assalt against *" and sum "find "own troops" save troops" and sum "if table is [own vilage] and next table is reenforcements *" then sum

Something like that

BWT: the nwe changes in your script makes firefox to block and I have to close it using the task manager

 
Diego2002 User

I would like to move on the map by 1 (like without the script), can I configure the script somehow?

Or can you make it configurable?

 
QP Script's Author

@Khaidhun: I haven't been farming for a LONG time... but I had something in the works regarding that (others had requested something similar). After finishing the next release (another very nice thing... at least in my opinion :P) I may try to pick that one up again... I need to find where in those 6k+ lines of code were the things regarding that... I think I need to re-organize the script again...
And thanks :)

 
Khaidhun User

Feature request:

I would like to see on the quick farm page ( on a scout report) a textfield where I can enter the cranny capacity for the respective city. It would be nice if the number of units to be sent would be calculated accordingly. Also it would be great if once completed for a city it would be saved for future use.

If you have the time and consider it a good feature please consider it implementing.

Thanks for this great script.

 
QP Script's Author

@Joca: That is as expected, you can only send troops that are at home. In the delayed version of mine I'm using the game interface, not making a completely new one where you could select everything... that is not going to change substantially in the near future.

@khaledali: Thanks :) It is always great to see so simple and nice comments :)

@brunoa: So you wanted troops at home + troops returning home? But that doesn't give you anything relevant, unless you wanted troops at home + all incoming reinfs, which you simply do not know because the game does not tell you... I'm not sure I'm going to add that "home + returning"... at least for now - not even sure if it is easy or doable.

@ThePirate: That is wrong at the concept, let me explain why:
1 - incoming/outgoing attacks is an information that exists per village;
2 - if you only have one village this is irrelevant! so I'm assuming you have multiple villages;
3 - you want that to be seen in all pages, meaning in each village you want to see information from all villages. In other words, you want to manage the account in a page that is specific to manage a village, or even a building. This, as far as I'm concerned is completely wrong.
Now imagine you have 50 villages and you have 50 attacks on each village and some reinfs/attacks outgoing... is there any space left in your screen?
Do you really want all pages to load slower because you want to show account info when you were simply trying to make a building upgrade or whatever else??
I surely do not want that, do not believe it is correct to make it that way and will not do such a thing.
That being said, the game has account management pages... which only have real information for Plus users. I might add something like that over there but... do not expect that very soon.

@BmW: Ok, the explanation was not the easiest... but I got the point from the code. So instead of select/deselect all you wanted a toggle all. That is fine as well, I even believe I made (or was going to make) it like that, the first time I did it, but I implemented it the way it is in Plus. The reasoning is not to make a simple checkbox behave differently in case you're using Plus or not... that would be very strange in terms of usability. Given the "not so important" fact of whether is has the 1st or the 2nd behavior, it thought it was better to simply make it like the Plus. I do not expect to change this unless lots of people would really prefer that way. I may consider making this a configuration...

Nice gaming to all.

 
BmW User

I changed the code to:
(A little SelectAllCheckbox "fix")

//===========================================================================================================
//===========================================================================================================
//============================== Travian IGM pages extra functions ========================================
//===========================================================================================================
//===========================================================================================================
/**
* transformPageIGMsList_addSelectAllCheckbox
*/
function transformPageIGMsList_addSelectAllCheckbox() {
// Plus users already have this checkbox so do nothing
if (document.getElementsByName("s10").length > 0) { return; }
var func = "var inputs = document.getElementsByTagName('input');"
+ "for (var i = 0; i < inputs.length; i++) {"
+ "if (inputs[i].type == 'checkbox') {"
+ "if (inputs[i].name.search(/n[1-9][0-9]?/i) >= 0) {"
+ "inputs[i].checked = !inputs[i].checked;"
+ "}}}";

var xresult = document.evaluate("//table[@class='tbg']/tbody/tr[last()]", document, null, XPathResult.ORDERED_NODE_SNAPSHOT_TYPE, null );
var tr = xresult.snapshotItem(0);

if (location.href.search(/berichte/i) >= 0) {
var xresult = document.evaluate("//table[@class='tbg']/tbody/tr[last()]/td[position()=1]", document, null, XPathResult.ORDERED_NODE_SNAPSHOT_TYPE, null );
var td = xresult.snapshotItem(0);
td.setAttribute("colspan", 1);
tr.innerHTML = "

 
ThePirate User

Can you make the outgoing and incoming attacks to be shown in every page?

 
brunoa Scriptwright

QP: it's not that it is:
add all the troops that are not stationary in other villages or backing up other vilages.
in other words.
All troops that are included in the table you made but not the troops that are reenforcing or going to reenforce other vilages

 
khaledali User

wooooow

 
Joca Scriptwright

The problem is when i send the hero with the troops.
I cant sheddule the new attack with the hero, because it is not avaliale in the rally point.

 
QP Script's Author

New version, not too many changes, but I think they are important so that I don't delay until I have more stuff.
Map now shows color coded villages just like the Plus version.

Enjoy. Nice gaming to all.

 
QP Script's Author

@Melhior: Ok, so now you say all other problems were fixed... (which makes since since I did some bug fixes recently). Now all that remains is that Total Troops Table in Rally Point sometimes does not appear... please check for errors in the error console (and the rest of the checklist indicated above).

@Joca: Well, either you meant something else or you simply got what was expected: if the hero is not in a village you can't send him anywhere.

@brunoa: What do you really want? From what you said it seems that what you want is to get "The troops made in town X that are stationed in town X"... if that is it, the original rally point already has that in the 1st table, called "Own troops".

Nice gaming to all.

 
QP Script's Author

@BmW: Oops... sorry, I didn't see it... and I had just woke up... so I took it literally and didn't like it... anyway... sorry.

Other answers later, gotta run.

Nice gaming to all

 
brunoa Scriptwright

ok now I identified how do you add the troop to the table. I suppose it's this code

// selects tables with troops from current town OR the oasis titles
var ownTroopsTables = xpathEvaluate('//div[@id="lmid2"]/table/tbody/tr/td[1]/a[contains(@href, ' + activeVillageCoordZ +

')]/../../../..|//div[@id="lmid2"]/p[@class="b f16"]');
now how do I change this in order not to add reenforcements?

 
BmW User

@ QP
I didnt mean nothing bad with what i said and it was ment as a joke, since i typed ":P" in the end, sorry if i disrespected you in any way, it wasnt ment to be so.

Greetings

 
Joca Scriptwright

I cant send hero even if currently he is not in the village!!

 
Melhior User

@QP
oh, sorry.
the problem with reports deletion seems to be resolved finally )

and about the total troops table in rally point...
I wanted to give you an error consloe log right now... and I saw this table working.
I don't know, what the hell is up =)))
If you remember, I told you earlier about dissapearing-appearing color codes for fields/buildings and title fix.
It looks like now I have disappearing-appearing total troops table in rally point )
god damn this poltergeist )

 
QP Script's Author

@BmW: Well, "how come I didn't do this yet ?" maybe because I am not your servant! Be careful as to how you say stuff.... please.
Now answering your question, I don't think I ever saw that - remember that there are too many "Beyond" modded versions, so I probably never installed that one.
I'll look into it...

Nice gaming to all.

 
BmW User

@QP

As we all know, the counters that count how long till full Warehouse goes over crop consumption which is a little annoying, so why dont you just add it on the top of the resources not uder? I saw that one Travian Beyond have this on the top of the resources, means it is possible to do, dont know why you didnt do this yet, maybe you dont want to or you didnt came on this idea? :P

Greetings BmW

 
QP Script's Author

Ok, new version out, a couple of bugfixes in there so be sure to get the latest version to make sure you're not having problems that have been solved.

@Melhior: That was really improved in the latest versions. But you didn't answer me, is the action of deleting the reports of that type being resumed? Even after you visiting another game page with the script active?
Btw, no earlier versions for anyone... not even for me :P I'm not keeping old versions.

@kupony:
1 - distances: well, I'm not sure yet where I'll add that, but that has been on the back of my mind that it is useful to have that information in more places... this is going into the to do list;
2 - fake icon: yes, on mine too :P
3 - send resources and reinfs on right side village list: I'll consider it...

@kupony: CP: I guess I need to mention this somewhere... I play speed server so per default this is configured for speed server CPs, but there is a config variable at the end of the script to change to other versions (travian 3 normal speed and travian 2.5). On next script update this info will be up there also.

@MestreLion: Compatibility is not always easy... for beyond there are thousands of versions out there which makes it worse. I do not use the others you mention (though I've used some for reports). 1st step you need to provide the links for the scripts you are mentioning, 2nd step try to say what do you think is a problem in terms of compatibility with each one of them.

@Zuggo: Hey... I think you be happy since I saw that and hope it is fixed in this new version :) (3.2.0)

@WiCiO: Resources on top having 2nd row for crop consumption on large resource values: This is simply the way the game is... I don't see this as a bug, specially because when the values are very big they would then overlap the right side, where the village list is. You probably wouldn't even be able to press the "Villages:" links...

Nice gaming to all.