This repository contains the code for URUBUGU (ikibuguzo, Igisoro): a variant of the Bao game that is played in Burundi. URUBUGU is a two player turn-based board game.
After downloading and installing python and the necessary libraries, the user have to run the following command to play the game:
- On Windows, Unix-like systems and Mac OS:
python3 main.py
- Exclusively on windows:
The user can download the following file "Executable Files/urubugu v1.1.zip" and launch the .exe file in it.
When the code is executed, this pygame window will appear.
On the menu screen, the user can switch between the "versus computer mode" or "player versus player" mode by clicking on the slider button in the top center of the window. The default setting is "player versus player".
The user can also choose his favorite language by clicking on the flag appearing in the top left corner of the window. The displayed flag is the current language, by default, the language is English.
To start a game, the user has to click on the play button.
According to the rules of "URUBUGU", the players can set up their board as they wish before the start of the game. Our version gives the possibility to only one of the players to do so, the other one has to use a default setting.
d
→ change design.
The board is divided in two, each player has half of the board as his base. Players play facing each other. image board divided in two symmetrical parts.
In each players base there are two zones, an active zone and a "cemetery". The active zone is the zone where a player can capture opponent's beads, in the "cemetery", the player can either go around and come back in the active zone or he might end his turn (more details in the [playing] section.
At the beginning, each player has 32 beads and each player is free as to the disposition of his beads. There no prohibited settings.
The default setting is a two-beads-by-cell setting.
To start a turn, the player takes the beads in any non-empty cell and spreads it's content in the direction of the play (counter-clockwise).
If the last bead falls in the active zone, and there are beads the adjacent cells in the opponent's base , the player will capture those beads and restart to play from the origin of his play.
If the adjacent cells in the opponent's base are empty, then the player will take the beads of that cell (if the cell was not empty) and spread it's content in the direction of the play (counter-clockwise) until the end of his turn.
A turn is ended in two cases:
- When the last bead of a play falls into an empty cell in the cemetery.
- When the last bead of a play falls into an empty cell in the active zone and the adjacent cells in the opponent's base are also empty.
To win, a player must capture all the beads from the opponent : player wins, if and only if all of the 64 opponent's beads are in his base.
In this section, we give two strategies (among a plethora of other strategies) to give a gist of what can be done in this game.
Spreading is a strategy where the player spreads the content of one cell, so as to fill the most cells. That strategy gives more chances to the player to capture ennemy's beads in two turns.
The decapitation's main objective is to prohibit the opponent to captuure any of our beads in his turn. The player will capture the beads from the left corner of the opponents board (the head) .
The online version of this game is in developpement, a first step has been reached: players can play against one another on a local network, the next step is to launch it over the internet for players to interact from all over the world. But a deployment on internet comes with financial costs, that is why it has been put on hold for now.
One of the next steps of this project is to develop an artificial intelligence model capable of playing against a player. This AI would also facilitate simulations in the context of research.
This game has many opportunities to explore in terms of research, the intuitive questions are:
" Is there a counter setting for each setting?"
" If there is a counter-setting, how can we compute it?"
But there are also some non-trivial questions like:
" How initial settings influence the game? "
In Conclusion, there are many avenues to be explored in this game.
We define by counter-setting a setting that insures a "one-play-win" ("IMPAGA") to the player who starts.