Posted: Thu Apr 15, 2010 9:00 pm
I just use a cronjob every hour for my population tracking script.
Because sometimes even national leaders just want to hang out
https://forum.nationstates.net/
Coffee and Crack wrote:I just use a cronjob every hour for my population tracking script.
Graphs are way too hard... A table would be sufficient; it needs to be dynamically generated, so that only that last four values are kept, for example. Conceptually, it would be like this :Winnipeg wrote:I mean you'd have a line graph that went up by 5-8 Million every day it would look pretty stable at a very low incline I'm sure.
dump pop. count to table;
if row count >= 5, delete top/bottom row; // delete top row if most recent value is in bottom row; else, other way round :)
[violet] wrote:OK, around 02-May-10 22:20 PDT two files should appear:
[violet] wrote:OK, around 02-May-10 22:20 PDT two files should appear:
http://nationstates.net/pages/nations.xml.gz
http://nationstates.net/pages/regions.xml.gz
... and thereafter be updated once every 24 hours. These will contain the XML of all regions and nations in the game. Please let me know if you find these useful, any feedback regarding data format, etc.
One difference to the regular API is that each item is <NATION> (or <REGION>), not <NATIONINFO> (or <REGIONINFO>).
[violet] wrote:Please let me know if you find these useful, any feedback regarding data format, etc.