-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathREADME
47 lines (28 loc) · 1.44 KB
/
README
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
# Requirements:
- Python 3.5 (carefull! 3.4 will not work!)
- Create a virtualenv:
virtualenv -p /usr/bin/python3.5 venv
source venv/bin/activate
- Install requirements.txt
pip install -r requirements.txt
# Agent Class naming:
The Student agent class must live in a file with the same name as the class, example:
StudentAgent -> studentagent.py
# Network Game:
A remote player (will not get video output) will play against a local player
step 1: (server) - python3 netserver.py 8765
step 2: (REMOTE player being proxied) - python3 start.py -p -s Agent1,remoto,ws://server:8765
step 3: (LOCAL player hosting the game) - python3 start.py -s Agent1,local -o NetAgent,remoto,ws://server:8765
Don't forget about firewalls and ports!
There is a public server: ws://barbrady.av.it.pt/snakes
# Practice against other agents
A game server has been setup where agent can meet dinamicaly and play against each other (no visual interface)
just run the script:
treino.sh AgentClassName AgentName
# How to configure a remote repository (get updates from the teachers repository)
Since you probably cloned the professors repository and created your own repository, you need to configure a a remote repository:
git remote add upstream https://code.ua.pt/git/iia-ia-snakes
Now you can fetch from the upstream and merge with your repository:
git fetch upstream
git checkout master (or other branch)
git merge upstream/master (or other branch)