-
Notifications
You must be signed in to change notification settings - Fork 0
Usage
First, you will need to produce a PDDL domain and a configuration file for the agent to use. The PDDL-parser allows the generation of both files from the VGDL game description.
The available options, with their parameters, are:
usage: $ make parser/makefile OPTION [gi=VALUE] [go=VALUE]
- help: Show help
- pddl-game: Generate only the PDDL domain
- gi: VGDL game description path.
- go: Output path
- config: Generate configuration and PDDL domain
- gi: Path to VGDL description file
- go: Name to be given to the output files
The parser is also capable of producing HTN domains. For further information, go to this repo.
To run the agent, execute the following command:
$ java -jar target/GVGAI-PDDL-1.0.jar [ options ]
The detailed list of options are:
Usage: GVGAI-PDDL [-dhpsV] [--localhost] [-c=<configurationFile>] -g=<gameIdx>
-l=<levelIdx>
Launches a new GVGAI game played by a planning agent or by a human.
-c, --config=<configurationFile>
YAML configuration file that will be used by the
agent.
-d, --debug Debug mode.
-g, --game=<gameIdx> Game to be played.
-h, --help Show this help message and exit.
-l, --level=<levelIdx> Level to be played.
--localhost Call planner running on localhost.
-p, --problem-only Generate PDDL problem without calling the planner.
-s, --save Save runtime information (problems, plans and log).
-v, --visuals Show game visuals at runtime.
The levelIdx
parameter ranges from 0 to 4 (except . To find out what the gameIdx
of a given
game is, please check this file.
The list of games (and their IDs) where the agent has been tested are:
4 - Bait
11 - Boulderdash
13 - Butterflies
14 - Cakybaky
19 - ChipsChallenge
51 - IceAndFire
87 - Sokoban
108 - Zelda
109 - Zenpuzzle
122 - SimplifiedBoulderdash
If you want to play a level of a given game to mess with it and understand it better, just run the system with the following options:
$ java -jar target/GVGAI-PDDL-1.0.jar -g [gameIdx] -l [lvlIdx]
To run the system using the implemented planning agent, you must specify the path of a configuration file. To do so, run the system with the following options:
$ java -jar target/GVGAI-PDDL-1.0.jar -g [gameIdx] -l [lvlIdx] -c [configurationFile]
The system also has a debugging mode, which can be very handy if you want to get more information during execution time. To enable it, run the system with the following options:
$ java -jar target/GVGAI-PDDL-1.0.jar -g [gameIdx] -l [lvlIdx] -c [configurationFile] -d
Note: In order to run the debugging mode, you have to use the implemented planning agent. Thus, you must specify a configuration file. Otherwise, the
-d
flag won't do anything.
You can also save runtime information such as the generated problems, the response plans and a log file which contains information about everything that is going on in the system. To enable this option, run the system as follows:
$ java -jar target/GVGAI-PDDL-1.0.jar -g [gameIdx] -l [lvlIdx] -c [configurationFile] -s
Note: This option is only available if you are running the implemented planning agent. Thus, you must specify a configuration file. Otherwise, the
-s
flag won't do anything.