Rocks'n'Diamonds is an open source C arcade style game based off Boulder Dash (Commodore 64), Emerald Mine (Amiga), Supaplex (Amiga/PC) and Sokoban (PC). This project uses the open source engine provided by the folks at Artsoft Entertainment, and extends it with features such as
- Easily add your own AI controller to play the levels
- Library functions to help access the engine state and query item locations/properties
- Ability to replay the levels using the actions the AI agent made
- Comprehensive logging
The project keeps up to date from the original game repository located here. This project is currently on Artsoft's v4.1.4.1.
The following header only libraries are used in this project. They are included as git submodules, so it is recommended you install them by using the git --recurse-submodules
argument.
Additionally, SDL2 is needed, and highly recommended, to run any the GUI version. In addition to the standard package, image, mixer, net, and ttf will also need to be installed.
sudo apt-get install libsdl2-dev libsdl2-image-dev libsdl2-mixer-dev libsdl2-net-dev libsdl2-ttf-dev
These instructions will help you install the program. It should compile fine on most systems, but YMMV. The following systems have been tested on:
- Ubuntu 18.04: gcc/g++ 7.4.0, gcc/g++ 8.3.0, Clang/Clang++ 6.0.0
- macOS Catalina 10.15.2: Apple Clang 11.0.0
To install this project, follow the below steps:
# Clone this repository
$ git clone --recurse-submodules https://github.com/tuero/rocksndiamonds.git
# Enter the repository
$ cd rocksndiamonds
# Compile
$ mkdir build && cd build
$ cmake -DCMAKE_BUILD_TYPE=Debug ..
# or
$ cmake -DCMAKE_BUILD_TYPE=Release ..
$ make -j8
$ cd ..
# Run the GUI program with user input
$ ./rocksndiamonds
For a detailed listing of the usage, see the usage section of the documents.
- About the original client
- Changes from the original client
- GUI vs Headless
- Creating a basic controller
- Example controllers
- Detailed controller features
- Accessing engine state and information
- Usage
- Logging
- Replay files
v1.2 (2020-03-18)
- Added handleLevelSolved method for BaseController use, to handle actions on successful level completion.
v1.1 (2020-02-11)
- Added clear/add individual restrictions for BaseOption.
- Added simple pathing example controller
- Added safe options for isEmpty (isEmptySafe), isWalkable (isWalkableSafe), and isActionMoveable (isActionMoveableSafe). These have an added check to determine if moving into a cell would cause the player to immediately die from falling objects above.
- Base options have an added flag to determine if A* pathing should avoid immediate death cells (off by default)
- Added gridinfo function to get whether item was just falling
- Added graphics element RocksTouch.png so compiling doesn't depend on creating these elements from scratch
* This Changelog was automatically generated by github_changelog_generator
This project is licensed under the GNU GPL version 2 License - see the COPYING file for details.