MASSim (Multi-Agent Systems Simulation Platform), the simulation (server) software used in the Multi-Agent Programming Contest, where participants program agents to compete with each other in a predefined game.
MASSim simulations run in discrete steps. Agents connect remotely to the contest server, receive percepts and send their actions, which are in turn executed by MASSim.
Note: This server is the 2018 server modified to include back the following features from the 2017 edition:
- Items in shops. In 2018 server, items could only be gathered in resource nodes whereas in previous servers they could also be purchased in shops. This version brings back items to shops as in 2017 server.
We upload binary releases to GitHub: https://github.com/ssardina-agts/agtcity-server/releases
The build requires Maven.
Run mvn clean package
in the main directory. Maven should automatically fetch all necessary dependencies.
UPDATE August 2023: server does not work with Java 17 (class version 55), throws exceptions at run-time. However, it compiles and runs with Java 11:
$ sudo apt-get install openjdk-11-jdk
$ export JAVA_HOME=/usr/lib/jvm/java-11-openjdk-amd64
$ mvn clean package
Then to run it:
$ ./startServer.sh conf/SampleConfig-ManyItems.json
Note the script startServer
uses JAVA_HOME
environment variable already that should be pointing to Java 11.
Note that even running with old Java 11 we get the warning:
WARNING: An illegal reflective access operation has occurred
WARNING: Illegal reflective access by com.sun.xml.bind.v2.runtime.reflect.opt.Injector (file:/home/ssardina/Insync/[email protected]/GoogleDrive/PROJECTS/agents/mapc/agents-in-city.nosync/2018-rmit/agtcity-server.git/server/target/server-2021-1.0-jar-with-dependencies.jar) to method java.lang.ClassLoader.defineClass(java.lang.String,byte[],int,int)
WARNING: Please consider reporting this to the maintainers of com.sun.xml.bind.v2.runtime.reflect.opt.Injector
WARNING: Use --illegal-access=warn to enable warnings of further illegal reflective access operations
WARNING: All illegal access operations will be denied in a future release
This is what JAVA 17 complains and does not allow anymore. :-)
All steps below require Docker
Run the server from docker hub:
docker run -p8001:8001 -p12300:12300 -i -t rodriguezseb/agtcity-server-rmit ./startServer.sh conf/SampleConfig-ManyItems.json
Build the images
docker build -t agtcity-server-rmit .
Run a configuration:
docker run -p8001:8001 -p12300:12300 -i -t agtcity-server-rmit ./startServer.sh conf/SampleConfig-ManyItems.json
Run interactively:
docker run -p8001:8001 -p12300:12300 -i -t agtcity-server-rmit /bin/bash
Inside the container run the desired configuration:
$ ./startServer.sh conf/SampleConfig-ManyItems.json
Other configurations are available in the conf
folder.
server.md describes how the MASSim server can be configured and started.
scenario.md contains the description of the current scenario.
protocol.md describes the MASSim protocol, i.e. XML message formats for communicating with the MASSim server.
eismassim.md explains EISMASSim, a Java library using the Environment Interface Standard (EIS) to communicate with the MASSim server, that can be used with platforms which support the EIS.
javaagents.md gives a short introduction to the java agents framework, which holds skeletons that can already communicate with the MASSim server and have basic agent capabilities.
monitor.md describes how to view live matches and replays in the browser.
MASSim is licensed under the AGPLv3+. See COPYING.txt for the full license text.