Editing Installation

From Bebot Wiki 2
Jump to navigationJump to search

Warning: You are not logged in. Your IP address will be publicly visible if you make any edits. If you log in or create an account, your edits will be attributed to your username, along with other benefits.

The edit can be undone. Please check the comparison below to verify that this is what you want to do, and then save the changes below to finish undoing the edit.

Latest revision Your text
Line 8: Line 8:
  
 
* an account of Anarchy Online (paid only if to be connected into RK2019 server) or Age of Conan
 
* an account of Anarchy Online (paid only if to be connected into RK2019 server) or Age of Conan
* PHP version from 5.4 (minimally but 7+ advised) upto 8.3 ("Max Tested So Far" aka MTSF)
+
* PHP version from 5.4 (minimal requirement) upto 8.0 (max tested so far)
* database server of either Mysql (from 4.1 upto 8.0 MTSF) or MariaDB (10.0 upto 11.2 MTSF)
+
* database server of either Mysql (from 4.1 upto 8.0) or MariaDB (10.0 upto 10.4)
 
* either "Official" files at https://github.com/J-Soft/BeBot/archive/master.zip (stable) or "Beta" files from https://github.com/bitnykk/BeBot/archive/master.zip (sandbox) NB : if you know how to use git, you also can clone/pull from any of these urls.
 
* either "Official" files at https://github.com/J-Soft/BeBot/archive/master.zip (stable) or "Beta" files from https://github.com/bitnykk/BeBot/archive/master.zip (sandbox) NB : if you know how to use git, you also can clone/pull from any of these urls.
  
Line 29: Line 29:
  
 
Download the latest release version from the BeBot homepage and unzip/git the files to a directory maintaining the directory structure.
 
Download the latest release version from the BeBot homepage and unzip/git the files to a directory maintaining the directory structure.
 
OR
 
 
Follow our Docker guide (if you juste want to test Bebot or run 1 bot and you have no SQL) http://wiki.bebot.link/index.php/Docker
 
  
 
'''Database'''
 
'''Database'''
Line 57: Line 53:
  
 
Note that you can use forward slashes (recommended) or double backslashes (not recommended) on windows systems. Using single backslashes WILL NOT WORK as php interprets \ as a special escape character.
 
Note that you can use forward slashes (recommended) or double backslashes (not recommended) on windows systems. Using single backslashes WILL NOT WORK as php interprets \ as a special escape character.
 
On linux, you may have to perform various installs depending on which OS you run (and its version). Usually apt (or yum) based :
 
* install phpX.Y phpX.Y-mysqli phpX.Y-bcmath phpX.Y-curl phpX.Y-mbstring (X.Y being the PHP version you aim for, eg 7.0 or 8.1, etc).
 
  
 
On windows, according to the PHP version you'd want Bebot to run into, you may need to copy a php.exe file right into bot's root folder (where StartBot.bat is). Unless windows PATH and/or php.ini are well set so the exe can locate required libraries alone, you may have to copy correct .dll files for this specific PHP.
 
On windows, according to the PHP version you'd want Bebot to run into, you may need to copy a php.exe file right into bot's root folder (where StartBot.bat is). Unless windows PATH and/or php.ini are well set so the exe can locate required libraries alone, you may have to copy correct .dll files for this specific PHP.
* For 5.4/5.6 : libeay32, libmysql, php5ts and ssleay32, php_mysqli & php_sockets.
+
For 5.4/5.6 : libeay32, libmysql, php5ts and ssleay32, php_mysqli & php_sockets.
* For 7+.x : libcrypt, libssl, libssh2, sockets, nghttp2, curl & phpX(ts).
+
For 7.x : libcrypt, libssl, libssh2, sockets, nghttp2, curl & php7(ts).
  
 
Bot will tell you what misses to run during startup, so check all lines !
 
Bot will tell you what misses to run during startup, so check all lines !
Line 86: Line 79:
 
  extension=pdo_mysql
 
  extension=pdo_mysql
 
  extension=sockets
 
  extension=sockets
 
You also should look after the value of the parameter "memory_limit" in php.ini. It could be set at -1 (unlimited) which is fine if you got lot of RAM.
 
Otherwise you'd want to control how much RAM each bot uses (if you run many). Anything around 10M (linux) or 50M (windows) should work safe enough :
 
 
memory_limit = 50M
 
 
If you see errors about exhausted allowed memory size, raise that number up of, e.g., 10M more (50M becomes 60M for example) until it works fine.
 
  
 
In Startbot.php you may want to set $main_php to location of the "Main.php". Leave it at "Main.php" if you're starting the bot from the directory its in. But if StartBot.php is in another directory than the bot itself (not recommended) you must specify its complete path to "Main.php".  
 
In Startbot.php you may want to set $main_php to location of the "Main.php". Leave it at "Main.php" if you're starting the bot from the directory its in. But if StartBot.php is in another directory than the bot itself (not recommended) you must specify its complete path to "Main.php".  
 
'''Config files'''
 
 
You can either fill up infos at bot's 1st run (if no conf file exists, they will be created once interactive setup is done), or edit them manually :
 
  
 
Open the file Bot.conf, which is in the conf directory where you installed the bot, in a text editor. Here you will have to enter the Anarchy-Online username, password and the name of the bot along with the dimension number you would like to run it on.
 
Open the file Bot.conf, which is in the conf directory where you installed the bot, in a text editor. Here you will have to enter the Anarchy-Online username, password and the name of the bot along with the dimension number you would like to run it on.
Line 113: Line 95:
  
 
The last 4 values are probably best left at default.
 
The last 4 values are probably best left at default.
 
'''1K Limit'''
 
 
Each bot has a limit of friendlist ingame, but that can be overcome by specific tricks and config.
 
 
For AO specifically, you may use AOCP over a certain version of Bebot. For AoC you have the slaves module.
 
 
Both are detailed in README and/or at this page http://wiki.bebot.link/index.php/Friendlist
 
  
 
'''Guild bot ONLY'''
 
'''Guild bot ONLY'''
Line 182: Line 156:
 
Then you can type (or crontab) :
 
Then you can type (or crontab) :
 
  service botname start|reload
 
  service botname start|reload
Or :
 
systemctl start botname.service
 
In this case your reboot bash script upper should rather be like :
 
/bin/systemctl start botname.service
 
  
 
Would your bot into an AOCP proxy with slaves, you could also service it on same model :
 
Would your bot into an AOCP proxy with slaves, you could also service it on same model :
Line 195: Line 165:
 
  Type=simple
 
  Type=simple
 
  User=root
 
  User=root
RemainAfterExit=yes
 
 
  WorkingDirectory=/path/to/aocproxy
 
  WorkingDirectory=/path/to/aocproxy
 
  ExecStart=/usr/bin/screen  -d -m -S aocproxy /path/to/aocproxy/run.sh
 
  ExecStart=/usr/bin/screen  -d -m -S aocproxy /path/to/aocproxy/run.sh

Please note that all contributions to Bebot Wiki 2 may be edited, altered, or removed by other contributors. If you do not want your writing to be edited mercilessly, then do not submit it here.
You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource (see Bebot Wiki 2:Copyrights for details). Do not submit copyrighted work without permission!

Cancel Editing help (opens in new window)