File: README

package info (click to toggle)
0ad 0.0.17-1
  • links: PTS, VCS
  • area: main
  • in suites: jessie, jessie-kfreebsd
  • size: 51,248 kB
  • ctags: 46,933
  • sloc: cpp: 223,208; ansic: 31,240; python: 16,343; perl: 4,083; sh: 1,011; makefile: 915; xml: 733; java: 621; ruby: 229; erlang: 53; sql: 40
file content (85 lines) | stat: -rw-r--r-- 3,080 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
@@ Install ejabberd and the erlang compiler @@
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
# apt-get install ejabberd erlang-dev make

Configure it
# dpkg-reconfigure ejabberd 
set the domain name (e.g. localhost if you installed it on your development computer)
and a login / password

You should now be able to connect to this XMPP server using a normal XMPP client (e.g. Empathy).

@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
@@ Installation of the custom XMPP module @@
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
Go to its source directory
$ cd source/tools/XpartaMuPP

Edit mod_ipstamp.erl to set the domain on which is run the ejabberd server. (e.g. localhost)
# -define (Domain, <server domain>).

Build and install it
$ make
# make install

Tell ejabberd that you want it to load the module
In /etc/ejabberd/ejabberd.cfg, add {mod_ipstamp, []}
in the Modules list "Modules enabled in all ejabberd virtual hosts"

Restart ejabberd
# service ejabberd restart

If something goes wrong, read /var/log/ejabberd/ejabberd.log

@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
@@ Ejabberd administration @@
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
Go http://localhost:5280/admin and connect 
(the login looks like login@domain (e.g. adminjabber@localhost))

In "Access rules" check that "register" is set to "[{allow,all}]"

You can see the list of registered / connected users in
"Virtual Hosts" >> domain name >> "users"

You must manually add a new user for XpartaMuPP.
Enter a login (use "wfgbot" since that's what clients expect) 
and password, then press "Add user"

Alternative - Command line :
Edit /etc/ejabberd.ejabberd.cfg and change {register, [{deny,all}]} to {register, [{allow,all}]}.
Register wfgbot : # ejabberdctl register wfgbot <domain> <wfgbot password>

Create an ACL that includes the bot (name it ipbots, since that's what the ipstamp module expects)

@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
@@ Run XpartaMuPP - XMPP Multiplayer Game Manager @@
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
You need to have python 3 and SleekXmpp installed
$ sudo apt-get install python3 python3-sleekxmpp

If you would like to run the leaderboard database,
$ sudo apt-get install python3-sqlalchemy

Then execute the following command to setup the database.
$ python3 ./source/tools/XpartaMuPP/LobbyRanking.py

Execute the following command to run the bot with default options
$ python3 ./source/tools/XpartaMuPP/XpartaMuPP.py

or rather a similar command to run a properly configured program
$ python3 ./source/tools/XpartaMuPP/XpartaMuPP.py --domain localhost --login wfgbot --password XXXXXX --nickname WFGbot --room arena

Run python3 ./source/tools/XpartaMuPP/XpartaMuPP.py --help for the full list of options

If everything is fine you should see something along these lines in your console
<<<<
INFO     Negotiating TLS
INFO     Using SSL version: 3
INFO     Node set to: wfgbot@lobby.wildfiregames.com/CC
INFO     XpartaMuPP started
<<<<

Congratulations, you are running XpartaMuPP - the 0ad Multiplayer Game Manager.