This is a guide to building your own Sonic Mania APK for Android. This guide is currently intended for Windows 10/Windows 11 users only. An Android build guide for Linux is coming soon.
-
Install Git from here if you don't already have it.
-
Install Android Studio from here if you don't already have it.
-
Download the Sonic Mania Android Build Helper script from here. Press "Ctrl + S" after clicking the link, and save it as a
.bat
file. This script will automate a lot of the difficult parts of the Android build process to make compilation easier. -
Locate
ManiaAndroidBuildHelper_2.0.bat
and place it somewhere easy-to-access. No specific location is required. -
Right click
ManiaAndroidBuildHelper_2.0.bat
and click "Run As Administrator". This is very important. If you do not select Run As Administrator, the script will fail to create the required symlinks, and it will not compile correctly!! -
Follow the directions in the command line window. You should want to choose
y
for Touch Controls and Ultra Widescreen, but neither are technically required. -
Once the script says
SETUP COMPLETE
, open Android Studio. ClickFile
in the navigation bar at the top, clickOpen
, navigate toC:\Users\username\Sonic-Mania-Android-Sheeple\Sonic-Mania-Decompilation\dependencies\RSDKv5\android
(replacing 'username' with whatever your Users folder is called) and clickOK
. Android Studio will then run some automatic actions in the background to import the project. -
Ensure that the latest SDK tools are installed. This can be checked by going to "Tools --> SDK Manager". Go to the
SDK Tools
tab. If the latest versions ofAndroid SDK Build-Tools 33
,NDK (Side-by-Side)
,CMake
, andAndroid SDK Platform-Tools
are not installed, check the boxes for them and clickApply
. It will then download the latest versions of these tools onto your computer. Once finished downloading, press theFinish
button, and the project will sync with the new tools. -
Eventually, Android Studio will prompt you, in the bottom right-hand corner, to upgrade "Gradle". This is required for successful compilation, so you need to upgrade it.
-
If you just want to play the game, and are not interested in bug-reporting, you can go to
Build --> Build Project
. Android Studio will then automatically start compiling your APK file, and after completion, will be stored in the directoryC:\Users\username\Sonic-Mania-Android-Sheeple\Sonic-Mania-Decompilation\dependencies\RSDKv5\android\app\build\outputs\apk\debug
.
11. This next step is for ONLY for users wanting to play on the RELEASE build. If you are using a Debug build, skip to Step 12.
- Before compilation, go to "Build --> Generate Signed Bundle/APK". This will then prompt you with many fields to fill out, the required ones listed below:
-
11a. Select "APK" on the first page, it being the bottom option. Hit "Next".
-
11b. There are four fields next. They are, as follows:
Key store path
,Key store password
,Key alias
, andKey password
. -
11c. For
Key store path
, click the folder icon and go to the directoryC:\Users\username\Sonic-Mania-Android-Sheeple\Sonic-Mania-Decompilation\dependencies\RSDKv5\android
. There should be a file namedrelease-key.jks
. Choose that file as theKey store path
. -
11d. For the next three fields, the passwords for each field are:
-
Key store password:
retroengine
-
Key alias:
key0
-
Key password:
retroengine
-
11e. Choose "Next", and then chose the
release
option. Android Studio will then automatically start compiling your APK file, and after completion, will be stored in the directoryC:\Users\username\Sonic-Mania-Android-Sheeple\Sonic-Mania-Decompilation\dependencies\RSDKv5\android\app\release
.
-
12a. Install your Mania APK on your phone and run it once. It will not show anything, but we can fix that.
-
12b. Download the required
mods.zip
folder from here. -
12c. Extract the
mods.zip
folder from Dropbox into the directory[root]\RSDK\v5\mods
on your phone. You should now be able to play Sonic Mania on Android!
If you need any support, please feel free to reach out to the Retro Engine Modding Server on Discord.