
Waltang
|
Quick Training with time to next gameFirst off, thanks to everyone who makes these scripts. They make a huge difference in time management in the game.
What I would like to see if is possible, is to have the Quick Training page modified to show the time remaining til next game. For those of us that have 30+ players spread across multiple teams, it would be nice to from the quick training page, know if there was 1 or 2 days til the next game so that the appropriate training intensity could be selected without having to jump back to the home page to see.
I've seen the mod that shows the cash on the quick training page, which would also be useful to a lesser extent, but since money is usually not an issue, the time is much more important IMO.
I can follow basically how the scripts work, but am not very proficient in javascript, and cannot seem to figure out how to determine the element names. If one of you guys have time to write this, or at least point me in the appropriate direction, it would be much appreciated.
Thanks again for all your work on the other scripts as well.
|
pabst
|
I use firebug to get a handle on the structure of the page. You can use it to jump directly to a particular element's HTML source just by clicking the page itself. You can edit on the fly for testing little things out. Works well enough for my purposes.
FWIW, for getting particular elements, I use DOM functions to get close and then move around using the parentNode/childNode relationships.
| Code: | document.getElementById("some id string")
<parentNode>.getElementsByClassName("some class name")
<parentNode>.getElementsByTagName("a" - "tr" - "input" - whatever)
<some element>.parentNode (move 1 node towards the root)
<some element>.childNodes[4] (5th child)
|
|
|
|
|