28: 1.1 Usage
29: You can type
30: __make all__
31: in the tools directory to compile everything. The other option you have is to compile modules (Phec, Simulator and Frontend) seperatly be typeing __make__ inside their directories. You will need ghc (haskell compiler) version 6.2
32: and the java sdk installed. Note that the java sdk is just needed if you want to recompile the frontend. Because the class files are included a java runtime is sufficient.
33: In the tools directory is a ./run.sh shell script to run
34: the simulator with the graphical front end, this can be used with
35: ./run.sh task/sample0.world --red=source2/initial.phec
36: --black=Simulator/test.prog
37:
38: Please note that the world files have to be downloaded sperately ({link:task.tgz|http://www.flexman.homeip.net/space/ICFP+2004/task.tgz}).
39: In the above example the file __source2/initial.phec__ is compiled first whereas the __Simulator/test.prog__ is allready compiled and is used just as it is.
40: There are a plenty of commandline switches of the main program. Start __run -h__ for a usage information.
41: For example there is a console front end included. The following call
42: makes the simulator run for 100 steps:
43: {code:bash}
44: ./run --world=task/sample0.world --red=testing/initial.phec
45: --black=Simulator/test.prog --console -s100
46: {code}
47: To run the simulator without any frontend use:
48: {code:bash}
49: ./run --world=task/sample0.world --red=testing/initial.phec
50: --black=Simulator/test.prog
51: {code}
52: In any case you will get a final result, who as won and so on.