AI Framework: Mancala (Module) Build Manual Page 2 of 23

AI Framework

Mancala (Module) Build Manual

Daniel Cooper

Kevin Manning

Adam Parker

Viet Huynh

November 30, 2007

Table of Contents

Mancala Board Overview…………………………………………………………………. / 3
Single User
Linux…………………………………………………………………………………… / 4
Windows………………………………………………………………………………… / 6
Multiple Users
Setup Overview…………………………………………………………………………. / 6
Client GUI Setup
Linux………………………………………………………………………………….. / 7
Windows……………………………………………………………………………… / 10
Mancala Board Setup
Linux………………………………………………………………………………….. / 12
Windows……………………………………………………………………………… / 14
Starting Game…………………………………………………………………………… / 16
Game Termination………………………………………………………………………. / 16
Compiling
Linux……………………………………………………………………………………. / 17
Windows………………………………………………………………………………… / 23

Mancala Board Overview


This is the Mancala board. One player controls the top row and the other player controls the bottom row. The green box is the capture pit for the top row and the red box is the capture pit for the bottom row. Top Time Remaining displays how much time the top player has and Bottom Time Remaining works the same for the bottom player.

The buttons have the following functionality:

§  New Game: Starts a new game of Mancala.

§  Load Game: Loads a game from a file created in a previous session.

§  Save Game: Saves the game currently being played to a file that can be loaded later.

§  Set Game Time: Allows the player to set the time limits for the game.

§  About: Displays information about the Mancala program.

§  Exit: Closes the Mancala program.

Single User (Linux)

  1. Start the program X-Win32.

  2. Start PuTTY. Under the SSH settings in the Connection settings area, choose the X11 settings. Enable X11 forwarding.

  3. Connect to dell12.cs.umr.edu.
  4. Go to the CaffeineFramework directory. Assuming all of the code has been previously compiled, type ./MancalaGUI. This will create an X-Win32 window for the Mancala game.

Single User (Windows)

Go to the CaffeineFramework folder and run the file MancalaGUI.exe.

Multiple Users (Setup Overview)

In order to run the Mancala client with multiple users, the following steps must be taken:

  1. Start the ClientGUI.
  2. Start the MancalaGUI.
  3. Start game.
  4. Continue playing game until termination.

All instructions for these steps can be found in the documentation below.

Multiple Users (Client GUI Setup: Linux)

1.  In the directory AI\trunk\CaffeineFramework type ./ClientGUI &. This will run the client GUI.

2.  In ClientGUI, select “Load Game Module” to load the Mancala game module.

3.  Select the file libMancala.so.

4.  In the Players section, select the types of players for this game.

Multiple Users (Client GUI Setup: Windows)

1.  In the CaffeineFramework folder, run ClientGUI.exe.

2.  In ClientGUI, select “Load Game Module” to load the Mancala game module.

3.  Select the file Mancala.dll.

4.  In the Players section, select the types of players for this game.

Multiple Users (Mancala Board Setup: Linux)

1. In the directory AI\trunk\CaffeineFramework, type ./MancalaGUI –caffeine &.

2.  Enter Student ID and Name

3.  Repeat steps 1 and 2 to run another Mancala board.

Multiple Users (Mancala Board Setup: Windows)

1.  Make a shortcut for MancalaGUI.

2.  Right click on shortcut for MancalaGUI and choose “Properties.” In the Target box, add –caffeine to the end of the string.

3.  Run the shortcut. It will prompt for student ID and Name.

4. Repeat step 3 to run another Mancala board.

Multiple Users (Starting Game)

Assuming ClientGUI and sufficient MancalaGUI windows have been loaded correctly, choose “Start Game” from ClientGUI.

Multiple Users (Game Termination)

The game ends if the following conditions are met:

§  Either player has no pieces in his/her row.

§  User selects “Exit” from the MancalaGUI.

Compiling (Linux)

  1. Go to the Caffeine folder and type qmake –unix Caffeine.pro and then qt4 when prompted.

  2. Type make to build the Caffeine framework. This will show the machine compiling the code.

  3. Go to the GUI/Mancala folder, type qmake –unix MancalaGUI.pro and then qt4 when prompted.

  4. Type make to build the Mancala GUI. This will show the machine compiling the code.

  5. Go back to the Caffeine folder and then to Games/Mancala. Type qmake –unix Mancala.pro and then qt4 when prompted.

  6. Type make to build the Mancala game files. This will show the machine compiling the code.

Compiling (Windows)

  1. Open up the QT command prompt and go to the Caffeine directory.
  2. Run qmake -win32 Caffeine.pro and then make to build the Caffeine framework.
  3. Move to the folder GUI/Mancala, run qmake -win32 MancalaGUI.pro and then make to build the Mancala GUI.
  4. Go back to the Caffeine folder and then to Games/Mancala. Run qmake -win32 Mancala.pro and then make to build the Mancala game.

AI Caffeine Framework • http://web.umr.edu/~cafene