# HG changeset patch # User macbook@59-116-8-229.dynamic.hinet.net # Date 1225298321 -28800 # Node ID ef5461db3951bf2d82db22bb4a6eba6c5e3f98ea # Parent 8155f93283963ab70deeade977ef6c32f404aaac Added usebot.sh,an interface for bot diff -r 8155f9328396 -r ef5461db3951 usebot.sh --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/usebot.sh Thu Oct 30 00:38:41 2008 +0800 @@ -0,0 +1,65 @@ +#!/bin/bash +#Auther: billy3321 +#Version: 0.1 +#Interface for Eagle-Eye ikariam bot project +#for more information please visit +# https://www.assembla.com/wiki/show/eagle-eye + +function seteagleeye() { +read -p "Enter your server ( s1/s2/s3/s4 ): " SER_NAME +read -p "Enter your account: " ACC_NAME +read -p "Enter your password: " PW_NAME +echo -e "package main;\n\n\$::server = \"${SER_NAME}.ikariam.tw\";\n\$::user = \"${ACC_NAME}\";\n\$::pass = \"${PW_NAME}\";\n\n1;" > ${HOME}/.eagleeye.pm +} + +echo "Checking for Database..." +if test -f ikariam.sqlite;then + echo "Find Database, continue..." +else + echo "setting up database...." + cat ikariam.sql | sqlite3 ikariam.sqlite + echo "Database Setting finished. Continue Program..." +fi + +echo "Checking for account information file..." +if test -f ${HOME}/.eagleeye.pm ; then + echo "Find your account information file. Continue Program..." +else + echo "Can't find your account information file. We will creat one" + seteagleeye + +fi + +while true +do + echo -e "Welcome to use eagle-eye ikariam bot. Please select the action you want to do.\n 1. Reset the account information file.\n 2. Reset the databse.\n 3. Scan around your island.\n 4. Run the bot.\n 5. List the sheeps(Please scan first).\n 0. Exit Program." + + read -p "What do you want to do now? Please enter the number:" ACT + case $ACT in + "1") + seteagleeye + ;; + "2") + rm ikariam.sqlite + cat ikariam.sql | sqlite3 ikariam.sqlite + ;; + "3") + perl scan.pl + ;; + "4") + perl agent.pl + ;; + "5") + perl sheep.pl + ;; + "0") + break + ;; + *) + echo "Please enter a number." + ;; + esac +done + + +#END diff -r 8155f9328396 -r ef5461db3951 warfare.pl