This post is only for PHP developers that would like to make a bot with a few lines of code for non-official ogame servers v2.9.4 (I haven't tested other versions). If you does not meet that person, just step aside.
Requeriments:
1. php 5.0+
2. pear package HTTP_Client (pear install HTTP_Client-1.2.1 on unix-like systems, you need root privileges if you install this using the easy way)
3. Cron
4. And unless you know how to install HTTP_Client on windows and set a cron there, you will also need an unix-like operating system.
[Only registered and activated users can see links. Click Here To Register...] you have the zip file, you don't need to take a look at game.class.php file if you have not modified the following line in index.php:
for this one:
You will be able to see an output of OGamePlayer data, so there's no need to know how it's structured looking at the code.
The API is not finished but it can handle lots of essential things.
In index.php there's already a dumb version of a bot that keeps upgrading the lowest level buildings, upgrading military technology and building battleship units.
I did this bot for personal use for a friend's server.
Feel free to use it, modify it, distribute it or even sell it. It's on public domain.
Although I would like you to e-mail me some code contributions if u made any, so I'll update this post.
Happy coding =D
Requeriments:
1. php 5.0+
2. pear package HTTP_Client (pear install HTTP_Client-1.2.1 on unix-like systems, you need root privileges if you install this using the easy way)
3. Cron
4. And unless you know how to install HTTP_Client on windows and set a cron there, you will also need an unix-like operating system.
[Only registered and activated users can see links. Click Here To Register...] you have the zip file, you don't need to take a look at game.class.php file if you have not modified the following line in index.php:
PHP Code:
$game = new OGamePlayer(true);
PHP Code:
$game = new OGamePlayer(false);
The API is not finished but it can handle lots of essential things.
In index.php there's already a dumb version of a bot that keeps upgrading the lowest level buildings, upgrading military technology and building battleship units.
I did this bot for personal use for a friend's server.
Feel free to use it, modify it, distribute it or even sell it. It's on public domain.
Although I would like you to e-mail me some code contributions if u made any, so I'll update this post.
Happy coding =D