Run the desktop version of Mindustry on Android — several versions of games in one app, Mixin bytecode patching supported.
- Introduction
- Getting
- Features
- Supported versions
- Building
- Known issues
- FAQ
- Contributing
- Support
- License
- Credits & Dependencies
- android-bridge is a JVM bridge that runs the desktop version of Mindustry on Android
- Several games or versions in one app, with as many isolated sets of data and mod configuration
- Bytecode patchers such as Mixin keep working, and loaders such as CopperLoader and Fabric run as they are
- It runs vanilla Mindustry: official releases 146.0 and up, bleeding-edge builds 24369 and up
- The game itself needs no changes and no repackaging — it runs the official release jar as it is
- This repository is the bridge alone; the host app is yours to write, or to pick an existing one
- Releases: download
bridge-<version>.jarfrom this repository's Releases (pushing a version tag — they start with a digit — makes CI build it and attach the artifact) - Snapshots: the
snapshotrelease is rebuilt and its asset replaced on every push — tomainor to a version tag (a pre-release) — and the artifact isbridge-snapshot.jar; use it when you want neither to build the bridge yourself nor to pin a version - Build from source: see Building
- Several games in one app
- Install several games or several versions, play one at a time
- Data and mod configuration can come in several isolated sets
- Mods
- Loaders such as CopperLoader and Fabric run as they are
- Bytecode patchers such as Mixin keep working, patching classes as they load
- Look and feel
- Touch, soft keyboard, back key and gesture, rotation
- File picker, clipboard, vibration, opening links
- Display
- OpenGL ES 2 / 3 both work
- ANGLE for devices that need it
- Tuning and logs
- Add and change JVM arguments yourself
- Logs in one file, optionally also in logcat
| Item | Range |
|---|---|
| Game version | Official releases 146.0 and up Bleeding-edge builds 24369 and up (the two numbering schemes are independent and not comparable) |
| Android | 11 (API 30) and up |
| ABI | arm64-v8a, armeabi-v7a, x86_64 |
| Game jar | Must be a desktop release build with assets; a classes-only one does not run |
git clone https://github.com/MDTCopper/android-bridge.git
cd android-bridge
./gradlew :pack:bridgeJarOn Windows use gradlew.bat.
The jar lands in pack/build/libs/bridge-snapshot.jar: without -Prelease the version is snapshot — buildVersion in gradle.properties belongs to a release, and only a tagged build should use it. Pass -Prelease for an artifact that carries a version number (which is what CI does for a tag build):
./gradlew :pack:bridgeJar -PreleaseThe first build checks out and compiles Mindustry and Arc at v159 by itself, which takes a few minutes and a network connection; after that it reuses what is in .mindustry/ and .arc/.
Prepare the following if you want control over the build.
JDK 25. Gradle runs its daemon on it, and downloads one if it is missing.
It needs build-tools (that is where d8 comes from), plus an NDK and cmake:
ndkVersion=29.0.14206865
cmakeVersion=3.22.1Both versions are pinned in gradle.properties — a different NDK produces a different binary. The SDK location goes in sdk.dir in local.properties, or in ANDROID_HOME.
A full clone of each, next to this project, and with tags (the build checks out by tag):
mindustryDir=../Mindustry
arcDir=../ArcThose are the default paths; they live in gradle.properties and can be changed.
Nothing to prepare. The build downloads them and packs them into the jar alongside the .so.
The bridge does not need a JRE to build. It is a payload the host carries at runtime; the tested one is an Android build of OpenJDK 25.
./gradlew :pack:bridgeJarJust to see the task list:
./gradlew tasks -PskipEpochPrepare- The game jar must be a release build with assets; a classes-only one does not run
- The bridge ships no app; the host is yours to write
- The bridge is not a mod loader; loading mods is up to the loader the host provides
- Can I use Mixin? Yes. Have the bridge start a custom loader (CopperLoader, Fabric, and so on), and that loader patches bytecode as the game loads.
- Does it need root? No.
- Can it run other games? Only vanilla Mindustry for now.
Any kind of contribution is welcome. For code changes, open a pull request that says what it does and how you verified it.
Run the full build after a change:
./gradlew :processor:compileJava :core:compileJava :bridge-v1:compileJava :native:assemble :pack:bridgeJarAfter touching bridge-vX sources, run the game on the oldest versions of the range with a real jar —compiling is not running.
Questions and suggestions go to this repository's issue tracker; read Known issues and the FAQ first.
Released under GPL-3.0.