I was sent here to get an approval for my small script.
So, briefly:
Name: Ogame Alt statistics
small disclaimer:
- At first this script was written for myself to avoid using external resources to watch different states: vacations, 'I', 'i' etc. It uses standard Ogame XML api so there is nothing new here.
- I'm not a js dev to rate how good this code is
- I have a feeling that this code will be way too slow on the servers with big online because I am using linear algorythm to parse xmls.
- Tbh this xml parsing must be somewhere on the server (not on the client side). From the other hand, clients are independent from the server.
What does this script do:
- It does not touch standard ogame stats page.
- Adds 1 more link:
- After the first try it loads data from XML api and saves it into the cache (localstorage). Then it uses this data from the cache.
For global and militarty stats cache lifetime is 30 mins, 'i' and 'I' have 3 hours. Players with stats less than 1k are not shown.
It could be easily changed in the code:
- I skipped adding urls into the nicknames because I have to parse one more xml for it (additional browser loading)
Code is avaliable here:
greasyfork.org/ru/scripts/11564-ogame-alt-statistic/code (This service requires a @namespace, I don't know if it's fine)
Direct link:
greasyfork.org/scripts/11564-o…20Alt%20Statistic.user.js
Language: independent (I hope so )
Screenshots:
So, briefly:
Name: Ogame Alt statistics
small disclaimer:
- At first this script was written for myself to avoid using external resources to watch different states: vacations, 'I', 'i' etc. It uses standard Ogame XML api so there is nothing new here.
- I'm not a js dev to rate how good this code is
- I have a feeling that this code will be way too slow on the servers with big online because I am using linear algorythm to parse xmls.
- Tbh this xml parsing must be somewhere on the server (not on the client side). From the other hand, clients are independent from the server.
What does this script do:
- It does not touch standard ogame stats page.
- Adds 1 more link:
- After the first try it loads data from XML api and saves it into the cache (localstorage). Then it uses this data from the cache.
For global and militarty stats cache lifetime is 30 mins, 'i' and 'I' have 3 hours. Players with stats less than 1k are not shown.
It could be easily changed in the code:
- I skipped adding urls into the nicknames because I have to parse one more xml for it (additional browser loading)
Code is avaliable here:
greasyfork.org/ru/scripts/11564-ogame-alt-statistic/code (This service requires a @namespace, I don't know if it's fine)
Direct link:
greasyfork.org/scripts/11564-o…20Alt%20Statistic.user.js
Language: independent (I hope so )
Screenshots: