changeset 42:0644b53fd3af

updated documents
author "Rex Tsai <chihchun@kalug.linux.org.tw>"
date Fri, 17 Oct 2008 01:33:52 +0800
parents 5849b6fdc76c
children 1dbb3e3c8691 4f7bca0d6190
files README ikariam.sql
diffstat 2 files changed, 28 insertions(+), 14 deletions(-) [+]
line wrap: on
line diff
--- a/README	Fri Oct 17 01:27:10 2008 +0800
+++ b/README	Fri Oct 17 01:33:52 2008 +0800
@@ -3,3 +3,28 @@
 = Files =
 
 Ikariam.pm - Basic modules for collectoin information from web, and the web access/submit functions will be also implemented.
+
+ally.pl - list all the cities which owned by an ally.
+enemy.pl - list all the islands and scores the enemy have.
+freeland.pl - find the available place we can build the city.
+inactive-map.pl - finding the sheep and list them in a map.
+inference.pl - a simple proof-of-concept of decision making robot.
+scan.pl - scan the islands and cities by coordinate or default world view.
+scores.pl - scan and update the scores of accounts.
+sheep.pl - find the sheep to kill, takes coordinate or default world view.
+
+= HOWTO =
+ * Create the sqlite3 database 'ikariam.sqlite' first, based on ikariam.sql
+ * Create the config file, at ${HOME}/.eagleeye.pm. The file content are
+package main;
+
+$::server = 's2.ikariam.tw';
+$::user = "chihchun";
+$::pass = "YOUKNOW";
+
+1;
+
+ * Run the bot, 'perl inference.pl'
+ * Update the islands by runing 'perl scan.pl'
+ * List sheeps, 'perl sheep.pl'
+
--- a/ikariam.sql	Fri Oct 17 01:27:10 2008 +0800
+++ b/ikariam.sql	Fri Oct 17 01:33:52 2008 +0800
@@ -5,7 +5,7 @@
  user INTEGER,
  owner TEXT,
  ally TEXT,
- island INTEGER);
+ island INTEGER, "status" CHAR, "time" INTEGER);
 CREATE TABLE "island" (
  id BIGINT PRIMARY KEY UNIQUE,
  x INTEGER,
@@ -13,16 +13,5 @@
  name TEXT,
  tradegood INTEGER,
  wonder INTEGER,
- people INTEGER);
-CREATE TABLE "user" (
-  id INTEGER PRIMARY KEY UNIQUE,
-  name VARCHAR,
-  ally VARCHAR,
-  allyId INTEGER,
-  score INTEGER,
-  building_score_main INTEGER,
-  building_score_secondary INTEGER,
-  research_score_main INTEGER,
-  research_score_secondary INTEGER,
-  army_score_main INTEGER,
-  trader_score_secondary INTEGER);
+ people INTEGER, "time" INTEGER);
+CREATE TABLE "user" ("id" INTEGER PRIMARY KEY ,"name" VARCHAR,"ally" VARCHAR,"allyId" INTEGER,"score" INTEGER,"building_score_main" INTEGER,"building_score_secondary" INTEGER,"research_score_main" INTEGER,"research_score_secondary" INTEGER,"army_score_main" INTEGER,"trader_score_secondary" INTEGER, "time" INTEGER);