Ogame Resource Ticker

By Oliver Jensen Last update Jul 20, 2009 — Installed 3,479 times.

another bug

Subscribe to another bug 9 posts, 3 voices

benjammin User

Hey Oliver - great script that you've made, but I found a bug. Here's what happens:

I have a moon outside my main planet. If I go to the resources tab on the planet to update the script with my production values, it works fine on the planet. However if I switch to my moon outside the planet, the moon resources increase the same as the planet production. Of course, this isn't possible. Same happens if I click the resources page on the moon - works fine while I'm on the moon but if I go back to the planet, the resources don't tick - so they reflect the cookie grabbed from my moon resources page.

Perhaps you just store the cookie based on the coordinates?

Oliver Jensen Script's Author


Thanks for your input! I do actually store the cookie based on the coordinates - if you check your cookies you'll see you have a cookie called rates[x:y:z] for each of your planets, but I guess since your moons are in the same [x:y:z] slot they probably get the same cookie attributed. The script gets the coordinates from the currently selected value in the dropdown box at the top of the screen. I've never had a moon so I don't really know how to check for them.

This sounds like an easy bug to fix, but I'd need to see what a moon-page looks like. If you wouldn't mind, could you save the HTML source of various pages when on your moon? (i.e. buildings, resources, etc) That way I could find a common element that's different from planet pages and I could just make the tickers not count when looking at a moon.

So, if you zip up a couple of those pages, upload it to drop.io or something and post the link, I'll have this fixed in no time. You'll probably also want to replace any of your coordinates with 'x's, so that people don't get 'em.


benjammin User

I will not be able to do that, sorry.

Oliver Jensen Script's Author

Thanks anyway for pointing out the bug =)

Anyone with a moon care to help me out? Otherwise you guys are gonna have to wait for a while...

Vess Scriptwright

If you take the coordinates of the current planet from the planet selector, and if the problem is that you can't figure out whether you're looking at the planet or at the moon around it, the easiest solution is to inspect the name if the planet. If it has a "(" in it, it's a moon.

For instance, when on a moon, the planet selector would show the current planet as something like "FooBar (Moon) [X:XXX:XX]", where "FooBar" is the name of the moon and "[X:XXX:XX]" are the coordinates of the planet it orbits. You can't have a "(" in the name of the planet and looking just for it is a language-independent way to recognize moons, because the text "Moon" is translated in the various languages.

Oliver Jensen Script's Author

Thanks. This should be solved now.

benjammin User

OK Oliver just tested the new script - it works sorta now. Here's what happens -

If I view the resources page of each planet, the resources will tick correctly on the planet and then not tick on the moon. The problem is if I view the resources page on the moon, then go back to the planet. If I do this, the resources stop ticking on the planet.

Oliver Jensen Script's Author

Ah hehe thanks =) Not having a moon makes this darn hard to test. Anyway, I threw in a moon-check before overwriting the planet's cookie so that issue should be fixed now.

I'll consider whether or not to just not do anything at all if it's a moon... but I'd need to think about that a little before just doing it and i'm too tired right now

benjammin User

Just tested the new version, the bug I noted yesterday seems to be fixed!