A complete decompilation of Retro Engine v3.
Without assets from the official release, this decompilation will not run.
You can get an official release of Sonic CD from:
Even if your platform isn't supported by the official releases, you must buy or officially download it for the assets (you don't need to run the official release, you just need the game assets). Note that only FMV files from the original Steam release of the game are supported; mobile and Origins video files do not work.
ESC
key if enabled in the config.F12
pause, F11
step over & fast forward debug features from Sonic Mania have all been ported and are enabled if devMenu
is enabled in the config.F1
will load the first scene in the Presentation stage list (usually the title screen).F2
and F3
will load the previous and next scene in the current stage list.F5
will reload the current scene, as well as all assets and scripts.F8
and F9
will visualize touch screen and object hitboxes.F10
will activate a palette overlay that shows the game's 8 internal palettes in real time.useSteamDir
is set in the config (Windows only), the game will try to load savedata from Steam's userdata
directory (where the original Steam version saves to).This project uses CMake, a versatile building system that supports many different compilers and platforms. You can download CMake here. (Make sure to enable the feature to add CMake to the system PATH during the installation!)
In order to clone the repository, you need to install Git, which you can get here.
Clone the repo recursively, using:
git clone --recursive https://github.com/RSDKModding/RSDKv3-Decompilation
If you've already cloned the repo, run this command inside of the repository:
git submodule update --init --recursive
To handle dependencies, you'll need to install Visual Studio Community (make sure to install the Desktop development with C++
package during the installation) and vcpkg.
After installing those, run the following in Command Prompt (make sure to replace [vcpkg root]
with the path to the vcpkg installation!):
[vcpkg root]\vcpkg.exe install glew sdl2 libogg libtheora libvorbis --triplet=x64-windows-static
(If you're compiling a 32-bit build, replace x64-windows-static
with x86-windows-static
.)Finally, follow the compilation steps below using -DCMAKE_TOOLCHAIN_FILE=[vcpkg root]/scripts/buildsystems/vcpkg.cmake -DVCPKG_TARGET_TRIPLET=x64-windows-static -DCMAKE_PREFIX_PATH=[vcpkg root]/installed/x64-windows-static/
as arguments for cmake -B build
.
[vcpkg root]
with the path to the vcpkg installation!x64-windows-static
with x86-windows-static
.Install the following dependencies: then follow the compilation steps below:
sudo pacman -S base-devel cmake glew sdl2 libogg libtheora libvorbis
sudo apt install build-essential cmake libglew-dev libglfw3-dev libsdl2-dev libogg-dev libtheora-dev libvorbis-dev
sudo dnf install make gcc cmake glew-devel glfw-devel sdl2-devel libogg-devel libtheora-devel libvorbis-devel zlib-devel
sudo apk add build-base cmake glew-dev glfw-dev sdl2-dev libogg-dev libtheora-dev libvorbis-dev
Follow the android build instructions here.
Compiling is as simple as typing the following in the root repository directory:
cmake -B build
cmake --build build --config release
The resulting build will be located somewhere in build/
depending on your system.
The following cmake arguments are available when compiling:
cmake -B build
step like so: cmake -B build -DRETRO_DISABLE_PLUS=on
RETRO_DISABLE_PLUS
: Whether or not to disable the Plus DLC. Takes a boolean (on/off): build with on
when compiling for distribution. Defaults to off
.RETRO_FORCE_CASE_INSENSITIVE
: Forces case insensivity when loading files. Takes a boolean, defaults to off
.RETRO_MOD_LOADER
: Enables or disables the mod loader. Takes a boolean, defaults to on
.RETRO_USE_HW_RENDER
: Enables the Hardware Renderer as an option. Takes a boolean, defaults to on
.RETRO_ORIGINAL_CODE
: Removes any custom code. A playable game will not be built with this enabled. Takes a boolean, defaults to off
.RETRO_SDL_VERSION
: Only change this if you know what you're doing. Switches between using SDL1 or SDL2. Takes an integer of either 1
or 2
, defaults to 2
.Follow the installation instructions in the readme of each branch.
Because these branches are unofficial, we can't provide support for them and they may not be up-to-date.
Currently the only supported platforms are the ones listed above, however the backend uses libogg, libvorbis, libtheora & SDL2 to power it (as well as tinyxml2 for the mod API), so the codebase is very multiplatform. If you're able to, you can clone this repo and port it to a platform not on the list.
You can find the FAQ here.
Join the Retro Engine Modding Discord Server for any extra questions you may need to know about the decompilation or modding it.