Player Overview

Distribution

You should have received the Starting Player as a Tar/GZip file. It should include all the source, shell scripts and other files needed to get you started. You can add the project to your workspace using the Eclipse menu:

    File >> Import
      
Choose Existing Projects into Workspace under the General drop-down. Select the Select Archive File at the top, and browse to the location of the Tar/GZip file. If you are on a CCIS Linux machine you can simply use the full path location:
    /home/lieber/.www/courses/cs4500/f09/files/source/Player/player.tgz
      
The Player project should be checked, and you can click Finish. The Player project should then appear in your Package Explorer.

Once the project is imported (and Eclipse compiles it), you can build a runnable JAR using the makeSubmission.sh script. You will use your team name for submissions, so I'll use "BryansTeam" for demonstration. Open a terminal and navigate to your Eclipse workspace directory.

Run the makeSubmission.sh command:

    ./makeSubmission.sh "BryansTeam"
      
Which will create two JAR archives: BryansTeam.jar, which is a runnable JAR, and BryansTeam_source.jar which contains just your Players source. The source will be submitted to Blackboard, and the runnable JAR will be placed in a common scratch directory, so that all the teams can have a number of players to test with.

The runnable JAR can be run using the command:

    java -jar BryansTeam.jar
      
Or alternatively with:
    java -cp BryansTeam.jar player.PlayerMain
      
If you get non-error feedback, then everything is set and you're ready to begin exploring the source and adding intelligence. If you get errors, then you must contact the course staff immediately.

Files and Organization

The directories are organized as follows:

    Player/
       overview.html
       teamreadme.sh
       makeTar.sh
       makeSubmission.sh
       scglibs.jar

       files/
          context.txt
       
       test/
          LocalGameTest.java
          PlayerTest.java
    
       player/
          PlayerMain.java
          Register.java
          Player.java
          player.mf
          PlayerServer.java
        
          tasks/
             SolveTask.java
             ReofferTask.java
             AcceptTask.java
             OfferTask.java
             ProvideTask.java
      

More Information

The source files themselves contain lots of comments and, of course, the code that makes things work. Read through them to see what we were thinking when the classes were organized/written. We will also provide a document on testing your Player with an Administrator instance both on your own, and with others... look for that in the course directories.